A family of functions used for inputting data into Covidestim.

input_cases(data, type = "reported", lastCaseDate = NULL)

input_deaths(data, type = "reported", lastDeathDate = NULL)

input_rr(data, type = "reported")

input_hosp(data, type = "reported", lastHospDate = NULL)

input_boost(data, type = "reported")

Arguments

data

A data.frame as described below.

type

A string, either "reported" or "occurred".

"reported" applies to the following situations:

  • Case, death, hospitalizatons, booster or RR data where the count for a particular day represents the number of cases or deaths that were reported publicly on that day for the following week.

  • Cases, death, hospitalizatons, booster or RR data where the count for a particular day is the number of cases or deaths received from hospital reports, or diagnostic laboratories, accumulated across a particular region

"occurred" applies to the following situations:

  • Data where counts represent the number of cases or deaths that actually occured on that day. For case data, this would be the day a test was administered. For deaths, this would be the day an individual died. Note that, if the deaths data represent the day an individual's death was first reported as a SARS-Cov-2-related death, that data should be passed with type = "reported", instead.

Details

There are two types of observational data that can be used with Covidestim:

  • Case data, detailing the number of new cases each week

  • Death data, detailing the number of confirmed Covid-19 deaths each week

  • Hospitalizations data, detailing the number of hospital admissions each week

  • Booster data, detailing the number of booster shots adminsitered each week

  • RR data, detailing the Relative Risk IFR adjustment that the model needs to account for.

All input data to Covidestim is expected to be a data.frame of two variables. One variable, date, must be a vector of type POSIXct or Date. The second column, observations, must be a non-negative numeric vector.

Missing values in cases, hospitalizations, booster, RR and deaths data should be imputed before running the model. The date range of all sets of data passed to covidestim must be equivalent, with one observation each day, and no gaps in the data. Assertions attempt to enforce this specification.