IV macro


The macro iv enables to link the administration with the model, for intravenous doses (bolus or infusion). Doses defined in the [ADMINISTRATION] section or in the data set without an administration rate or infusion time are instantaneously absorbed within the associated compartment, as an IV bolus. Doses with an administration rate or infusion time (e.g keyword ‘rate’ in the [ADMINISTRATION] section of a Mlxplore file, or column-type RATE or TINF in the data set) are absorbed according to a zero order process, as an IV infusion.


Arguments for macro iv are:

  • cmt: Label of the compartment called in by the absorption process. Its default value is 1.
  • type: Administration type of doses subject to the absorption process. Its default value is 1. Alias: adm. Thus, when defining a treatment in Mlxplore for example, instead to define a target, the user should define a type and apply the dedicated absorption process on it.
  • Tlag: Lag time before the absorption. Its default value is 0.
  • p: Final proportion of the absorbed amount. It can affect the effective rate of the absorption, not its duration. p can take any positive value (including > 1). Its default value is 1.


PK; intravenous bolus for the doses of type 1, in compartment 1 with a delay Tlag at 1 
iv(type=1, cmt=1, Tlag=1, p=1)

Example with Mlxplore

In the presented example, we show the difference two iv processes with and without a rate in the administration.

input = {V, Tlag}

compartment(cmt=1, amount=A1, concentration=Cc_iv_bolus, volume=V)
iv(cmt=1, type=1, Tlag)
elimination(cmt=1, k=1)

compartment(cmt=2, amount=A2, concentration=Cc_iv_inf, volume=V)
iv(cmt=2, type=2, Tlag)
elimination(cmt=2, k=1)

adm_1 = {time=5, amount=1, type=1}
adm_2 = {time=5, amount=1, type=2, rate=.1}

V = 10
Tlag = 2

grid = 0:.05:20
list = {Cc_iv_bolus, Cc_iv_inf}

p = {y={Cc_iv_bolus, Cc_iv_inf}, ylabel='Concentrations', xlabel='Time'}

The two concentrations (Cc_iv_bolus in orange, and Cc_iv_inf in blue) are presented in the following figure.

Rules and Best Practices:

  • We encourage the user to use all the fields in the macro to guarantee no confusion between parameters
  • Format restriction (non compliance will raise an exception)
    • The value after cmt= and type= are necessarily integers.
    • The value after Tlag=, p= can be either a double or replaced by an input parameter. Calculations are not supported.
  • With the iv macro, it is not possible to give the rate or duration of the infusion as a parameter or fixed value. To do so, use the absorption macro with duration parameter Tk0 to define a zero-order absorption (i.e infusion).
  • When the iv macro is used in combination with a data set with a column-type RATE:
    • if RATE >0: infusion with rate RATE and duration AMT/RATE
    • if RATE <=0: bolus
  • When the iv macro is used in combination with a data set with a column-type TINF:
    • if TINF >0: infusion of duration TINF at a rate AMT/TINF
    • if TINF <=0: bolus