epiBR0: Basic reproduction number (R0)

Description Usage Arguments Value Examples

View source: R/epiBR0.r

Description

Gives a Monte Carlo estimate of the basic reproduction number for a specified SIR model and data set

Usage

1
2
3
4
5
epiBR0 (x = NULL, y = NULL, contact = NULL, sus.par, trans.par = NULL, beta,

        spark = NULL, infperiod, Sformula = NULL, Tformula = NULL, tmax,

        niter)

Arguments

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 ~ model is interpreted as a specification that the susceptibility function, Ω_S(i) is modelled by a linear predictor specified symbolically by the model term. Such a model consists of a series of terms separated by + and - operators. If there is no susceptibility covariate information, Sformula is null.

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 ~ -1+model is interpreted as a specification that the transmissibility function, Ω_T(j) is modelled by a linear predictor specified symbolically by the model terms without the incorporation of the intercept term. Such a model consists of a series of terms separated by + and - operators. If there is no transmissibility covariate information, Tformula is null.

tmax

The last time point of simulation

niter

Number of epidemic simulations to calculate basic reproduction number

Value

A list is returned with the following components:

BasicR0

The basic reproduction number value

simulated_BR0

Number of infections per simulation

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
# 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

EpiILM documentation built on Jan. 13, 2021, 1:07 p.m.