params
slot of a simList
object
and its elements.
Additonal methods are provided to access core module and global parameters:
Commonly used
globals |
List of global simulation parameters. |
params |
Nested list of all simulation parameters. |
Accessor method | Module |
Description |
checkpointFile |
.checkpoint |
Name of the checkpoint file. (advanced) |
checkpointInterval |
.checkpoint |
The simulation checkpoint interval. (advanced) |
progressType |
.progress |
Type of graphical progress bar used. (advanced) |
progressInterval |
.progress |
Interval for the progress bar. (advanced) | Accessor method |
params(object)
"params"(object)
params(object) <- value
"params"(object) <- value
globals(object)
"globals"(object)
globals(object) <- value
"globals"(object) <- value
checkpointFile(object)
"checkpointFile"(object)
checkpointFile(object) <- value
"checkpointFile"(object) <- value
checkpointInterval(object)
"checkpointInterval"(object)
checkpointInterval(object) <- value
"checkpointInterval"(object) <- value
progressInterval(object)
"progressInterval"(object)
progressInterval(object) <- value
"progressInterval"(object) <- value
progressType(object)
"progressType"(object)
progressType(object) <- value
"progressType"(object) <- value
simList
simulation object.simList
object.
Progress Bar:
Progress type can be "text", "graphical" or "shiny".
Progress interval can be a numeric.
These both can get set by passing a
.progress=list(type="graphical", interval=1)
into the
simInit call. See examples
simList-class
,
simList-accessors-envir
,
simList-accessors-events
,
simList-accessors-inout
,
simList-accessors-modules
,
simList-accessors-objects
,
simList-accessors-paths
,
simList-accessors-times
.
## Not run:
# mySim <- simInit(times=list(start=0.0, end=100.0),
# params=list(.globals=list(stackName="landscape"),
# .progress=list(type="text", interval=10),
# .checkpoint = list(interval = 10, file = "chkpnt.RData")),
# modules=list("randomLandscapes"),
# paths=list(modulePath=system.file("sampleModules", package="SpaDES")))
#
# # progress bar
# progressType(mySim) # "text"
# progressInterval(mySim) # 10
#
# # parameters
# params(mySim) # returns all parameters in all modules
# # including .global, .progress, .checkpoint
# globals(mySim) # returns only global parameters
#
# # checkpoint
# checkpointFile(mySim) # returns the name of the checkpoint file
# # In this example, "chkpnt.RData"
# checkpointInterval(mySim) # 10
# ## End(Not run)
Run the code above in your browser using DataLab