r2R: Convert Growth Rate to Reproduction Number

View source: R/r2R.R

r2RR Documentation

Convert Growth Rate to Reproduction Number

Description

Convenience function to convert a growth rate (little r) to a reproduction number (R) given a particular generation time.

Usage

r2R(r, mu_gamma = 4.7, sd_gamma = 2.9)

Arguments

r

a double representing the growth rate

mu_gamma

a double representing mean of the gamma function characterizing the generation time.

sd_gamma

a double representing standard deviation of the gamma function characterizing the generation time.

Source

https://royalsocietypublishing.org/doi/10.1098/rsif.2020.0144

Examples


cases <- rpois(10,2.5)
t <- 1:10
fit <- glm(cases ~ t, family = "poisson")

r2R(coef(fit)[2])




nctriadresearch/nccovid documentation built on April 9, 2023, 7:03 a.m.