View source: R/pandemic_stats.R
pandemic_stats | R Documentation |
This function provides short and long-term predictions for the pandemic. 95% credible intervals are assigned to the number of cases for every future date predicted, as well as for the total number of cases, and dates for the peak and end of the pandemic.
Short-term predictions are made on the cumulative counts and long-term predictions are based on the new case counts.
pandemic_stats(object)
object |
an object of S3 class |
The total number of cases is obtained by adding the cumulative total cases observed in the data to the predicted new cases for the next 1,000 days.
The peak of the pandemic curve represents the highest number of daily cases reported.
The median, 2.5% and 97.5% percentiles are calculated on the mean number of new cases for the pandemic curve (starting from the first observed data point until 1,000 days after the last date observed in the data). The 95% credible interval for the peak of cases is selected such that the two limiting dates of the 97.5% percentile curve coincides with the highest value of the 2.5% percentile curve. This guarantees that all possible curves belonging to the confidence band will peak within the defined interval.
Represents the 99% percentile of the total number of cases in the pandemic.
An object of S3 class pandemicStats
. This object is a list containing the following elements:
data
:
A list with a data frame containing the observed pandemic data, a string with the location name
and a string indicating the type of cases predicted.
ST_predict
:
A data frame with the short-term predictions for the number of cumulative cases. For each future date predicted,
the mean, median, 2.5% and 97.5% percentiles are provided.
The short-term horizon is determined by the horizonShort
argument in the posterior_predict
function.
LT_predict
:
A data frame with the long-term predictions for the number of new cases. For each future date predicted,
the mean, median, 2.5% and 97.5% percentiles are provided.
The long-term horizon is determined by the horizonLong
argument in the posterior_predict
function.
LT_summary
:
A list with the estimated total number of cases and the dates for the peak and end of the pandemic.
In each metric, the median, 2.5% and 97.5% percentiles are provided. For more information, see the
Details section.
mu
:
A data frame with the median values of the mean number of new cases for each date (starting from the first
observed data point until the last date in the long-term horizon).
CovidLP Team, 2020. CovidLP: Short and Long-term Prediction for COVID-19. Departamento de Estatistica. UFMG, Brazil. URL: http://est.ufmg.br/covidlp/home/en/
load_covid
, pandemic_model
, posterior_predict.pandemicEstimated
and plot.pandemicPredicted
.
## Not run: italy = load_covid("italy") estim = pandemic_model(italy, case_type = "confirmed", covidLPconfig = TRUE) pred = posterior_predict(estim) stats = pandemic_stats(pred) stats ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.