Return simulations of the trajectory of the output variables of a dynamical model simulator.
Arguments
- model
A dynamical model simulator produced by
mp_simulator
.- include_initial
Should the initial values of the simulation be included in the output? If
TRUE
this will include outputs fortime == 0
associated with the initial values. Seemp_initial
for another approach to getting the initial values.- conf.int
Should confidence intervals be produced?
- conf.level
If
conf.int
isTRUE
, what confidence level should be used? For example, the default of0.95
corresponds to 95% confidence intervals.- n
Number of random trajectories to simulate.
- probs
Numeric vector of probabilities corresponding to quantiles for summarizing the results over the random realizations.
Functions
mp_trajectory_sd()
: Simulate a trajectory that includes uncertainty information provided by thesdreport
function inTMB
with default settings.mp_trajectory_ensemble()
: Simulate a trajectory that includes uncertainty information provided by repeatedly sampling from a normal approximation to the distribution of the fitted parameters, and generating one trajectory for each of these samples. The quantiles of the empirical distribution of these trajectories can be used to produce a confidence interval for the fitted trajectory.mp_trajectory_sim()
: Generate quantiles overn
realizations of the trajectory. Instead of avalue
column in the output data frame, there is one column for each of the quantiles defined inprobs
.