Changelog
pharmr.extra (development version)
update_parameters()now also accepts a rawnlmixr2FitCore/nlmixr2FitDataobject — useful when fitting outsiderun_nlme(). Both diagonal and off-diagonal omega elements are extracted and named per pharmpy’sIIV_X/IIV_X_IIV_Yconvention, so block-omega covariances are now updated alongside variance terms (previously dropped).run_nlme(),run_sim(), andcreate_vpc_data()now dispatch on the model engine. Pharmpy nlmixr-format models are routed through nlmixr2 / rxode2 directly (no pharmpypyreadrdependency). NONMEM models still use the existing nmfe / PsN / pharmpy paths unchanged.New
controlargument onrun_nlme()is forwarded tonlmixr2::nlmixr2()(e.g.foceiControl()); ignored for NONMEM.validate_model()now accepts nlmixr-format pharmpy models.get_advan()/get_obs_compartment()return gracefully for non-NONMEM models instead of erroring on the missing control stream.add_sir()now warns and no-ops for non-NONMEM models instead of silently doing nothing or aborting deep inside the covariance-record reader.call_pharmpy_tool()now forwardsesttool = "nlmixr"to pharmpy when a search tool (modelsearch,covsearch,iivsearch,ruvsearch,amd,bootstrap) is invoked with an nlmixr-format model. Pharmpy can drive these searches against nlmixr2 if the Python packagepyreadris installed and the system Rscript that pharmpy spawns has a working nlmixr2 / data.table install.compare_nlme_runs()now detects the engine per run folder and loads nlmixr2 fits from the saved<id>.rdsnext to the run directory, socompare_nlme_runs()works for nlmixr2 runs too.create_modelfit_info_table()is robust to fit objects reloaded from RDS whose pharmpy model attribute is no longer a live Python reference.create_vpc_data()on an nlmixr fit now uses the fitted model’s parameter estimates (was silently falling back to the pre-fit initial estimates when only afitwas supplied), and restrictsobsto observation rows so it matches the simulation row set.run_nlme_nlmixr()now stashes an explicitdataargument on the model so saved fits sim/VPC against the right dataset (previously the saved model still referenced the originalmodel$dataset).Initial CRAN submission.