Learn R Programming

mrgsolve (version 0.8.12)

mcode: Write, compile, and load model code

Description

This is a convenience function that ultimately calls mread.

Usage

mcode(model, code, project = tempdir(), ...)

mcode_cache(model, code, project = tempdir(), ...)

Arguments

model

model name

code

character string specifying a mrgsolve model

project

project name

...

passed to mread

Details

Note that the arguments are in slightly different order than mread. The default project is tempdir().

See Also

mread, mread_cache

Examples

Run this code
# NOT RUN {
# }
# NOT RUN {
code <- '
$CMT DEPOT CENT
$PKMODEL ncmt=1, depot=TRUE
$MAIN
double CL = 1;
double V = 20;
double KA = 1;
'

mod <- mcode("example",code)
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab