Estimate r

estimate_little_r(sample, min_time = NULL, max_time = NULL)

Arguments

sample

A datatable containing a numeric cases variable.

min_time

Numeric, minimum time to use to fit the model.

max_time

Numeric, maximum time to use to fit the model.

Value

A datatable containing an estimate of r, its standard deviation and a measure of the goodness of fit.

Examples

cases <- data.table::setDT(EpiSoon::example_obs_cases)[, cases := as.integer(cases)] estimate_little_r(cases)
#> r sd fit_meas #> 1: 0.1363544 0.003767123 0.9787982