Skip to contents

Implements adaptive single-point pharmacokinetic analysis to calculate clearance and volume of distribution.

Usage

run_single_point_base(
  dat,
  route = c("bolus", "oral", "infusion"),
  half_life = NULL,
  dose_type = NULL,
  pooled_ctrl = pooled_control(),
  ssctrl = ss_control()
)

Arguments

dat

A data frame containing raw time–concentration data in the standard nlmixr2 format.

route

Route of administration. Must be one of bolus, oral, or infusion.

half_life

Optional numeric value for drug half-life. If not provided, it is estimated from the dataset.

dose_type

Specifies the dosing context of the pharmacokinetic observations. Required when half_life is not provided. Classified as first_dose, repeated_doses, or combined_doses based on whether observed concentrations occur following the first administration, during repeated dosing, or across both contexts.

pooled_ctrl

Optional list of control parameters used by get_pooled_data() for pooling observations. Defaults to output from pooled_control().

ssctrl

A list of control parameters generated by ss_control() to guide the detection of steady-state observations.

Value

A list containing:

  • summary: a data frame with trimmed mean clearance and volume of distribution, and run time information

  • dat: the processed dataset used for analysis

  • cl_df: individual clearance estimates

  • vd_df: individual volume of distribution estimates

Details

This function integrates clearance and volume estimation into a unified adaptive workflow, using steady-state pharmacokinetic observations and trimmed mean statistics to reduce the influence of outliers.

Examples

dat <- Bolus_1CPT
out <- processData(dat)
#> 
#> 
#> Infometrics                               Value          
#> ----------------------------------------  ---------------
#> Dose Route                                bolus          
#> Dose Type                                 combined_doses 
#> Number of Subjects                        120            
#> Number of Observations                    6951           
#> Subjects with First-Dose Interval Data    120            
#> Observations in the First-Dose Interval   2276           
#> Subjects with Multiple-Dose Data          120            
#> Observations after Multiple Doses         4675           
#> ----------------------------------------  ------
fdat <- out$dat
route <- out$Datainfo$Value[out$Datainfo$Infometrics == "Dose Route"]
half_life <- get_hf(dat = fdat)$half_life_median
#> Estimating half-life....................
#> Half-life estimation complete: Estimated t1/2 = 11 h
run_single_point_base(dat = fdat, half_life = half_life, route = route)$summary
#>     cl   vd          start.time time.spent
#> 1 3.04 67.6 2026-06-09 11:11:06      1.401