Skip to content

ospsuite 12.4.5

Latest

Choose a tag to compare

@Felixmil Felixmil released this 24 Sep 07:24
· 150 commits to main since this release
7482b90

Minor improvements and bug fixes

  • {ospsuite} 12.4.x now requires {rSharp} 1.2.3 or older, which runs on .NET 8. Newer {rSharp} versions use .NET 10, with which loadSimulation() and the other functions that read or write observed data in .pkml files fail. If library(ospsuite) reports that a newer {rSharp} is installed, run pak::pak("Open-Systems-Pharmacology/rSharp@v1.2.3") or upgrade to {ospsuite} 13.

  • DataCombined$toDataFrame() now returns the name and group columns as factors whose levels follow the order in which datasets (and groups) were added. As a result, plots built from DataCombined objects (plotTimeProfile(), plotPredictedVsObserved(), plotResidualsVsCovariate(), etc.) now display legend entries in the order DataSet and SimulationResults objects were added, rather than in alphabetical order. This also keeps name- and group-based legends consistent in observed-vs-predicted plots, where the two variables may otherwise diverge (#1968).

  • plotResidualsVsCovariate(), plotResidualsAsHistogram(), and plotQuantileQuantilePlot() now include the data unit in the y-axis label for residualScale = "linear" (e.g. "residuals [µmol/l]"). For "log" and "ratio" scales the residuals are dimensionless and no unit is shown. An empty-string unit (dimensionless data such as fractions) no longer produces empty brackets [] in the label.

  • ospsuite now installs and loads even when its native libraries or the .NET runtime cannot be initialised (for example on build machines that lack a compatible libxml2 or the .NET runtime), instead of failing at load time. The reason is reported when the package is attached and raised with an actionable message on the first call into the .NET API. Vignette code that requires the runtime is only executed when it is available. Together this allows the package to be built, checked, and resolved as a dependency in environments without a working runtime.

  • library(ospsuite) no longer changes the global ggplot2 theme and geom defaults: the {ospsuite.plots}-based plotting functions (plotTimeProfile(), plotPredictedVsObserved(), plotResidualsVsCovariate(), plotResidualsAsHistogram(), plotQuantileQuantilePlot()) now style each plot individually, and the styling of unrelated plots in the session is left untouched. As a consequence, the appearance of the deprecated {tlf}-based plotting functions may change slightly, since they no longer inherit the global theme (#1968).

  • Added isSupportedUnit() and validateIsNamedList() helper functions to the exported API.

  • Added dataCombinedAciclovir, a pre-built DataCombined object combining simulated and observed aciclovir data, exported for use in examples, vignettes, and tests.

  • loadDataSetsFromExcel() now treats an empty sheets vector (character(0)) the same as sheets = NULL, falling back to the configuration/all-sheets logic instead of overriding with no sheets.

  • plotIndividualTimeProfile() and plotPopulationTimeProfile() now produce a stable legend entry order when showLegendPerDataset = TRUE; previously the order of the dataset-name legend entries could vary between sessions.

  • convertSnapshot() is soft-deprecated in favor of two dedicated functions: loadProjectFromSnapshot() (snapshot .json -> project) and exportProjectToSnapshot() (project -> snapshot .json). convertSnapshot() still works but issues a deprecation warning and will be removed in a future release. Only PK-Sim projects (.pksim5) are supported for now; MoBi support is planned.