PRODUCTS: NONMEM® USER TIPS

These tips are brought to you as information of interest from experiences in using NONMEM. All tips can also be found in the tips folder on the NONMEM Repository@GloboMax.

Tip # 10 - Log-Transformed Data and DV=0 Records:

As a follow up to the last tip and some recent discussion on nmusers, this tip will address "what do I do with DV=0 records in data sets when log-transforming my data?"

In the previous tip (#9), the data came from an IV study (actually the phenobarbital data that is distributed with NONMEM was ln-transformed) with no zero observations (fortuitously and by design). In that situation, the following code can be used to provide individual predictions (and avoid the ln(DV)=log(0) which would occur for the dosing records):

$ERROR
IPRED=0
IF(F.GT.0) IPRED=LOG(F)
Y=IPRED+ERR(1)

However, in the situation where one has data with observations with DV=0, you have to decide how you are going to treat those records. As an example, I have ln-transformed the theopp data that is distributed with NONMEM. In preparing the transformed data set, a column was added with ln(DV). For ln(0) records, 0 was entered as the ln(DV). Now, how do you handle the model code?

  1. Suggestions were proposed to set the ln(0) equal to some "small value":
    1. $ERROR
      CALLFL=0
      IPRED = -3 ;similar to above code but ipred=-3 instead of ipred=0
      IF(F.GT.0) IPRED = LOG(F)
      Y = IPRED + EPS(1)
    2. OR

    3. $ERROR
      CALLFL=0br> IPRED=F
      IF(IPRED.EQ.0) IPRED=EXP(-9)
      Y=LOG(IPRED)+EPS(1)
  2. Another suggestion is to simply delete the observations records with DV=0 if they occur right after the dose and there are not "a lot" of them. An argument can be made that these are BQL's and could be deleted.
  3. Use the "double-exponential" residual error model:

    Y=LOG((F)+THETA(n))+(F*ERR(1))/(F+THETA(n))+(THETA(n)*ERR(2))/(F+THETA(n))
    ;code does not require log(0) protection except if IPRED wanted
    IPRED=0
    IF(F.GT.0) IPRED=LOG(F)

For the log transformed theophylline data, the "best" fit to the data was obtained using option 2. and 3. Both gave an equivalent fit and parameter estimates. Options 1.A. and 1.B, gave fits with significantly higher objective function values and bias for this data. The arbitrary selection of the "small" value had a significant effect on the fit. With option 3., the value of m, the "positively constrained variance parameter" (THETA(n), here), was about 0.2, presumably near the LOQ. The difference in objective function between 2. and 3. was ~6.4 (lower for 3. but with two more parameters in the model). This again suggests, why not remove the DV=0 observation records? What are YOUR THOUGHTS?

[errors may be reported to the author and are welcomed.]

[Generic Disclaimer: Verify that this code or any other code you receive from an outside source works with YOUR DATA.]