Skip to content

Supplementary R package for the book chapter "Forecasting Based on Surveillance Data"

Notifications You must be signed in to change notification settings

HIDDA/forecasting

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The R package HIDDA.forecasting

The Handbook of Infectious Disease Data Analysis (Chapman & Hall/CRC, 2019) contains a chapter on "Forecasting Based on Surveillance Data" (preprint) by Leonhard Held and Sebastian Meyer. The R package HIDDA.forecasting provides the data and code to reproduce results from the two applications presented in that chapter:

  1. Univariate forecasting of Swiss ILI counts using

    • forecast::auto.arima() --> vignette("CHILI_arima")

    • glarma::glarma() --> vignette("CHILI_glarma")

    • surveillance::hhh4() --> vignette("CHILI_hhh4")

    • prophet::prophet() --> vignette("CHILI_prophet")

    • experimental kcde::kcde() --> vignette("CHILI_kcde")

    • and MASS::fitdistr() for naive reference forecasts --> vignette("CHILI_naive")

  2. Age-stratified analysis of norovirus counts in Berlin using "hhh4" --> vignette("BNV")

Installation

To install the released HIDDA.forecasting package (with pre-built vignettes) together with other packages required to run the analyses:

# install.packages("remotes")
remotes::install_url("https://github.com/HIDDA/forecasting/releases/download/v1.1.2/HIDDA.forecasting_1.1.2.tar.gz", dependencies = TRUE)

Alternatively, to install HIDDA.forecasting from the current sources, building the vignettes on your machine, you could use:

# install.packages("devtools")
devtools::install_github("HIDDA/forecasting", dependencies = TRUE, build_vignettes = TRUE)

To browse the installed vignettes:

browseVignettes("HIDDA.forecasting")

Note that the "CHILI" vignettes include source("setup.R"), which refers to a small R script available from the installed package at

system.file("doc", "setup.R", package = "HIDDA.forecasting")