PK model examples

Knowledge of how to do basic tasks using the Phoenix interface, such as creating a project and importing data, is assumed.

Fit a PK model to data example

This example is about creating and saving PK models in Phoenix and supposes that a researcher has obtained concentration data from one subject after oral administration of a compound, and now wishes to fit a pharmacokinetic (PK) model to the data.

The completed project (PK_Model.phxproj) is available for reference in …\Examples\Win­Nonlin.

Explore the PK input data

  1. Create a new project.

  2. Rename the project as PK Model.

  3. Import the file …\Examples\WinNonlin\Supporting files\study1.CSV.
    In the File Import Wizard dialog, select the Has units row option and click Finish.

  4. Right-click Workflow in the Object Browser and select New > Plotting > XY Plot.

  5. Drag the study1 worksheet from the Data folder to the XY Data Mappings panel.
    Leave Subject mapped to the None context.
    Map Time to the X context.
    Map Conc to the Y context.

  6. Click icon_execute_113.png to execute the object. The results are displayed on the Results tab.

  7. In the Options tab below the plot, select Axes > Y from the menu tree.

  8. Select the Logarithmic option button in the Scale area. Leave the logarithmic base set to 10.
    The XY Plot is automatically updated to reflect the scale change.

Set up the object

The plots suggests that the system might be adequately modeled by a one-compartment, 1st order absorption model. This model is available as Model 3 in the pharmacokinetic models included in Phoenix. Set up a PK Model object and a Phoenix Model object, for comparison.

PK Model object 

  1. Right-click Workflow in the Object Browser and select New > WNL 5 Classic Modeling > PK Model.

  2. With the new PK Model object selected in the Object Browser, drag the study1 worksheet from the Data folder to the Main Mappings panel.
    Map Subject to the Sort context.
    Leave Time mapped to the Time context.
    Map Conc to the Concentration context.

  3. In the Model Selection tab below the Setup panel, check the Number 3 model checkbox.

Entering the units for dosing data makes it possible to view and adjust units for the model parameters.

In this example, a single dose of 2 micrograms was administered at time zero.

  1. Select the Dosing panel in the Setup tab.

  2. Check the Use Internal Worksheet checkbox.

  3. Click OK in the Select sorts dialog to accept the default sort variable.

  4. In the cell under Time type 0.

  5. In the cell under Dose type 2.

  6. In the Weighting/Dosing Options tab below the Setup panel, type ug in the Unit field.

PKmodelWghtDosingOptstab.png 

All model estimation procedures benefit from initial estimates of the parameters. While Phoenix can compute initial parameter estimates using curve stripping, this example will provide user values for the initial parameter estimates.

  1. Select the Parameter Options tab below the Setup panel.

  2. Select the User Supplied Initial Parameter Values option.
    The WinNonlin Bounds option is selected by default as the Parameter Boundaries. Do not change this setting.

  3. Select Initial Estimates in the Setup panel list.

  4. Check the Use Internal Worksheet checkbox.

  5. Click OK to accept the default sort variable in the Select sorts dialog.

  6. Enter the following information in the table:
    For row 1 (V_F), enter 0.25 in the Initial column.
    For row 2 (K01), enter 1.81 in the Initial column.
    For row 3 (K10), enter 0.23 in the Initial column.

Phoenix Model object 

  1. Right-click the study1 worksheet in the Data folder and select Send To > Phoenix Modeling > Phoenix Model.

  2. In the Structure tab, uncheck the Population box.

  3. Click the Set WNL Model button.
    The contents of the Structure tab changes. The first of the two untitled menus allows users to select a PK model, and the second allows users to select a PD model.

  4. In the first untitled menu, select 3 (1cp extravascular).

  5. Click Apply to set the WinNonlin model.

  6. Use the option buttons in the Main Mappings panel to map the data types to the following contexts:
    Subject to the Sort context.
    Time to the Time context.
    Conc to the CObs context.

