Skip to content

Baseline model

Evan Ray edited this page Sep 14, 2020 · 1 revision

The baseline model, adapted from a proposal by Ryan Tibshirani, forecasts constant median incidence with a distribution around the median derived from past first differences in incidence. Forecasts of cumulative counts are derived from forecasts of incident counts. A more detailed description is given in the metadata file.

Software Dependencies

You will need Python 3 and R 3.x or 4.x, as well as the packages listed below:

Python packages:

  • pandas and requests. To install, run the following in a terminal:
pip install pandas
pip install requests

R packages:

  • The quantgen package by Ryan Tibshirani. Follow the instructions at https://github.com/ryantibs/quantgen.

  • Other packages: tidyverse, MMWRweek, magrittr, here. In an R session, run the following:

install.packages(c("tidyverse", "MMWRweek", "magrittr", "here"))
  • The covidModels package. Clone the repository and install as an R package. In a terminal, you can run the following commands:
git clone https://github.com/reichlab/covidModels
cd covidModels
R CMD INSTALL R-package
  • The covidData package. Clone the repository. You don't need to install it as an R package immediately; this will be done as part of the automated ensemble build process.
git clone https://github.com/reichlab/covidData

Weekly baseline model build

The following instructions can be used to build the COVID-19 Forecast Hub baseline model.

  1. In a terminal window, navigate to covidModels/weekly-submission/ and run the make all command.
  2. Copy the submission files to a branch or fork of the covid19-forecast-hub repository, commit, push, and submit a pull request.