demo_simulation: set up a simulation as demonstrated by John C Mallery

View source: R/simdemo.R

demo_simulationR Documentation

set up a simulation as demonstrated by John C Mallery

Description

set up a simulation as demonstrated by John C Mallery

Usage

demo_simulation(
  gt.type = "gamma",
  gt.val = c(3, 1.5),
  begin = 1,
  end = 30,
  epid.nb = 1,
  epid.length = 30,
  family = "poisson",
  R0 = 1.67,
  peak.value = 500
)

Arguments

gt.type

character(1) type setting for R0:generation.time

gt.val

numeric() val setting for R0:generation.time

begin

numeric(1) passed to R0::estimate.R

end

numeric(1) passed to R0::estimate.R

epid.nb

numeric(1) passed to R0:sim.epid

epid.length

numeric(1) passed to R0:sim.epid

family

character(1) passed to R0:sim.epid

R0

numeric(1) passed to R0:sim.epid

peak.value

numeric(1) passed to R0:sim.epid

Value

result of estimate.R

Examples

## Not run: 
d1 = demo_simulation()
# plot(d1) ## note: R0:::plot.R0.sR is very peculiar and runs dev.new()
plotfit(d1)  # same here but seems to have simpler behavior
# s.a <- sensitivity.analysis(res=d1$estimates$EG, begin=1:15, end=16:30, sa.type="time")

## End(Not run)

seandavi/sars2pack documentation built on May 13, 2022, 3:41 p.m.