simpleSim: Simple SIR simulation

Description Usage Arguments Details Value

View source: R/simpleSim.R

Description

simpleSim runs a stochastic SIR model with gamma-distributed waiting times.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
simpleSim(
  inc_mean_param,
  inf_mean_param,
  R_0,
  case_fatality,
  pop_size,
  inc_shape_param = 1,
  inf_shape_param = 1,
  initial_cases = 1,
  max_time = 365,
  seed = 20200129
)

Arguments

inc_mean_param

Mean of the incubation period distribution

inf_mean_param

Mean of the infectious period

R_0

Basic reproductive number

case_fatality

Proportion of cases that die

pop_size

Size of the population

inc_shape_param

Shape parameter of the incubation period distribution (default = 1)

inf_shape_param

Shape parameter of the infectious period distribution (default = 1)

initial_cases

Initial number of cases (default = 1)

max_time

Maximum time for the simulation to run (default = 365)

seed

Seed for the random number generator (default = 20200129)

Details

TODO: Add more details later

Value

Returns a list with two dataframes: pop, the full population on which the simulation was run, and cases a preliminary line list (perfect reporting)

TODO: Add more detail


jrcpulliam/LLsim documentation built on Feb. 5, 2020, 8:49 p.m.