Sunday, April 5, 2015

Hierarchical Two Compartimental PK Model

In this post I am running the Theoph dataset from MEMSS (Data sets and sample analyses from Pinheiro and Bates, "Mixed-effects Models in S and S-PLUS" (Springer, 2000)) in a JAGS model. To quote the MEMSS manual:
'Boeckmann, Sheiner and Beal (1994) report data from a study by Dr. Robert
Upton of the kinetics of the anti-asthmatic drug theophylline. Twelve subjects
were given oral doses of theophylline then serum concentrations were measured at
11 time points over the next 25 hours. These data are analyzed in Davidian and Giltinan (1995) and Pinheiro and
Bates (2000) using a two-compartment open pharmacokinetic model, for which a
self-starting model function, SSfol, is available.'

Model

The model which is used in the example for the data is SSfol. Its value is:

With input the time variable. This looks very complex, but there seems to be a trick here. What is estimated is not Ke (elimination rate) but its natural logarithm. The same is true for Ka and CL. This is probably done to keep the parameters positive. So in terms of ordinary parameters:

Dose * (Ke+Ka)/CL * (exp(-Ke*input) - exp(-Ka*input)) / (Ka - Ke)

This looks much more simple.

Estimates using nls

The example code uses nls() to fit the model. Below the model is wrapped in an apply. In addition, the exponent is taken.

No comments:

Post a Comment

Wiekvoet

Wiekvoet is about R, JAGS, STAN, and any data I have interest in. Topics range from sensometrics, statistics, chemometrics and biostatistics. For comments or suggestions please email me at wiekvoet at xs4all dot nl.