 # NONMEM TO NLME transit compartments

### #1 amashehri

amashehri

Newbie

• • Members
• • 1 posts

Posted 17 September 2020 - 01:47 AM

Hi

I am trying to use differential equations from a NONMEM published model on NLME but I cant figure it out "I am new in modeling". The model is two compartment, first order of absorption with a chain of transit compartment.

Thanks

### #2 bwendt@certara.com

bwendt@certara.com

• • • 188 posts

Posted 22 September 2020 - 09:24 AM

We asked one of our developers to translate the NM-Tran code to PML, here is the code:

test(){

# ntr is the structural parameter representing one less than the number of transit stages.

transit(Aa, mtt, ntr, max=50, out=-Aa*Ka)

deriv(A1 = Ka * Aa - Cl * C - Cl2 * (C - C2))

deriv(A2 = Cl2 * (C - C2))

dosepoint(Aa)

C = A1 / V

C2 = A2 / V2

error(CEps = 0.11) # sqrt(0.508876 )

covariate(ASSAY())

covariate(WT)

CRatio = ASSAY == 3? C*Ratio : C

CMultStdev = ASSAY == 3? PROP_ERR_DBS:PROP_ERR_Plasma

observe(CObs = CRatio + CEps * sqrt(1 + CRatio^2 * (CMultStdev/sigma())^2))

stparm(Ka = tvKa)

stparm(V = tvV * exp(nV))

stparm(V2 = tvV2 * exp(nV2) * (WT/70))

stparm(Cl = tvCl * exp(nCl) * (WT/70)**0.75)

stparm(Cl2 = tvCl2 * exp(nCl2))

stparm(mtt = tvmtt * exp(nmtt))

stparm(ntr = tvntr) # fixed

fixef(tvKa = c(, .55, ))

fixef(tvV = c(, 89, ))

fixef(tvV2 = c(, 234, ))

fixef(tvCl = c(, 7.6, ))

fixef(tvCl2 = c(, 19, ))

fixef(tvmtt = c(,1.05, ))

fixef(tvntr(freeze) =c(,6,))

fixef(Ratio = c(, 0.71, ))

# define multiplicative sigmas

# although we cannot code the correlation

fixef(PROP_ERR_Plasma = 0.09) #sqrt(0.00878848 )

fixef(PROP_ERR_DBS = 0.11) # sqrt(0.0124671)

ranef(diag(nV, nCl, nV2, nCl2, nmtt) = c(0.01, 0.064, 0.04, 0.17, 0.36))

}

Please try in Phoenix and let us know if you run into issues.

Bernd

#### 0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users 