The WARNINGS tab at the bottom highlights potential issues. If there are no issues, the tab will be labeled “no warnings”. Click the WARNINGS tab and note the message that Aa values are missing. This will be taken care of in the next few steps.

In this example, a single dose of 2 micrograms was administered at time zero. However, since the concentration units were ng/mL, the dose should be entered as 2000ng so the units are equivalent.

  1. Select the Dosing panel in the Setup tab.

  2. Check the Use Internal Worksheet checkbox.

  3. In the cell under Aa type 2000.

  4. In the cell under Time type 0.

  5. Click View Source above the worksheet.

  6. In the Columns tab below the table, select Aa from the Columns list and enter ng in the Unit field.

  7. Click X in the upper right corner to close the source window (the units are added to the column header).

Notice that the warning about Aa values is gone and the tab label now says “no warnings.”

The NLME engine will not generate its own initial estimates, like the WNL Classic engine can, so it is important to consider reasonable starting values.

  1. Select the Initial Estimates tab in the lower panel.

  2. Extend the Duration to 15, since the last observed timepoint is 14 hours.

  3. Enter values 2, 300, and 0.1 for tvKa, tvV, and tvKe, respectively.

  4. PKExample1InitialEstSettings.png 

    The y axis can also be set to log scale and, if there is more than one profile, the curves can be overlaid by checking the log and overlay boxes, respectively.

    Note how the predicted curve roughly follows the observed data now.

    PKExample1InitialEstGraph.png 

  5. Click the blue arrows to submit these values to the main model engine (if the arrow is blue, then the value will not be used).

Execute and view the results

At this point, all of the necessary commands and options have been specified.

  1. Select the Workflow object in the Object Browser and click icon_execute_114.png to execute the all objects in the workflow. The results are displayed in the Results tab.

The Results tab contains three types of model output:

Worksheets (descriptions of the worksheets are located in the “Worksheet output” section)

Plots

Text output

The six plots generated by the PK Model object are shown below. The NLME object generates more plots, however the ones corresponding to the WinNonlin output are listed in parentheses.

pkmodelObsYPredYvsX.png 

Observed Y and Predicted Y vs X (Ind DV, IPRED vs TAD)

pkmodelPartialDerivatives.png 

Partial Derivatives plot (Ind Partial Derivatives)

pkmodelPredYvsObsY_1.png 

Predicted Y vs Observed Y (Ind DV vs IPRED, axes swapped)

pkmodelPredYvsX.png 

Predicted Y vs X

pkmodelResidualYvsPredY.png 

Residual Y vs Predicted Y (Ind IWRES vs IPRED)

pkmodelResidualYvsX_1.png 

Residual Y vs X (Ind IWRES vs TAD)

The tables generated by the Phoenix Model summarize useful information.

Overall: Contains -2LL (the objective function) and other goodness of fit information

Theta: Final parameter estimates

Residuals: Analogous to Summary Table of WNL classic and NCA models

To compare the two models, create a worksheet by appending the Final Parameters worksheet from the PK model to the Theta worksheet from the Phoenix Model. (See “Append Worksheet” for specifics on how to append worksheets.)

PKExample1Append.png 

The Core Output text file contains all model settings and output in plain text format. Below is part of the Core Output file from the Phoenix Model run.

PKExample1ModelCore.png 

Save the project and the results

Projects and their results can be saved as a project file or loaded into Integral.

To save the project as a file:

  1. Select File > Save Project.

  2. In the Save Project dialog, select a directory in the Save in menu or use the default directory.

  3. Type a name in the File name field or use the default name and click Save.

  4. The project is saved as a Phoenix Project (.phxproj) file.

    For details on adding the project to Certara Integral, see “Adding a project to Integral”.

  5. Close the project by right-clicking the project in the Object Browser and selecting Close Project.

Simulation and study design of PK models example

