Learn R Programming

RsSimulx (version 2024.1)

inlineModel: Inline model

Description

Save a string in a temporary file to be used as a model file

Usage

inlineModel(srtIn, filename = NULL)

Value

Name of the model file

Arguments

srtIn

(string) Model in string format,

filename

(string) name of the model file (by default the model is saved in a temporary file)

Examples

Run this code
if (FALSE) {
myModel <- inlineModel("
[LONGITUDINAL]
input = {A, k, c, a}
EQUATION:
t0    = 0
f_0   = A
ddt_f = -k*f/(c+f)
DEFINITION:
y = {distribution=normal, prediction=f, sd=a}
[INDIVIDUAL]
input = {k_pop, omega}
DEFINITION:
k = {distribution=lognormal, prediction=k_pop, sd=omega}
")
}

Run the code above in your browser using DataLab