When simulation concentration-time data using NONMEM, there are times when you wish to include the censoring effect of BLQ measurements from your bioanalytical laboratory. It is very easy to implement this in your NONMEM control stream. Here is how I do it.
In the $ERROR block , you will be adding your residual error to the prediction. The prediction is denoted F in NONMEM code. The individual prediction that is output as DV is denoted Y in NONMEM code. Let’s assume that the limit of quantitation is 0.1 ng/mL. The code to add at the end of your error code is the following:
Y=F + ERR(1)
The first line can vary depending on your specific residual error structure. The heavy lifting is done by the second line where the value Y is compared to the target value of 0.1 using the Fortran term for “less than” (LT). If the predicted value is less than the BLQ it will be replaced by the number zero. If the predicted value is greater than or equal to the BLQ, then the prediction does not change. You cannot assign text (eg BLQ) to the value of Y. Only numerical values are accepted. In my example I set it to zero; however, I could have assigned a value of -99999 also. Ether way I would extract these “BLQ” values from the simulated dataset before plotting the data.