Jump to content


Photo

NONMEM TO NLME transit compartments


  • Please log in to reply
6 replies to this topic

#1 amashehri

amashehri

    Newbie

  • Members
  • Pip
  • 5 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.

 

Please find the attached document.

 

Thanks 

 

 

 

 

 

Attached Files



#2 bwendt@certara.com

bwendt@certara.com

    Advanced Member

  • Administrators
  • 201 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  



#3 amashehri

amashehri

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 30 December 2020 - 10:56 AM

 


Edited by amashehri, 30 December 2020 - 10:59 AM.


#4 amashehri

amashehri

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 30 December 2020 - 10:57 AM

Thanks Bernd for your help.

 

I think I need to add a function to describe enterohepatic recycling but I am not sure how to add it to PML 

 

Here is the code "Drug is administered once" No dosing interval 

 

 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.1)
    observe(CObs = C + CEps * sqrt(1 + C^2 * (CMultStdev/sigma())^2))
    stparm(Ka = tvKa * exp(nKa))
    stparm(V = tvV * exp(nV))
    stparm(V2 = tvV2 * exp(nV2))
    stparm(Cl = tvCl * exp(nCl))
    stparm(Cl2 = tvCl2 * exp(nCl2))
    stparm(mtt = tvmtt * exp(nmtt))
    stparm(ntr = tvntr) # fixed
    stparm(CMultStdev = tvCMultStdev)
    fixef(tvKa = c(, 1, ))
    fixef(tvV = c(, 162929.74, ))
    fixef(tvV2 = c(, 625466, ))
    fixef(tvCl = c(, 7243, ))
    fixef(tvCl2 = c(, 7243, ))
    fixef(tvmtt = c(,1.05, ))
    fixef(tvntr(freeze) =c(,7,))
    fixef(tvCMultStdev = c(,1, ))
    ranef(diag(nV, nCl, nKa, nV2, nCl2, nmtt) = c(1, 1, 1, 1, 1, 1))
}
 
Thanks !!


#5 bwendt@certara.com

bwendt@certara.com

    Advanced Member

  • Administrators
  • 201 posts

Posted 31 December 2020 - 01:21 PM

You may know that we have covered quite a diverse set of scenarios as part of our PML School. There was one webinar around enterohepatic recirculation:

 

https://support.cert...-recirculation/

 

The entry covers all materials, slide deck, model and recorded webinar session.

Let me know if you need more.

 

Bernd



#6 LLLi

LLLi

    Advanced Member

  • Members
  • PipPipPip
  • 92 posts

Posted 04 January 2021 - 04:51 PM

Hi amashehri,

 

The code that you attached is for single dose data or multiple dose data? 

 

Thanks!

 

 



#7 amashehri

amashehri

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 05 January 2021 - 12:10 AM

Hi amashehri,

 

The code that you attached is for single dose data or multiple dose data? 

 

Thanks!

 

Hi

 

The code is for single dose data






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users