control_seiqhrf.Rd
Sets the controls for stochastic individual contact models simulated
with simulate_seiqhrf
. Similar to EpiModel::control.icm, but allows for
model types with additional compartments (e.g. 'SEIQHRF').
control_seiqhrf( type = "SEIQHRF", nsteps = 366, nsims = 8, prog.rand = FALSE, quar.rand = TRUE, hosp.rand = TRUE, disch.rand = TRUE, rec.rand = FALSE, arec.rand = TRUE, fat.rand = TRUE, a.rand = TRUE, d.rand = TRUE, initialize.FUN = "initialize.FUN", infection.FUN = "infection.FUN", recovery.FUN = "recovery.FUN", departures.FUN = "departures.FUN", arrivals.FUN = "arrivals.FUN", get_prev.FUN = "get_prev.FUN", verbose = FALSE, verbose.int = 0, skip.check = FALSE, ncores = 4, ... )
type | Disease type to be modeled, with the choice of |
---|---|
nsteps | Number of time steps to solve the model over. This must be a positive integer. |
nsims | Number of simulations to run. |
prog.rand | Method for progression from E compartment to I. If TRUE, random binomial draws at prog.rate, if FALSE, random draws from a Weibull distribution (yes, I know it should be a discrete Weibull distribution but it makes little difference and speed of computation matters), with parameters prog.dist.scale and prog.dist.shape |
quar.rand | Method for self-isolation transition from I to Q. If TRUE, random binomial draws at quar.rate, if FALSE, random sample with a sample fraction also given by `quar.rate. |
hosp.rand | Method for transition from I or Q to H -- that is, from infectious or from self-isolated to requiring hospitalisation. If TRUE, random binomial draws at hosp.rate, if FALSE, random sample with a sample fraction also given by `hosp.rate. |
disch.rand | Method for transition from H to R -- that is, from requiring hospitalisation to recovered. If TRUE, random binomial draws at disch.rate, if FALSE, random sample with a sample fraction also given by disch.rate. Note that the only way out of the H compartment is recovery or death. |
rec.rand | If |
arec.rand | Method for recovery transition from E to R. If TRUE, random binomial draws at arec.rate, if FALSE, random draws from a random draws from a Weibull distribution, with parameters arec.dist.scale and arec.dist.shape. |
fat.rand | Method for case fatality transition from H to F. If TRUE, random binomial draws at fat.rate.base, if FALSE, random sample with a sample fraction also given by fat.rate.base. However, if the current number of patients in the H (needs hospitalisation) compartment is above a hospital capacity level specified by hosp.cap, then the fatality rate is the mean of the base fatality rate weighted by the hospital capacity, plus a higher rate, specified by fat.rate.overcap, weighted by the balance of those requiring hospitalisation (but who can't be accommodated). By setting fat.rate.overcap higher, the effect of exceeding the capacity of the health care system can be simulated. There is also a coefficient fat.tcoeff for the fatality rates that increases them as a linear function of the number of days the individual has been in the H compartment. Use of the co-efficient better approximates the trapezoid survival time distribution typical of ICU patients. |
a.rand | If |
d.rand | If |
initialize.FUN | Module to initialize the model at the outset, with the
default function of |
infection.FUN | Module to simulate disease infection, with the default
function of |
recovery.FUN | Module to simulate disease recovery, with the default
function of |
departures.FUN | Module to simulate departures or exits, with the default
function of |
arrivals.FUN | Module to simulate arrivals or entries, with the default
function of |
get_prev.FUN | Module to calculate disease prevalence at each time step,
with the default function of |
verbose | If |
verbose.int | Time step interval for printing progress to console, where
0 (the default) prints completion status of entire simulation and
positive integer |
skip.check | If |
ncores | Number of physical CPU cores used for parallel computation. |
... | Additional control settings passed to model. |
A list of control parameters and core functions
control
sets the required control settings for any stochastic
individual contact model solved with the simulate_seiqhrf
function. Controls
are required for both base model types and when passing original process
modules. For an overview of control settings for base ICM class models,
consult the Basic ICMs
tutorial. For all base models, the type
argument is a necessary
parameter and it has no default.
Base ICM models use a set of module functions that specify
how the individual agents in the population are subjected to infection, recovery,
demographics, and other processes. Core modules are those listed in the
.FUN
arguments. For each module, there is a default function used in
the simulation. The default infection module, for example, is contained in
the infection.FUN
function.
For original models, one may substitute replacement module functions for any of
the default functions. New modules may be added to the workflow at each time
step by passing a module function via the ...
argument.