Model configuration


Configure a Covidestim run on a set of priors and input data


Population estimates for US states and counties

Input data

Covidestim expects two data sources to be present - case data, and death data. These functions allow adding these data sources to the model configuration.

input_cases() input_deaths()

Input observational data

Custom priors

These functions allow customization of model priors. By default, Covidestim comes with a complete set of priors, which have been tailed for estimation of U.S. counties and states. However, these functions make it possible to override the default parameterizations of the prior distributions, within certain constraints. This allows you to conduct exploratory modeling of other geographies, or test the effect of different priors on estimates.

Prior Type Description
rr_diag_asy_vs_sym Beta(α,β) Rate ratio of diagnosis, asymptomatic vs. symptomatic,non-severe
rr_diag_sym_vs_sev Beta(α,β) RR diagnosis, symptomatic vs. severe
p_diag_if_sev Beta(α,β) P(diagnosed | severe)
dx_delay_sym Beta(α,β) Time to diagnosis as fraction of time spent symptomatic
dx_delay_sev Beta(α,β) Time to diagnosis as fraction of time spent severe
inf_prg_delay Gamma(α,β) T(infection → symptoms)
sym_prg_delay Gamma(α,β) T(symptoms → severe)
sev_prg_delay Gamma(α,β) T(severe → dead)
asy_rec_delay Gamma(α,β) T(infection → recovery), asymptomatics
pri_serial_i Gamma(α,β) Serial interval
infect_dist Gamma(α,β) Change in infectiousness
seropos_dist Gamma(α,β) Change in seropositivity
cas_rep_delay Gamma(α,β) T(test → report)
die_rep_delay Gamma(α,β) T(death → report)
p_sym_if_inf Beta(α,β) P(symptoms | infected)
p_sev_if_sym Beta(α,β) P(severe | symptoms)
p_die_if_sev Beta(α,β) P(die | severe)
p_die_if_inf Beta(α,β) P(die | infection) (IFR)
ifr_decl_OR Gamma(α,β) ~IFR decline

Helper functions:

gamma_shape() gamma_rate()

Convert mean/variance stats to shape/rate parameters of gamma distribution

Model execution


Run the Covidestim model using NUTS


Run the Covidestim model using BFGS



Summarize a Covidestim run


Visualize results of a Covidestim run

Example data

Covidestim provides an example NYC dataset to try running the model with.


Example NYC case/death data