Learn R Programming

mrgsolve (version 1.5.2)

Simulate from ODE-Based Models

Description

Fast simulation from ordinary differential equation (ODE) based models typically employed in quantitative pharmacology and systems biology.

Copy Link

Version

Install

install.packages('mrgsolve')

Monthly Downloads

1,214

Version

1.5.2

License

GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

Last Published

October 18th, 2024

Functions in mrgsolve (1.5.2)

ev_assign

Replicate a list of events into a data set
data_set

Select and modify a data set for simulation
env_ls

List objects in the model environment
env_update

Update objects in model environment
details

Extract model details
ev_repeat

Repeat a block of dosing events
evd

Create an event object with data-like names
ev_rep

Replicate an event object
design

Set observation designs for the simulation
exdatasets

Example input data sets
env_get

Return model environment
env_eval

Re-evaluate the code in the ENV block
ev_ops

Operations for ev objects
ev_rx

Create intervention objects from Rx input
ev_seq

Schedule a series of event objects
ev_days

Schedule dosing events on days of the week
ev_methods

Various methods for event objects
expand_observations

Insert observations into a data set
ev-class

S4 events class
expand.idata

Create template data sets for simulation
c,matlist-method

Operations with matlist objects
matlist

Methods for working with matrix-list objects
matlist-class

S4 class matlist
file_show

Show model specification and C++ files
house

Return a pre-compiled, PK/PD model
lower2matrix

Create a square numeric matrix from the lower-triangular elements
lctran

Change the case of nmtran-like data items
loadso

Load the model shared object
modlib_pkpd

modlib: Pharmacokinetic / pharmacodynamic models
modlib_pk

modlib: Pharmacokinetic models
inventory

Check whether all required parameters needed in a model are present in an object
is.mrgmod

Check if an object is a model object
modMATRIX

Create a matrix
modlib

Internal model library
modelparse

Parse model specification text
modlib_details

modlib: PK/PD Model parameters, compartments, and output variables
mutate.ev

dplyr verbs for event objects
mrgmod-class

S4 class for mrgsolve model object
ev

Event objects for simulating PK and other interventions
mrgsim_variants

mrgsim variant functions
mrgsims-class

S4 class for mrgsolve simulation output
is.mrgsims

Check if an object is mrgsims output
as_bmat

Coerce R objects to block or diagonal matrices
merge.list

Merge two lists
matrix_helpers

Create matrices from vector input
mrgsims_dplyr

Methods for handling output with dplyr verbs
nmext

Import model estimates from a NONMEM ext file
nmxml

Import model estimates from a NONMEM xml file
mrgsims

Methods for working with mrgsims objects
knobs

Run sensitivity analysis on model settings
mcRNG

Set RNG to use L'Ecuyer-CMRG
$,ev-method

Select columns from an ev object
mcode

Write, compile, and load model code
modlib_tmdd

modlib: Target mediated disposition model
idata_set

Select and modify a idata set for simulation
modlib_viral

modlib: HCV viral dynamics models
init

Methods for working with the model compartment list
omega

Manipulate OMEGA matrices
mod

Return the model object
outvars

Show names of current output variables
mread_yaml

Read a model from yaml format
mrgsim

Simulate from a model object
$,mrgmod-method

Select parameter values from a model object
mwrite_cpp

Write a model to native mrgsolve format
mread

Read a model specification file
parameter_list-class

S4 parameter_list class
render

Render a model to a document
simargs

Access or clear arguments for calls to mrgsim()
plot,batch_mrgsims,missing-method

Plot method for mrgsims objects
mvgauss

Simulate from a multivariate normal distribution with mean zero
numeric2diag

Create a diagonal numeric matrix from diagonal elements
mrgsim_q

Simulate from a model object with quicker turnaround
soloc

Return the location of the model shared object
reserved

Reserved words
within

Update parameters, initials, and settings within a model object
mrgsims_modify

Methods for modifying mrgsims objects
wf_sweep

Simulate a sequence of parameters
mwrite_yaml

Write model code to yaml format
plot_mrgsims

Generate a quick plot of simulated data
names,mrgmod-method

Get all names from a model object
mrgsolve-package

mrgsolve: Simulate from ODE-Based Models
param_tags

Return parameter tags
qsim

Basic, simple simulation from model object
param

Create and work with parameter objects
numericlist

Methods for numericlist
read_nmext

Extract estimates from NONMEM ext file
obsaug

Augment observations in the simulated output
obsonly

Collect only observation records in the simulated output
numericlist-class

S4 class numeric list
realize_addl

Make addl doses explicit in an event object or data set
show,cmt_list-method

Show the compartment list
reexports

Objects exported from other packages
plot_sims

Plot data as an mrgsims object
summary.mrgmod

Print summary of a mrgmod object
show,mrgmod-method

Print model details
tgrid

Create a simtime object
show,parameter_list-method

Show the parameter list
numerics_only

Prepare data.frame for input to mrgsim()
touch_funs

Get inits from compiled function
c,tgrid-method

Operations with tgrid objects
sigma

Manipulate SIGMA matrices
revar

Get model random effect variances and covariances
stime

Get the times at which the model will be evaluated
solversettings

Optional inputs for lsoda
update

Update the model object
tscale

Re-scale time in the simulated output
valid_idata_set

Validate and prepare idata data sets for simulation
scrape_opts

Scrape options from a code block
see

Print model code to the console
valid_data_set

Validate and prepare data sets for simulation
scrape_and_call

Scrape options and pass to function
zero_re

Zero out random effects in a model object
%>%

Forward pipe
blocks

Return the code blocks from a model specification file
as.list,mrgsims-method

Coerce an mrgsims object to list
aboutsolver

About the lsoda differential equation solver used by mrgsolve
Req

Request simulated output
as_deslist

Create a list of designs from a data frame
BLOCK_PARSE

Functions to parse code blocks
as_data_set

Create a simulation data set from ev objects or data frames
as.list,mrgmod-method

Coerce a model object to list
PKMODEL

Parse PKMODEL BLOCK data
as.ev

Coerce an object to class ev
collapse_omega

Collapse OMEGA or SIGMA matrix lists
collapse_matrix

Collapse the matrices of a matlist object
cama

Run the model cama function
carry_out

Select items to carry into simulated output
cmtn

Get the compartment number from a compartment name
check_data_names

Check input data set names against model parameters
cvec

Create create character vectors
cmt_list-class

S4 cmt_list class
code

Extract the code from a model