Aims: nlmixr is an open-source R package under development that builds on both RxODE1, an R package for simulation of nonlinear mixed effect models using ordinary differential equations (ODEs), and the nlme2 package in R, for parameter estimation in nonlinear mixed effect models. nlmixr greatly expands the utility of nlme by providing an efficient and versatile way to specify pharmacometric models and dosing scenarios, with rapid execution due to compilation in C++. NONMEM®3 with first-order conditional estimation with interaction was used as a comparator to test nlmixr.
Methods: Richly sampled profiles were simulated for 4 different dose levels (10, 30, 60 and 120 mg) of 30 subjects each as single dose (over 72h), multiple dose (4 daily doses), single and multiple dose combined, and steady state dosing, for a range of test models: 1- and 2-compartment disposition, with and without 1st order absorption, with either linear or Michaelis-Menten (MM) clearance (MM without steady state dosing). This provided a total of 42 test cases. All inter-individual variabilities (IIVs) were set at 30%, residual error at 20% and overlapping PK parameters were the same for all models. A similar set of models was previously used to compare NONMEM and Monolix4. Estimates of population parameters, standard errors for fixed-effect parameters, and run times were compared both for closed form solutions and using ODEs.
Results: Parameter estimates were comparable across estimation methods; Figure 1 provides results for central volume of distribution (Vc) as illustration because it is the single parameter present in all models. In comparison to NONMEM, nlmixr was always faster for ODEs (MM-models) and comparable for closed form models. Standard error estimates were obtained for all nlmixr models, but not all NONMEM models. IIV estimates were regularly estimated close to 0% for ill-defined model parameters (e.g. for inter-compartmental clearance and peripheral volume), in nlmixr, whereas NONMEM provided estimates closer to the original simulation values.
Figure 1. Fixed effects (top left) and IIV (bottom left) estimates for Vc, residual error (top right) and log run times (bottom right) comparing NONMEM (grey lines) and nlmixr (black lines). Horizontal black line: value used for simulation.
Conclusion: These findings suggest that nlmixr provides a viable open-source parameter estimation procedure for nonlinear mixed effects pharmacometric models within the R environment.
1. Wang W et al. CPT:PSP (2016) 5, 3–10.
3. Pinheiro J et al. (2016). nlme: Linear and Nonlinear Mixed Effects Models. R package version 3.1-126,
4. Beal SL et al. 1989-2011. NONMEM Users Guides. Icon Development Solutions, Ellicott City, Maryland, USA.
5. Laveille C et al PAGE 17 (2008) Abstr 1356 [www.page-meeting.org/?abstract=1356]