Learn R Programming

⚠️There's a newer version (2.0.11) of this package.Take me there.

SpaDES (version 1.1.3)

Develop and Run Spatially Explicit Discrete Event Simulation Models

Description

Easily implement a variety of simulation models, with a focus on spatially explicit agent based models. These include raster-based, event-based, and agent-based models. The core simulation components are built upon a discrete event simulation framework that facilitates modularity, and easily enables the user to include additional functionality by running user-built simulation modules. Included are numerous tools to visualize raster and other maps. The suggested package `fastshp` can be installed with `install.packages("fastshp", repos="http://rforge.net", type="source")`.

Copy Link

Version

Install

install.packages('SpaDES')

Monthly Downloads

484

Version

1.1.3

License

GPL-3

Issues

Pull Requests

Stars

Forks

Maintainer

Alex M Chubaty

Last Published

April 18th, 2016

Functions in SpaDES (1.1.3)

move

Move
.fileTableIn

Create empty fileTable for inputs and outputs
gpar

Importing some grid functions
.makeSpadesPlot

Make a .spadesPlot class object
openModules

Open all modules nested within a base directory
clearPlot

Clear plotting device
getModuleVersion

Find the latest module version from a SpaDES module repository
checkModule

Check for the existence of a remote module
.sim2gantt

sim2gantt
paths

Specify paths for modules, inputs, and outputs
rndstr

Generate random strings
checksums

Calculate checksums for a module's data files
.updateSpadesPlot

Merge two SpaDES Plot objects
copy

Copy a simList object
defineModule

Define a new module.
show,simList-method

Show an Object
saveFiles

Save objects using .saveObjects in params slot of simInit
equalExtent

Assess whether a list of extents are all equal
heading

Heading between spatial points.
envir

Simulation environment
dwrpnorm2

Vectorized wrapped normal density function
.spadesPlottables-class

The .spadesPlottables class
changeObjEnv

Copy or move objects from one environment to another
.unparsed

Determine which modules in a list are unparsed
params

Get and set simulation parameters.
.simList-class

The simList class
versionWarning

Compare module version against SpaDES package version and warn if incompatible
minTimeunit

Determine the smallest timeunit in a simulation
checkParams

Check use and existence of params passed to simulation.
divergentColors

Divergent colour palette
initiateAgents

SELES - Initiate agents
loadPackages

Load packages.
checkPath

Check filepath.
.parseArgs

Parse arguments and find environments
packages

Get simulation package dependencies
.plotGrob

Plot spatial grobs (using grid package)
nlayers,list-method

Find the number of layers in a Spatial Object
makeDigestible

Remove any reference to environments in a simList
randomPolygons

randomPolygons
.spadesGrob-class

The .spadesGrob class
.identifyGrobToPlot

Identify where to get the grob from
.depsPruneEdges

Prune edges to remove cycles in module dependencies
dyears

SpaDES time units
doEvent

Process a simulation event
.arrangement-class

The .arrangement class
inSeconds

Convert time units
paddedFloatToChar

Convert numeric to character with padding
.assignSpaDES

Assign to the internal SpaDES environment.
newPlot

Open a new plotting window
getFileName

Get the name of a source-ed file
downloadData

Download module data
numAgents

SELES - Number of Agents to initiate
.makeList

Convert plotArgs to list of lists
spadesClasses

Classes defined in SpaDES
classFilter

Filter objects by class
digest

Calculate the hashes of multiple files
.emptyMetadata

Default (empty) metadata
.existsSpaDES

Is an object defined in the .spades environment?
fileExt

Extract the file extension of a file
.findFactors

Find factors
defineParameter

Define a parameter used in a module
simList_-class

The simList_ class
depsGraph

Build a module dependency graph
doEvent.checkpoint

Simulation checkpoints.
Plot

Plot: Fast, optimally arranged, multipanel plotting function with SpaDES
probInit

SELES - Probability of Initiation
.getSpaDES

Get objects from the internal SpaDES environment
maxTimeunit

Determine the largest timestep unit in a simulation
.fileExtensions

File extensions map
eventDiagram

Simulation event diagram
.fillOutputRows

An internal function for coercing a data.frame to inputs()
moduleCoverage

Calculate module coverage of unit tests
ls.str.simList

List simulation objects and their structure
append_attr

Add a module to a moduleList
getColors

Get colours for plotting Raster* objects.
.fillInputRows

An internal function for coercing a data.frame to inputs()
transitions

SELES - Transitioning to next time step
moduleMetadata

Parse and extract module metadata
scheduleEvent

Schedule a simulation event
rasterToMemory

Read raster to memory
downloadModule

Download a module from a SpaDES module GitHub repository
cir

Identify pixels in a circle around a SpatialPoints* object.
inRange

Test whether a number lies within range [a,b]
.arrangeViewports

Determine optimal plotting arrangement of plot objects
.moduleDeps-class

The .moduleDeps class
.prepareRaster

Prepare raster for plotting
updateList

Update elements of a named list with elements of a second named list
spread

Simulate a spread process on a landscape.
adj.raw

Fast `adjacent` function, and Just In Time compiled version
.spadesPlot-class

The .spadesPlot class
experiment

objectNames

Extracts the object names
newModule

Create new module from template.
fileName

Extract filename (without extension) of a file
newProgressBar

Progress bar
.makeColorMatrix

Convert Raster to color matrix useable by raster function for plotting
splitRaster

Split a raster into multiple tiles.
gaussMap

Produce a raster of a random Gaussian process.
objs

Extract or replace an object from the simulation environment
spadesMaps

Dummy maps included with SpaDES
.spadesEnv

The SpaDES environment
sortDotsFirst

Sort a any named object with dotted names first
moduleDiagram

Simulation module dependency diagram
SpaDES-package

Categorized overview of the SpaDES package
.makeViewports

Make viewports
clickValues

Mouse interactions with Plots
layerNames

Extract the layer names of Spatial Objects
objectDiagram

Simulation object dependency diagram
agentLocation

SELES - Agent Location at initiation
.makeLayout

Make an optimal layout of plots
patchSize

Patch size
normPath

Normalize filepath
shine

Display a simple, interactive shiny app of the simList
specificNumPerPatch

specificNumPerPatch
clearStubArtifacts

Clear erroneous archivist artifacts
checkObject

Check for existence of object(s) referenced by a objects slot of a simList object
dev

Specify where to plot
ls.simList

List simulation objects
.inputObjects

Create an empty (template) inputObjects and outputObjects data.frames
cache

Cache method for simList class objects
initialize,simList-method

Generate a simList object
rasterizeReduced

Convert reduced representation to full raster
.depsLoadOrder

Determine module load order
.addDepends

Add simulation dependencies
times

Time usage in SpaDES
makeLines

Make SpatialLines object from two SpatialPoints objects
.spadesPlotObjects-class

The .spadesPlotObjects class
.unittrim

Convert grid.locator units
spatialObjects-class

The spatialObjects class
wrap

Wrap coordinates or pixels in a torus-like fashion
.first

Event priority
zipModule

Create a zip archive of a module subdirectory
currentModule,.simList-method

Simulation event lists
spades

Run a spatial discrete event simulation
depsEdgeList

Build edge list for module dependency graph
.emptyEventList

Blank (template) event list
.simDeps-class

The .simDeps class
simInit

Initialize a new simulation
modules

Simulation modules and dependencies
ganttStatus

ganttStatus
.parseModule

Parse and initialize a module
setColors<-

Set colours for plotting Raster* objects.
inputs

Inputs and outputs