R/misc.R
, R/plots_epi.R
plot_linpred.Rd
Plots credible intervals for the observed data under the posterior predictive distribution, and for a specific observation type. The user can control the levels of the intervals and the plotted group(s). This is a generic function.
# S3 method for epimodel posterior_sample_size(object) # S3 method for epimodel all_obs_types(object) plot_linpred(object, ...) # S3 method for epimodel plot_linpred( object, type = NULL, groups = NULL, dates = NULL, date_breaks = "2 weeks", date_format = "%Y-%m-%d", levels = c(30, 60, 90), ... )
object | A fitted model object returned by |
---|---|
... | Additional arguments for
|
type | the name of the observations to plot. This should match one
of the names of the |
groups | Either |
dates | A length 2 vector of |
date_breaks | A string giving the distance between date tick labels.
Default is |
date_format | This function attempts to coerce the |
levels | A numeric vector defining the levels of the plotted credible intervals. |
A ggplot
object which can be further modified.