Description Usage Arguments Value
View source: R/sir-simulations.R
Update agents based on Bernoulli draws
1 | update_agents(current_states, SIR_count, beta, gamma)
|
current_states |
vector of 0/1/2 of length n_agents. Gives the current state for each agent |
SIR_count |
total number of S, I, R currently in each state |
beta |
infection parameter between 0 and 1 |
gamma |
infection parameter between 0 and 1 |
list with
states vector of size n_agents of new states
SIR_count new total number of S, I, R currently in each state
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.