simulateModelReplicates: Simulate several replicate of the model

View source: R/utils.r

simulateModelReplicatesR Documentation

Simulate several replicate of the model

Description

Simulate several replicate of a fitmodel using its function simulate

Usage

simulateModelReplicates(
  fitmodel,
  theta,
  initState,
  times,
  n,
  observation = FALSE
)

Arguments

fitmodel

a fitmodel object

theta

named numeric vector. Values of the parameters. Names should match fitmodel$thetaNames.

initState

named numeric vector. Initial values of the state variables. Names should match fitmodel$stateNames.

times

vector of times at which you want to observe the states of the model.

n

number of replicated simulations.

observation

logical, if TRUE simulated observation are generated by rTrajObs.

Value

a data.frame of dimension [nxlength(times)]x[length(initState)+2] with column names equal to c("replicate","time",names(initState)).


sbfnk/fitR documentation built on July 18, 2023, 3:28 p.m.