Implements Empirical Bayes Incidence Curves


[Up] [Top]

Documentation for package ‘incidental’ version 0.1

Help Pages

compute_expected_cases Compute expected cases
compute_log_incidence Compute log likelihood of incidence model
covid_delay_dist Delay distribution from COVID-19 pandemic.
covid_new_york_city New York City data from the COVID-19 pandemic.
data_check Input data check
data_processing Data processing wrapper
diff_trans Transpose of the 1st difference operator
fit_incidence Fit incidence curve to reported data
front_zero_pad Pad reported data with zeros in front
incidence_to_df Export incidence model to data frame
init_params Initialize spline parameters (beta)
make_ar_extrap_samps Make AR samples for extrapolation past end point
make_likelihood_matrix Make delay likelihood matrix
make_spline_basis Create spline basis matrix
marg_loglike_poisson Marginal log likelihood This function computes the marginal probability of Pr(reported | beta). Note that lnPmat must be zero padded enough (or censored) to match the length of reported cases vector.
marg_loglike_poisson_fisher Marginal log likelihood Fisher information matrix
marg_loglike_poisson_grad Marginal log likelihood gradient
plot.incidence_spline_model Plot model from fit_incidence
poisson_objective Poisson objective function
poisson_objective_grad Poisson objective function gradient
poisson_objective_post_cov_approx Compute Fisher information matrix for Poisson objective
regfun Beta regularization function
regfun_grad Beta regularization function gradient
regfun_hess Beta regularization function Hessian
sample_laplace_log_incidence_poisson Generate Laplace samples of incidence
scan_spline_dof Scan spline degrees of freedom
scan_spline_lam Scan spline regularization parameter
spanish_flu Daily flu mortality from 1918 flu pandemic.
spanish_flu_delay_dist Delay distribution from 1918 flu pandemic.
train_and_validate Train and validate model on reported data
train_val_split Split reported case data