nlmixr2plot
5.2.1Nonlinear Mixed Effects Models in Population PK/PD, Plot Functions
Overview
Fit and compare nonlinear mixed-effects models in differential equations with flexible dosing information commonly seen in pharmacokinetics and pharmacodynamics (Almquist, Leander, and Jirstrand 2015 doi:10.1007/s10928-015-9409-1). Differential equation solving is by compiled C code provided in the 'rxode2' package (Wang, Hallow, and James 2015 doi:10.1002/psp4.12052). This package is for 'ggplot2' plotting methods for 'nlmixr2' objects.
- The model-diagram test of a long product no longer checks how long
modelGraph()takes, and is skipped on CRAN. The timing check failed at random on loaded CRAN machines (48 s against a 30 s limit). plot()no longer fails on a fit with more than one variance level. A model with between-occasion variability reportsomegaas a list holding one matrix per level rather than as a single matrix, and the between-subject-variability guard testednrow(omega) > 0, which isNAfor a list, soplot()stopped with "missing value where TRUE/FALSE needed" before drawing anything. The guard now asks whether the fit reports any between-subject eta, which is what the BSV plots need and does not depend on the number of variance levels.- The between-subject-variability plots now take their etas from the subject-level
omegablock (dropping any fixed at zero) rather than from every columnranef()returns, so a mixture fit no longer gets a QQ plot of itsmixnumsubpopulation labels or a spurious correlation panel, and an occasion-only fit is correctly treated as having no BSV.
Show all changes in 5.2.1Hide the rest of the changes in 5.2.1
plot()of a fit,vpcPlot()andplot()of anaugPred()object now emit onefitResultevent on the rxode2 event bus (when rxode2 has one) with the plots they made, so loggers such as nlmixr2log can store them with the fit. Simulations done insidevpcPlot()emit nothing. Without a listener nothing changes.modelDiagram(..., engine = "ggplot2", labels = TRUE)now draws the arrow labels on a white background, so the arrow no longer runs through the label text.plot()of anaugPred()object no longer titles a single-endpoint figure with the last endpoint of an earlier multiple-endpoint plot.- The figures from
plot()of a fit,traceplot()andplot()of anaugPred()object no longer carry the fit, the full plotting data or the other figures in their environments, so saving them (withsaveRDS()or as a 'targets' target) is far smaller. Before, each figure'saes(), facet and layer environments held the frame it was built in, and with it the whole fit or every figure built before it (the trace plot and the individual plots could each serialize to hundreds of MB). Each figure now stores its data once, in$data; the plots look the same. - The VPC figures from
vpcPlot(),vpcPlotTad(),vpcCens()andvpcCensTad()no longer carry the VPC simulation, and withmethod = "tidyvpc"no longer carry the fit either. 'vpc' built its figure in about a dozen frames that each held the whole simulation, and the tidyvpc figure kept the frame ofvpcPlot()itself, so saving a VPC of a 1500-observation fit with 50 simulations wrote 97 MB ('vpc') or up to 34 MB ('tidyvpc'). The 'vpc' figure now takes about 3 MB, and neither grows with the number of simulations. The figures look the same. - The
engine = "ggplot2"diagram frommodelDiagram()no longer keeps its layer data and a second copy of itself in its environments, and adds its scales last; together about 1 MB (up to 3.4 MB for large models) less for each saved diagram. The diagrams look the same. - The
bootplotfigure thatplot()includes for a fit with bootstrap results no longer carries the frame ofplot(), with the plotting data and every other figure: for theo_sd with 3 bootstrap samples it went from 152 MB to 6 MB saved. It still carries the fit, whichnlmixr2extra::bootplot()keeps in its own frame.
From NEWS.md in the release
Install
Health
- OK13 OK2026-10-14
- ERROR12 OK, 1 ERROR2026-10-13
- OK13 OK2026-10-08
- ERROR12 OK, 1 ERROR2026-09-15
- OK13 OK2026-08-20
Show 6 earlier changesHide 6 earlier changes
- ERROR12 OK, 1 ERROR2026-08-18
- OK13 OK2026-08-12
- ERROR11 OK, 2 ERROR2026-07-23
- OK13 OK2026-06-09
- ERROR12 OK, 1 ERROR2026-06-08
- OK14 OK2026-03-10
Documentation
- Help pages
- 7 (1 internal)
- Examples that run
- 0%6 only when donttest examples are enabled (R CMD check --as-cran)
- Exported functions with examples
- 80%
- Documented parameters
- 100%
- Return-value docs
- 80%
- Help pages citing references
- 0%
Downloads
Repository
- PRs merged (all time)
- 96%
- Median days to close, 50 most recently updated closed issues
- 22
- Median days to close, 50 most recently updated closed PRs
- 1
Releases over time
Issues over time
PRs over time
Commits over time
13 development-tooling and community-health practices detected across 6 families in the upstream repository
Checks run against github.com/nlmixr2/nlmixr2plot on 2026-10-11.
The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel
GitHub Pages site last deployed 2026-10-08 · The repository has a site deploy workflow
pkgdown site last built 2026-10-08, before release 5.2.1 (2026-10-16)
Show all practicesHide 2 practices
This repository shows signs of AI coding tools.
- GitHub Copilotfirst seen 2026-02-27Pull request: opened by its own accountCommits: 2 by its own account
- Claude Codefirst seen 2026-05-27Pull request it wrote: opened by a project memberCommits: at least 33 crediting it in the message
- Claude Opus 4.811 commits · Jun to Jul 2026
- Claude Opus 5.511 commits · Sep 2026
- Claude Opus 59 commits · Jul to Aug 2026
- Claude Fable 51 commit · Jul 2026
- Claude Opus 4.71 commit · May 2026
Dependencies
Installing nlmixr2plot adds 136 packages (87 with compiled code, 110 MB of source tarballs). Heaviest: BH 14 MB, stringi 11 MB, ggplot2 6.0 MB.
CRAN will archive these unless their check problems are fixed by the date shown. This package needs each one to install.
- nlmixr2estfix by Oct 23
Code & Tests
People & History
Pick two releases to compare their code metrics.
- 5.2.1Latest2026-10-16 · current release · diff ↗ ·
listed once in CRAN's queue
Seen in one reading of CRAN's incoming queue, at 2026-10-16 17:07 UTC, so it stayed less than the time between readings. It was also listed earlier, first on 2026-10-15 12:21 UTC, and left the queue for more than a day before this stay. - 5.2.0
- 5.1.02026-08-05 · diff ↗
- 5.0.22026-06-11 · diff ↗
- RR 4.6.0 released · 2026-04-24
- 5.0.12026-02-28 · diff ↗
- 5.0.02025-11-29 · diff ↗
- 3.0.32025-08-23 · diff ↗
- 3.0.22025-06-25 · diff ↗
- RR 4.5.0 released · 2025-04-11
- 3.0.12025-02-14 · diff ↗
- 3.0.02024-09-18 · diff ↗
- 2.0.92024-05-29 · diff ↗
- RR 4.4.0 released · 2024-04-24
- 2.0.82024-01-31 · diff ↗
- RR 4.3.0 released · 2023-04-21
Package metadata
- First published
- 2022-05-23
- Total releases
- 14 / 4 yrs
- License
- GPL (>= 3) OSI
- Minimum R
- ≥ 4.3.0
- Download size
- 1.7 MB
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("nlmixr2plot")This package has no citation file, so citation() returns this entry built from DESCRIPTION.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-17, which the citation names so these numbers can be found later. More on citing and the projects behind them.