| sim_sens_2cmpt | R Documentation |
Performs parameter sweeping by varying pharmacokinetic parameters in a two-compartment model under IV or oral dosing. Model fit is evaluated across combinations of CL, Vc, Vp, Q, and Ka (oral only).
sim_sens_2cmpt(
dat,
sim_ka = list(mode = "manual", values = NULL),
sim_cl = list(mode = "manual", values = NULL),
sim_vc = list(mode = "manual", values = NULL),
sim_vp = list(mode = c("auto", "manual"), values = NULL),
sim_q = list(mode = c("auto", "manual"), values = NULL, auto.strategy = c("scaled",
"fixed")),
route = c("iv", "oral"),
verbose = TRUE
)
dat |
Pharmacokinetic dataset. |
sim_ka |
List specifying Ka (oral route only):
|
sim_cl |
List specifying clearance (CL):
|
sim_vc |
List specifying central volume (Vc):
|
sim_vp |
List specifying peripheral volume (Vp):
|
sim_q |
List specifying inter-compartmental clearance (Q):
|
route |
Dosing route, either "iv" or "oral". Default is "iv". |
verbose |
Logical (default = TRUE).
Controls whether progress information is displayed during parameter sweeping.
When TRUE, a dynamic progress bar is shown using the |
The function generates a parameter grid and performs model fitting for each
combination using Fit_2cmpt_iv or Fit_2cmpt_oral. Parameters can be
specified manually or automatically derived. Model predictions and fit metrics
are computed for each simulation to assess parameter sensitivity.
A data frame containing parameter combinations with model fit metrics.
Zhonghui Huang
Fit_2cmpt_iv, Fit_2cmpt_oral
out <- sim_sens_2cmpt(
dat = Bolus_2CPT[Bolus_2CPT$ID<50,],
sim_cl = list(mode = "manual", values = 4),
sim_vc = list(mode = "manual", values = 50),
sim_vp = list(mode = "auto"),
sim_q = list(mode = "auto"),
sim_ka = list(mode = "manual", values = NA),
route = "iv",verbose=FALSE
)
head(out[out$rRMSE2==min(out$rRMSE2),])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.