AUC.Rd
Calculate Area Under the Curve(AUC) and the first Moment Curve(AUMC) in two ways; 'linear trapezoidal method' or 'linear-up and log-down' method. Return a table of cumulative values.
AUC(x, y, down = "Linear")
vector values of independent variable, usually time
vector values of dependent variable, usually concentration
either of "Linear"
or "Log"
to indicate the way to calculate AUC and AUMC
down="Linear"
means linear trapezoidal rule with linear interpolation.
down="Log"
means linear-up and log-down method.
Table with two columns, AUC
and AUMC
; the first column values are cumulative AUCs and the second column values cumulative AUMCs.
Rowland M, Tozer TN. Clinical Pharmacokinetics and Pharmacodynamics - Concepts and Applications. 4th ed. pp687-689. 2011.
AUC(Theoph[Theoph$Subject==1, "Time"], Theoph[Theoph$Subject==1, "conc"])
#> AUC AUMC
#> [1,] 0.00000 0.000000
#> [2,] 0.44750 0.088750
#> [3,] 1.95310 0.801534
#> [4,] 6.64735 5.065382
#> [5,] 15.71935 19.138321
#> [6,] 32.13535 66.198241
#> [7,] 42.97695 114.461665
#> [8,] 58.25290 206.281512
#> [9,] 72.75650 322.298798
#> [10,] 92.45055 528.521903
#> [11,] 148.92305 1459.071104
AUC(Theoph[Theoph$Subject==1, "Time"], Theoph[Theoph$Subject==1, "conc"], down="Log")
#> AUC AUMC
#> [1,] 0.00000 0.000000
#> [2,] 0.44750 0.088750
#> [3,] 1.95310 0.801534
#> [4,] 6.64735 5.065382
#> [5,] 15.71410 19.243482
#> [6,] 32.11090 66.830600
#> [7,] 42.95189 115.151380
#> [8,] 58.21173 207.426110
#> [9,] 72.70744 323.774418
#> [10,] 92.36544 531.108538
#> [11,] 147.23475 1499.129085