Considerable research has been done in the area of optimal designs for linear models. Most methods involve computation of the variance covariance matrix. The “optimal” design is usually one in which replicate samples are taken at a limited number of combinations of experimental conditions. Unfortu­nately, these methods are of little or no value when designing experiments involving nonlinear models for a number of reasons, including:

It can be difficult or, in the case of a pharmacokinetic study, impossible to obtain replicate observations.

The primary interest often is not in the model parameters but in some functions of the model parameters such as AUC, t1/2, etc.

When Phoenix performs a simulation, the output includes information on precisely how parameters in the model can be estimated for specified values of the independent variables, such as time.

Assume that a study is being planned and that the data produced by this study should be consistent with Phoenix PK model 3. Assume also that the parameter values should be approximately: V_F=10, K01=3, K10=0.05 and one of the following study designs, or sampling times, will be used:

0, 1.5, 3, 6, 9, 12, 15, 18, and 24 hours
or
0, 0.5, 1, 2, 4, 8, 12, 24, and 36 hours.

Simulation can be used to determine which set of sampling times would produce the more precise estimates of the model parameters. This example will use Phoenix to simulate the model with each set of sampling times, and compare the variance inflation factors for the two simulations.

The completed project (Study_Design.phxproj) is available for reference in …\Exam­ples\WinNonlin.

