High-level wrapper around vrc_fit() modelled after the user experience of
packages like epidemia and rstanarm. You specify a mortality component and a reporting
component, and vrcm() handles data preparation and model fitting.
The fitted model separates:
a latent mortality process (
lambda), anda reporting completeness process (
rho).
Both processes include a conflict proxy by default.
Usage
vrcm(
mortality = vrc_mortality(~1),
reporting = vrc_reporting(~1),
data,
t0,
priors = NULL,
...
)Arguments
- mortality
A
vrc_mortality()specification, or a formula.- reporting
A
vrc_reporting()specification, or a formula.- data
A data.frame in canonical VR long format (see
vrc_standata()).- t0
Conflict start time (index or a value in
data$time).- priors
Optional prior specification created by
vrc_priors(). IfNULL(default), usesvrc_priors()with package defaults.- ...
Passed through to
vrc_fit().
Value
A vrcfit object, or (if chains = 0) a standata bundle returned
by vrc_standata().