Run_model: Run Cysticercosis model with interventions

Description Usage Arguments Examples

View source: R/Model_wrappers.R

Description

Runs the ODE Cysticercosis model

Usage

1
2
3
4
Run_model(Params = NULL, Initial_states = NULL, Time, Intervention = NULL,
  Intervention_time = Time/2,
  Intervention_effect = Intervention_effect_size(), step = 1/30,
  Burn_in = 0)

Arguments

Params

List of model parameters

Initial_states

List of intitial state values

Time

The number of years to run the model for (from equilibrium). Default is at the halfway point.

Intervention

A vector of interventions to include from: Husbandry, Sanitatio, Inspection, Pig_MDA, Pig_vaccine and Human_test_and_treat

Intervention_effect

A list of intervention effect sizes, see Intervention_effect_size for details

step

Time step (months)

Burn_in

A burn in period run before model run (years)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
# Run the baseline model:
M1<-Run_model(Time=50, Burn_in=50)
plot(M1$t/12, M1$Humans_Cysticercosis, t='l', ylim=c(0,1000), ylab='Humans with Cysticercosis', xlab='Time (years)')

# Run the model with a single intevention:
M2<-Run_model(Time=50, Intervention='Sanitation', Intervention_time=20, Burn_in=50)
lines(M2$t/12, M2$Humans_Cysticercosis, col='red')

# Run the model with multiple interventions:
M3<-Run_model(Time=50, Intervention=c('Human_test_and_treat', 'Pig_MDA'), Intervention_time=20, Burn_in=50)
lines(M3$t/12, M3$Humans_Cysticercosis, col='green')
legend('topright', c('Baseline','Sanitation','Human test & treat and Pig MDA'), lty=c(1,1,1), col=c('black','red', 'green'))

pwinskill/EPICYST documentation built on May 26, 2019, 11:34 a.m.