epicurve {EpiLPS}R Documentation

Plot the epidemic curve

Description

This routine gives a graphical representation of the epidemic curve based on an incidence time series.

Usage

epicurve(incidence, dates = NULL, datelab = "7d", col = "deepskyblue4", barwidth = 1,
           title = "Epidemic curve", xtickangle = 0, smooth = NULL,  smoothcol = "orange")

Arguments

incidence

A vector containing the incidence time series

dates

A vector of dates in format "YYYY-MM-DD".

datelab

The spacing for ticks on the x-axis. Default "7d".

col

The color of the epidemic curve.

barwidth

The width of the bars. Default is 1.

title

Title of the plot.

xtickangle

The angle of the x-ticks. Default is 0 (horizontal).

smooth

An object of class Rt obtained with the estimR or estimRmcmc routine. It is used to draw a smoothed estimate of the epidemic curve based on the Laplacian-P-splines model.

smoothcol

The color of the smoothed curve and associated credible interval.

Value

A plot of the epidemic curve.

Author(s)

Oswaldo Gressani oswaldo_gressani@hotmail.fr

Examples

si <- c(0.05, 0.05, 0.1, 0.1, 0.1, 0.1, 0.1, 0.05, 0.05, 0.1, 0.1, 0.1)
epidemic <- episim(si = si, Rpattern = 4)
epicurve(epidemic$y)


[Package EpiLPS version 1.3.0 Index]