NONMEM Users Network Archive

Hosted by Cognigen

RE: Negative concentration from simulation

From: Zhang, Liping [JRDUS] <LZhang11>
Date: Tue, 2 Jun 2020 19:56:56 +0000

Hi Nyein,

Like Bill and Leonid explained, you can decide what to do with the negative values after the simulation, depending on the goals of the analysis.

Alternatively, within Nonmem model file, you can use ICALL.EQ.4 (simulation event) to prevent non-negative values being simulated
IF (ICALL.EQ.4) THEN. DOWHILE (Y.LT.0). CALL SIMEPS(EPS). Y= Y=IPRED*(1+EPS(1))+EPS(2). Note your $SIM must have NEW option. You can see a complete example from Nick here,

Note this approach, same as in dealing with non-negative values after simulation, will lead to a truncated dataset with different variation than the original random error model specified in the simulation model. Following the same thread you can find a solution from Ken.

Best regards, Liping

-----Original Message-----
From: owner-nmusers> On Behalf Of Bill Denney
Sent: Tuesday, June 2, 2020 2:30 PM
To: Nyein Hsu Maung <nyeinhsumaung2018>;
Subject: [EXTERNAL] RE: [NMusers] Negative concentration from simulation

Hi Nyein,

Negative concentrations can be expected from simulations if the model includes additive residual error. I assume that you mean additive and proportional error when you say "combined error model". If the error structure does not include additive error, then we'd need to know more.

How you will handle them in analysis depends on the goals of the analysis.
Usually, you will either simply set negative values to zero or set all values below the limit of quantification to zero.



-----Original Message-----
From: owner-nmusers <> On Behalf Of Nyein Hsu Maung
Sent: Tuesday, June 2, 2020 2:13 PM
Subject: [NMusers] Negative concentration from simulation

Dear NONMEM users,
I tried to simulate a new dataset by using a previously published pop pk model. Their model was described by combined error model for residual variability. And after simulation, I have obtained two negative concentrations. I would like to know if there is any proper way to handle those negative concentrations or if there are some codings to prevent gaining negative concentrations. Thanks.

Best regards,
Nyein Hsu Maung

Received on Tue Jun 02 2020 - 15:56:56 EDT

The NONMEM Users Network is maintained by ICON plc. Requests to subscribe to the network should be sent to:

Once subscribed, you may contribute to the discussion by emailing: