correct.conc: Correct Missing Concentration

Description Usage Arguments Details Value Examples

View source: R/correct.conc.r

Description

Corrects missing concentration at critical time points (e.g, predose, TAU, start and end of user selected AUC interval).

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
correct.conc(
  x,
  by = character(0),
  nomtimevar = "ntad",
  tau = NA,
  tstart = NA,
  tend = NA,
  teval = NA,
  th = NA,
  reg = "SD",
  ss = "N",
  route = "EV",
  method = 1
)

Arguments

x

input dataset name (after Time Deviation Correction Rules have been applied by correct.time)

by

column names in x indicating grouping variables

nomtimevar

variable name containing the nominal sampling time after dose

tau

dosing interval (for multiple dosing); NA (default) for if single dose; x$tau overrides

tstart

start time of partial AUC (start>0); NA (default) if not requested; x$tstart overrides

tend

end time of partial AUC; NA (default) if not requested; x$tend overrides

teval

user selected AUC interval; NA (default) if not requested; x$teval overrides

th

lamdba_z information for each curve; like output of est.thalf

reg

regimen, "sd" or "md"; x$reg overrides

ss

is steady state reached (y/n); x$ss overrides

route

route of drug administration ("EV","IVB","IVI"); x$route overrides

method

method for trapezoidal rule; x$method overrides

  • 1: linear up - linear down

  • 2: linear up - logarithmic down

  • 3: linear before first Tmax, logarithmic after first Tmax

Details

The following Concentration Deviation Correction Rules will be applied to critical time points (t=0, tau, tstart, tend, teval), if needed:

Rule Regimen Description Applied to
SDC-1 sd Set concentration to 0 (only non-endogenous compounds) t=0
SDC-2 sd impute missing concentration by interpolation t=tau,tstart,tend,teval
SDC-3 sd impute missing concentration by extrapolation t=tau,tend,teval
SDC-4 sd (IVB) impute missing concentration by back-extrapolation t=0
MDC-1 md impute missing concentration by existing conc at t=0 or t=tau (only if steady state has been reached) t=0,tau
MDC-2 md impute missing concentration by interpolation t=tau,tstart,tend,teval
MDC-3 md impute missing concentration by extrapolation t=tau,tend,teval
MDC-4 md (IVB) impute missing concentration by back-extrapolation t=0

Value

a dataset with missing concentrations imputed. The following variables are added:

Variable Description
crule.nr correction rule number
crule.txt text explaining what was altered
applies.to.conc lists all critical time points to which the concentration correction rule applies

Examples

1
2
3
4
5
example(correct.time)
x %<>% mutate(ss = 'N', route = 'EV')
# route redefined for completeness
x %<>% correct.conc(by = 'subject') # ignoring th
x %>% head

qpNCA documentation built on Aug. 16, 2021, 5:08 p.m.