Create the input dataset

  1. Create a new project with the name Study Design.

  2. Right-click the Data folder in the Object Browser and select New > Worksheet.

  3. Name the new worksheet Example Data.

  4. In the Columns tab, add a column identifying the group number by clicking Add underneath the Columns list.

  5. In the New Column Properties dialog, type Group in the Column Name field. Leave the data type set to Numeric, and click OK.

  6. In the first cell under Group, type 1 and press ENTER. Continue to enter 1 for rows 2–9.

  7. In rows 10–18 type 2 in the Group column.

  8. Add a column of time data by clicking Add underneath the Columns list.

  9. In the Column Name field, type Times. Leave the data type set to Numeric and click OK.

  10. Type the values 0, 1.5, 3, 6, 9, 12, 15, 18, and 24 in the Times column for rows 1–9 and values 0, 0.5, 1, 2, 4, 8, 12, 24, and 36 for rows 10–18. (Alternatively, the data can be imported from …\Examples\WinNonlin\Supporting files\Example Data.csv.

Set up the object

This model is available as Model 3 in the pharmacokinetic models included in Phoenix.

  1. Right-click Workflow and select New > WNL5 Classic Modeling > PK Model.

  2. Drag the Example Data worksheet from the Data folder to the Main Mappings panel.
    Map Group to the Sort context.
    Map Times to the Time context.

  3. In the Model Selection tab below the Setup panel, specify the PK model that Phoenix will use in the analysis by selecting the Number 3 model checkbox.

  4. Select the Simulation checkbox on the right side of the Model Selection tab (notice that the Con­centration mapping is changed from required (orange) to option (gray)).

  5. In the Y Units field, type ng/mL.

  6. Enter the dosing data by selecting the PK Model's Dosing panel in the Setup tab.

  7. Check the Use Internal Worksheet checkbox.

  8. Click OK in the Select sorts dialog to accept the default sort variable.

  9. In the Time column type 0 for both groups.

  10. In the Dose column type 100 for both groups.

  11. Note:The number of rows in the Group column corresponds to the number of doses received. For example, if group 1 had 10 doses, there would be 10 rows of dosing information for group 1. In Phoenix this grouping of data is referred to as stacking data.

  12. In the Weighting/Dosing Options tab below the Setup panel, type mg in the Unit field.

  13. Select the Parameter Options tab.

    Parameter values must be specified for simulations. The User Supplied Initial Parameter Values option is selected and cannot be changed. The Do Not Use Bounds option is selected by default and cannot be changed.

    Selecting the Simulation checkbox makes the parameter calculation and boundary selection options unavailable. If the Simulation checkbox is selected, then users must supply initial param­eter values, and parameter boundaries are not used.

  14. Select Initial Estimates in the Setup list.

  15. Check the Use Internal Worksheet checkbox.

  16. In the Select sorts dialog, click OK to accept the default sort variable.

  17. Enter the following initial values for each group: V_F=10, K01=3, K10=0.05.

Execute and view the results

All the settings are complete and the model can be executed.

  1. Click icon_execute_115.png to execute the object.

The variance inflation factors (VIF) for each dosing scheme (groups 1 and 2) are located in the Final Parameters worksheet and are summarized (with values rounded) in the following table.

VIF summary

Parameter

Estimate

Group 1 VIF

Group 2 VIF

V_F

10

0.779

0.657

K01

3

68.48

1.176

K10

0.05

0

0

In practice, it is useful to vary the values of V_F, K01, and K10 and repeat the simulations to deter­mine if the first set of sampling times consistently yields less precise estimates than the second set.

Design the sampling plan

Note that, for the parameters V_F and K10, the estimated variances would be approximately 15% lower using the second set of times, while the difference is much more dramatic for the parameter K01. These sets of variance inflation factors indicate that the second set of sampling times would pro­vide tighter estimates of the model parameters.

The partial derivatives plots for this model explain this result. The locations at which the partial deriv­ative plots reach a maximum or a minimum indicate times the model is most sensitive to changes in the model parameters, so one approach to designing experiments is to sample where the model is most sensitive to changes in the model parameters.

  1. Click Partial Derivatives Plot in the Results tab.

  2. simstudyPartialDerivGroup1.png 

    Partial Derivatives plot Group 1

  3. Select the Page 02 tab below the plot.

  4. simstudyPartialDerivGroup2.png 

    Note that in the first plot of the partial derivatives the model is most sensitive to changes in K10 at about 20 hours. Both sampling schemes included times near 20 hours, so therefore the two sets of sampling times were nearly equivalent in the precision with which K10 would be estimated.

    For both V_F and K01 the model is most sensitive to changes very early, at about 0.35 hours for K01 and about 1.4 hours for V_F. The first set of sampling times does not include any post-zero points until hour 3, long past these areas of sensitivity. Even the second set of times could be improved if samples could be taken earlier than 0.5 hours.

    This same technique could be used for other models in Phoenix or for user-defined models.

  5. Close this project by right-clicking the project and selecting Close Project.

More WNL5 Classic modeling examples

Knowledge of how to do basic tasks using the Phoenix interface, such as creating a project and importing data, is assumed.

The examples project Model_Examples.phxproj located in …\Examples\WinNonlin involve WNL5 classic modeling objects. Each model object within this project contains the appropri­ate default mappings and settings needed to run the model.

To run these example objects:

  1. Load the project …\Examples\WinNonlin\Model_Examples.phxproj into Phoenix.

    Each example model has the following items associated with it:

  2. A dataset in workbook form.

    Many have datasets in workbook form for dosing.

    A PK, PKPD, Indirect Response, or an ASCII model object.

  3. Explore each model object and its mappings and settings.

  4. Click icon_execute_116.png to execute each model. The results are displayed on the Results tab.

Explanations for each model object in the example is given below.

Pharmacokinetic model (Exp1)

In the Exp1 example, a dataset was fit to PK model 13 in the pharmacokinetic model library. Four con­stants are required for model 13: the stripping dose associated with the parameter estimates, the number of doses, the dose, and the time of dosing.

This example uses weighted least squares (1/observed Y). Phoenix determines initial estimates via curve stripping and then generates bounds for the parameters.

Pharmacokinetic model with multiple doses (Exp2)

In the Exp2 example, a dataset obtained following multiple dosing is fit to model 13 in the pharmaco­kinetic model library, which is a two-compartment open model. This model has five parameters: A, B, K01, Alpha, and Beta and uses the user-supplied initial values 20, 5, 3, 2, and 0.05. Phoenix gen­erates bounds for the parameters.

Probit analysis: maximum likelihood estimation of potency (Exp3)

The Exp3 example demonstrates how to use the NORMIT and WTNORM functions to perform a pro­bit regression (parallel line bioassay or quantal bioassay) analysis. Note that a probit is a normit plus five. There are several interesting features used in this example:

Method 3 is selected, which is recommended for Maximum Likelihood estimation (MLE), and iterative reweighting problems.

Convergence Criterion is set to 0. This turns off convergence checks for MLE.

Iterations are set to 10. Estimates should converge after a few iterations.

Meansquare is set to 1. Sigma squared is 1 for MLE.

For further reading regarding use of nonlinear least squares to obtain maximum likelihood estimates, refer to Jennrich and Moore (1975). Maximum likelihood estimation by means of nonlinear least squares. Amer Stat Assoc Proceedings Statistical Computing Section 57–65.

Logit regression (bioassay) (Exp4)

The following data were obtained in a toxicological experiment:

Example data

Dose (mg)

# DoseD (n)

# Died (Y)

300

50

15 (30%)

1000

20

9 (45%)

3300

26

19 (73%)

10000

12

12 (100%)

In the Exp4 example, assume that the distribution of Y is binomial with:

mean=np

variance=npq, and q=1 – p

where pkexamples02536.png and X=loge dose

Maximum likelihood estimates of a and b for this model are obtained via iteratively reweighted least squares. This is done by fitting the mean function (np) to the Y data with weight (npq) –1.

The modeling commands needed to fit this model to the data are included in an ASCII model file. Note that the loge LD50 and loge LD001 are also estimated as secondary parameters.

This model is really a linear logit model in that:

pkexamples02538.png 

(1)

Note:For this type of problem, the final value of the residual sum of squares is the Chi-square statistic for testing heterogeneity of the model. If this example is run a user obtains X2 (heterogene­ity)=2.02957, with 4 – 2=2 degrees of freedom (number of data points minus the number of param­eters that were estimated).

For a more in-depth discussion of the use of nonlinear least squares for maximum likelihood estima­tion, see Jennrich and Moore (1975). Maximum likelihood estimation by means of nonlinear least squares. Amer Stat Assoc Proceedings Statistical Computing Section 57–65.

In the Engine Settings tab, the Convergence Criteria is set to zero to turn off the halving and conver­gence checks. Meansquare is set to 1 (the residual mean square is redefined to be 1.00) in order to estimate the standard errors of a, b, and the secondary parameters.

Survival analysis (Exp5)

Exp5 is another maximum likelihood example and is very similar to Model Exp4. It is included to show that models arising in a variety of disciplines, such as case survival or reliability analysis, can be fit by nonlinear least squares.

The dosing constant is defined in this model as the denominator for the proportions, that is, N.

In the Engine Settings tab the Convergence Criteria is set to zero to turn off the halving and conver­gence checks. Meansquare is set to 1 (redefines the residual mean square to be 1.00) in order to esti­mate the standard errors of the primary and secondary parameters.

Two differential equations with data for both compartments (Exp6)

Exp6 involves the following model:

inset_0.png

 

where K12 and K20 are first-order rate constants. This model may be described by the following system of two differential equations.

pkexamples02541.png compartment 1
pkexamples02543.png compartment 2

(2)

with initial conditions Z1=D, and Z2=0.

In addition to obtaining estimates of K12 and K20, it is also desirable to estimate D and the half-lives of K12 and K20.

A sample solution for this example is given here. Note that, for this example, the model is defined as an ASCII file. Data corresponding to both compartments are available.

Column C in the dataset for this example contains a function variable, which defines the separate functions.

Two differential equations with data on one-compartment (Ex7)

The model for the Exp7 example is identical to that for Exp6. However, in this example, it is assumed that data are available only for compartment two.

Multiple linear regression (Exp8)

Linear regression models are a subset of nonlinear regression models; consequently, linear models can also be fit using Phoenix. To illustrate this, a sample dataset (taken from Analyzing Experimental Data By Regression by Allen and Cady (1982), Lifetime Learning Publications, Belmont, CA) was analyzed in Exp8. Note that linear models can always be written as:

pkexamples02545.png 

(3)

This example is also interesting in that the model was initially defined in such a way to permit several different models to be fit to the data.

In the ASCII model panel, note that the number of parameters to be estimated is defined in CONS in order to make the model specification as general as possible. Note also the use of a DO loop in the model text.

Note:When using Phoenix to fit a linear regression model:
- use arbitrary initial values
- make sure the Do Not Use Bounds option is checked
- select the Gauss-Newton minimization method with the Levenberg and Hartley modification

The dosing constant for this example is the number of terms to be fit in the regression.

Cumulative areas under the curve (Exp9)

The Exp9 example uses the TRANSFORM block of commands to output cumulative area under the curve values calculated by trapezoidal rule. It computes cumulative urine excretion then fits it to a one-compartment model. The use of the LAG function is demonstrated.

Mitscherlich nonlinear model (Exp10)

In the Exp10 example, a dataset is fit to the Mitscherlich model. The data were taken from Allen and Cady (1982), Analyzing Experimental Data By Regression. Lifetime Learning Publications, Belmont, CA. Fitting data to this model involves the estimation of three parameters; b1, b2, and a.

pkexamples02547.png 

(4)

Four parameter logistic model (Exp11)

The Exp11 example illustrates how to fit a dataset to a general four parameter logistic function. The function is often used to fit radioimmunoassay data. The function, when graphed, depicts a sigmoidal (S-shaped) curve. The four parameters represent the lower and upper asymptotes, the ED50, and a measure of the steepness of the slope. For further details see DeLean, Munson and Rodbard (1978). Simultaneous analysis of families of sigmoidal curves: Application to bioassay, radioligand assay and physiological dose-response curves. Am J Physiol 235(2):E97–E102. The model, with parameters a, b, c, and d is as follows:

pkexamples02549.png 

(5)

Linear regression (Exp12)

The Exp12 example is based on work published by Draper and Smith (1981). Applied Regression Analysis, 2nd ed. John Wiley & Sons, NY.

Note:When doing linear regression in Phoenix, enter arbitrary initial estimates and make sure the Do Not Use Bounds option is checked. Use the Gauss-Newton minimization method with the Leven­berg and Hartley modification

Indirect response model (IR)

The IR example is PD8 from the textbook: Gabrielsson and Weiner (2016). Pharmacokinetic and Pharmacodynamic Data Analysis: Concepts and Applications, 5th ed. Apotekarsocieteten, Stockholm. It uses an indirect response model, linking Phoenix pharmacokinetic model 11 to indirect response model 54. The PK data were fit in a separate run and are linked to the Indirect Response model. This can be done via the PKVAL command when using an ASCII model or via the PK parameters panel. Model 11 is a two-compartment micro constant model with extravascular input.

Ke0 link model (PKPD)

The PKPD example is PD10 from the textbook: Gabrielsson and Weiner (2016). Pharmacokinetic and Pharmacodynamic Data Analysis: Concepts and Applications, 5th ed. Apotekarsocieteten, Stockholm. It uses an effect compartment PK/PD link model. The drug was administered intravenously, and a one-compartment model is assumed (PK Model 1). The PD data is fit to a simple Emax model (PD Model 101). The pharmacokinetic data were fit in a separate run and are linked to the pharmacody­namic model.

Pharmacokinetic/pharmacodynamic link model (Exp15)

Rather than fitting the PK data to a PK model, an effect compartment is fitted and Ke0 estimated in the Exp15 example using the observed Cp data. Therefore it is a type of nonparametric model. The collapsed Ce values are then used to model the PD data. The example also illustrates how to mix dif­ferential equations and integrated functions. This approach was proposed by Dr. Wayne Colburn.


Last modified date:9/10/19
Certara USA, Inc.
Legal Notice | Contact Certara
© 2019 Certara USA, Inc. All rights reserved.