Jasmine H Hughes, Kara Woo, Dominic MH Tong, Ron J Keizer
InsightRX
Objectives:
Most point-of-care model-informed precision dosing (MIPD) software tools use maximum likelihood (maximum a posteriori MAP Bayesian) estimation to adjust pharmacokinetic (PK) or pharmacodynamic (PD) parameter estimates in response to therapeutic drug monitoring samples or other biomarkers. While this approach is suitable for MIPD of drugs with relatively simple, linear PK such as vancomycin [1-3], for complex and/or nonlinear PK/PD models, these algorithms may not select the most likely parameters [4-5]. Probability of pharmacokinetic target attainment or of toxicity is an important part of the clinical decision-making process [3], however, while uncertainty around MAP estimates can be quantified based on the variance-covariance matrix [6], such approaches may not adequately reflect uncertainty for nonlinear PK/PD models.
Full Bayesian approaches, which typically leverage software tools such as Stan or BUGS, address these algorithmic limitations. However, there are few full Bayesian software implementations conducive to implementation of MIPD at the point of care. Torsten provides a library of PK/PD model implementations for use in Stan [7-8], however its design best supports population-level or individual-level analysis, and its high flexibility in model implementation comes at the price of increased complexity of incorporating these models in point-of-care software. Furthermore, application of full Bayesian algorithms requires translation of PK/PD models, which are typically developed in NONMEM or nlmixr, to a format recognized by full Bayesian software tools.
Methods:
Here, we present PKPDposterior, an open-source R package to conduct Markov chain Monte Carlo (MCMC) simulations to estimate the posterior patient PK parameter distribution. MCMC simulations are executed via cmdstanr in Stan, a probabilistic programming language and Hamiltonian Monte Carlo sampler [7], with the option to use Torsten model libraries [8]. For a given set of PK/PD parameters, ODE solving and concentration-time curve modeling are then carried out using the PKPDsim modeling framework [9], which powers existing MIPD software [2-3].
To facilitate development of full Bayesian solutions by pharmacometricians unfamiliar with Stan, this package additionally provides a convenient interface for defining new PK/PD models. Prior distributions and model structures can be provided as character strings, which are checked for syntax and converted to a Stan model. This design approach standardizes model inputs and outputs (covariate and variable names, posterior samples, etc), facilitating comparison between models, and allows for automation of new models. The package provides sample models for vancomycin, voriconazole and neutropenia, however this model definition interface provides the flexibility to implement a wide range of PK/PD models.
Results:
A typical workflow using PKPDposterior could be as follows:
- Compile a Stan model, or define one using PKPDposterior::new_stan_model
- Define patient medication history and covariates using the user-friendly APIs PKPDsim::new_regimen and PKPDsim::new_covariate
- Create a Stan-ready data set using these PKPDsim objects using PKPDposterior::PKPDsim_to_stan_data, or create one from a NONMEM-style dataset.
- Sample from the posterior distribution using PKPDposterior:get_mcmc_posterior
- Simulate posterior concentration-time curves with uncertainty using PKPDsim::sim
- Optionally, extract maximum likelihood estimates using PKPDposterior::extract_map_estimate, or plot posterior parameter distributions using PKPDposterior::plot_params
The package is available for installation via GitHub, and has 85% test coverage.
Conclusions:
PKPDposterior is an open source R package designed to enable individualization of PK/PD parameters and estimation of model prediction uncertainty using a full Bayesian approach, without requiring advanced knowledge of Stan syntax.
References:
[1] Wicha et al. (2021) CPT 10.1002/cpt.2202
[2] Hughes et al. (2021) CPT 10.1002/cpt.2088
[3] Frymoyer et al., Frontiers in Pharmacol. doi.org/10.3389/fphar.2020.00551
[4] Tong et al. (2022) PAGE 2022
[5] Maier et al. (2020) CPT:PSP 10.1002/psp4.12492
[6] Wicha et al. (2015) PAGE https://www.page-meeting.org/default.asp?abstract=3445
[7] Stan Development Team. mc-stan.org
[8] Metrum Research Group. github.com/metrumresearchgroup/Torsten/
[9] Keizer et al. https://CRAN.R-project.org/package=PKPDsim
Reference: PAGE 30 (2022) Abstr 10226 [www.page-meeting.org/?abstract=10226]
Poster: Methodology - Estimation Methods