stageRunner objects are used for executing a linear sequence of
actions on a context (an environment). For example, if we have an
environment e
containing x = 1, y = 2
, then using
stages = list(function(e) e$x <- e$x + 1, function(e) e$y <- e$y - e$x)
will cause x = 2, y = 0
after running the stages.
stagerunner_initialize(context, stages, remember = FALSE, mode = getOption("stagerunner.mode") %||% "head")
context | environment. The initial environment that is getting modified during the execution of the stages. |
---|---|
stages | list. The functions to execute on the |
remember | logical. Whether to keep a copy of the context and its contents throughout each stage for debugging purposes--this makes it easy to go back and investigate a stage. The default is |
mode | character. Controls the default behavior of calling the
|