epiBR0 {EpiILM} | R Documentation |
Gives a Monte Carlo estimate of the basic reproduction number for a specified SIR model and data set
epiBR0 (x = NULL, y = NULL, contact = NULL, sus.par, trans.par = NULL, beta,
spark = NULL, infperiod, Sformula = NULL, Tformula = NULL, tmax,
niter)
x |
X coordinates of individuals |
y |
Y coordinates of individuals |
contact |
Contact network(s) |
sus.par |
Susceptibility parameter(>0) |
trans.par |
Transmissibility parameter(>0) |
beta |
Spatial parameter(s) (>0) or network parameter (s) (>0) if contact is used |
spark |
Sparks parameter (>=0), representing infections unexplained by other parts of the model or infections coming in from outside the observed population, default value is zero |
infperiod |
Length of infectious period for each individual |
Sformula |
An object of class formula. See formula Individual-level covariate information associated with susceptibility can be passed through this argument. An expression of the form |
Tformula |
An object of class formula. See formula Individual-level covariate information associated with transmissibility can be passed through this argument. An expression of the form |
tmax |
The last time point of simulation |
niter |
Number of epidemic simulations to calculate basic reproduction number |
A list is returned with the following components:
BasicR0 |
The basic reproduction number value |
simulated_BR0 |
Number of infections per simulation |
# generate 100 X-Y coordinates for a distance-based ILM
x <- runif(100, 0, 10)
y <- runif(100, 0, 10)
# Suppose we know the length of infectious period for each individual. Also, assume
# susceptibility parameter = 1.5 and spatial parameter = 5 for this SIR model
infperiod <- rep(3, 100)
# For a 1000 iteration with a last observed time point 15, we can estimate the basic
# reproduction number using Monte Carlo simulation
out <- epiBR0(x = x, y = y, sus.par = 1.5, beta = 5, infperiod= infperiod,
tmax = 15, niter = 1000)
out$BasicR0