Skip to main content
Skip table of contents

setAddLines

Add equations to the structural model.

Usage

R
setAddLines(lines)

Arguments

lines

(character) Additional lines to define.

Details

Additional equations can be added to the model file as in Simulx GUI. It is useful in case of import from Monolix or PKanalix, in order to add equations to the model, eg to compute an additional variable, without modifying the model file used for estimation.

All variables defined in the add lines will be available as an output.

See also

Examples

R
  # Calculate AUC
  initializeLixoftConnectors("monolix")
  monolix_project <- file.path(getDemoPath(), "1.creating_and_using_models", "1.1.libraries_of_models", "theophylline_project.mlxtran")
  initializeLixoftConnectors("simulx")
  importProject(monolix_project)
  setAddLines("ddt_AUC = Cc")

  # Calculate partial AUC
  initializeLixoftConnectors("monolix")
  monolix_project <- file.path(getDemoPath(), "1.creating_and_using_models", "1.1.libraries_of_models", "warfarinPK_project.mlxtran")
  initializeLixoftConnectors("simulx")
  importProject(monolix_project)
  setAddLines(c("if t<24", "deriv = Cc", "else", "deriv = 0", "end", "ddt_AUC = deriv"))
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.