From 4df9e6d22e035120006f69904f4a264072fb44b6 Mon Sep 17 00:00:00 2001 From: Matthew Fidler Date: Mon, 2 Dec 2024 15:19:55 -0600 Subject: [PATCH] Change the tlast handling to be based on tlast per cmt --- inst/include/rxode2parseHandleEvid.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inst/include/rxode2parseHandleEvid.h b/inst/include/rxode2parseHandleEvid.h index 165b402bb..6f12034bb 100644 --- a/inst/include/rxode2parseHandleEvid.h +++ b/inst/include/rxode2parseHandleEvid.h @@ -248,7 +248,7 @@ static inline void handleTlastInline(double *time, rx_solving_options_ind *ind) } else { evid = getEvid(ind, ind->ix[ind->idx]); } - if (op->neq + op->extraCmt != 0 && ind->tlast != _time && + if (op->neq + op->extraCmt != 0 && ind->tlastS[ind->cmt] != _time && isDose(evid) && ind->cmt < op->neq + op->extraCmt) { double curDose = getDoseIndex(ind, ind->idx), tinf = NA_REAL;