Function for running replicates of simulation.
1 2 3 4 |
functions |
An environment (could be coerced from a list) with any additional functions needed by the simulation. |
data |
An environment (could be coerced from a list) with all immutable data for the simulation. It may include code snippets (e.g.-quote(a <- 3; o <- f(x))) |
data_transformations |
code snippet run once, created by quoting a bracketed expression, (e.g.-quote(a <- 3; b <- 3*a)), which will be used to transform data once prior to simulation. |
simulation |
function defining a single simulation, taking 'parameters' as arguments. |
parameters |
list of lists. Each element is a list of parameter values.. |
control |
control list for generating replicates, includes elements: 1) size, the number of replicates to generate per parameter set; 2) output, a snippet run at the end of each simulation, should persist results. used to summarize and persist simulation results. |
sandbox |
if TRUE the parent.env where the call is made will not be available to the code. For full effects see ?create_sandbox. |
simulation |
A code snippet, run once per replicate, created by quoting a bracketed expression, (e.g.-quote(a <- 3; b <- -1*a), which will be used to generate simulation output. This code can not modify the data. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.