View source: R/simplified_gillespies.R
Possible states and their respective logical representations. Summarise in matrix Initial state of each individual Initial state of epidemic at population level Possible Events Summarise in a matrix event table Waiting Time Which event happens? event = sample(c(1,2), size = 1, prob = c(infectionRate, removalRate)) To who? Construct rate vector Update Population State Update Individual State Record event
1 | heterogeneousSIR_Gillespie(initialState, beta, gamma, kernel)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.