runRole | R Documentation |
'runRole' takes a 'role*' object and simulates all processes specified in the given parameters
runRole(x, cores = 1)
## S4 method for signature 'roleModel'
runRole(x)
## S4 method for signature 'roleExperiment'
runRole(x, cores = 1)
x |
'roleModel' or 'roleExperiment' object to run |
cores |
number of cores |
Prior to invoking 'runRole', the 'role*' input object must be initialized with a set of parameters, e.g., as generated by 'roleParams'.
'roleModel' or 'roleExperiment' run for the specified number of time steps
# create and run a model
model <- roleModel(roleParams())
model <- runRole(model)
# create and run an experiment
p1 <- roleParams(dispersal_prob = 0.2)
p2 <- roleParams(dispersal_prob = 0.3)
p3 <- roleParams(dispersal_prob = 0.4)
exp <- roleExperiment(list(p1,p2,p3))
exp <- runRole(exp)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.