Learn R Programming

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

SpaDES (version 1.0.1)

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.0.1

License

GPL-3

Issues

Pull Requests

Stars

Forks

Maintainer

Alex M Chubaty

Last Published

August 10th, 2015

Functions in SpaDES (1.0.1)

depsGraph

Build a module dependency graph
newPlot

Open a new plotting window
cache

Cache method for simList class objects
getColors

Get colours for plotting Raster* objects.
depsEdgeList

Build edge list for module dependency graph
modules

Simulation modules and dependencies
.addDepends

Add simulation dependencies
openModules

Open all modules nested within a base directory
adj.raw

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

The .spadesPlot class
show,simList-method

Show an Object
setColors<-

Set colours for plotting Raster* objects.
checkParams

Check use and existence of params passed to simulation.
move

Move
makeDigestible

Remove any reference to environments in a simList
defineParameter

Define a parameter used in a module
doEvent

Process a simulation event
checkObject

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

Create new module from template.
moduleDiagram

Simulation module dependency diagram
.depsPruneEdges

Prune edges to remove cycles in module dependencies
eventDiagram

Simulation event diagram
makeLines

Make SpatialLines object from two SpatialPoints objects
.makeList

Convert plotArgs to list of lists
.unparsed

Determine which modules in a list are unparsed
.objectNames

Extracts the object names
ganttStatus

ganttStatus
randomPolygons

randomPolygons
.makeLayout

Make an optimal layout of plots
equalExtent

Assess whether a list of extents are all equal
getFileName

Get the name of a source-ed file
newProgressBar

Progress bar
initiateAgents

SELES - Initiate agents
loadFiles

Load simulation objects according to filelist
.parseArgs

Parse arguments and find environments
.depsLoadOrder

Determine module load order
defineModule

Define a new module.
.plotGrob

Plot spatial grobs (using grid package)
ls.str.simList

List simulation objects and their structure
.findFactors

Find factors
.assignSpaDES

Assign to the internal SpaDES environment.
ls.simList

List simulation objects
.identifyGrobToPlot

Identify where to get the grob from
maxTimeunit

Determine the largest timestep unit in a simulation
layerNames

Extract the layer names of Spatial Objects
cir

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

Simulation event lists
splitRaster

Split a raster into multiple tiles.
.arrangement-class

The .arrangement class
.getSpaDES

Get objects from the internal SpaDES environment
agentLocation

SELES - Agent Location at initiation
doEvent.checkpoint

Simulation checkpoints.
dwrpnorm2

Vectorized wrapped normal density function
loadPackages

Load packages.
.prepareRaster

Prepare raster for plotting
scheduleEvent

Schedule a simulation event
spread

Simulate a spread process on a landscape.
.makeSpadesPlot

Make a .spadesPlot class object
rndstr

Generate random strings
spadesClasses

Classes defined in SpaDES
moduleMetadata

Parse and extract module metadata
gaussMap

Produce a raster of a random Gaussian process.
heading

Heading between spatial points.
SpaDES-package

Categorized overview of the SpaDES package
paddedFloatToChar

Convert numeric to character with padding
.spatialObjects-class

The .spatialObjects class
.spadesGrob-class

The .spadesGrob class
gpar

Importing some grid functions
inRange

Test whether a number lies within range [a,b]
inputs

Inputs and outputs - adding file-based inputs and saving files
objectDiagram

Simulation object dependency diagram
specificNumPerPatch

specificNumPerPatch
zipModule

Create a zip archive of a module subdirectory
rasterizeReduced

Convert reduced representation to full raster
.sim2gantt

sim2gantt
sortDotsFirst

Sort a any named object with dotted names first
.makeViewports

Make viewports
.simDeps-class

The .simDeps class
clearPlot

Clear plotting device
updateList

Update elements of a named list with elements of a second named list
nlayers,list-method

Find the number of layers in a Spatial Object
.spadesPlotObjects-class

The .spadesPlotObjects class
transitions

SELES - Transitioning to next time step
normPath

Normalize filepath.
spades

Run a spatial discrete event simulation
.spadesEnv

The SpaDES environment
rasterToMemory

Read raster to memory
.spadesPlottables-class

The .spadesPlottables class
spadesMaps

Dummy maps included with SpaDES
saveFiles

Save simulation objects according to params
.parseModule

Parse and initialize a module
times

Get and set simulation times.
[[

Extract or replace parts of an object from the simulation environment
probInit

SELES - Probability of Initiation
params

Get and set simulation parameters.
inputPath

Specify paths for modules, inputs and outputs
.updateSpadesPlot

Merge two SpaDES Plot objects
simInit

Initialize a new simulation
changeObjEnv

Copy or move objects from one environment to another
downloadModule

Download a module from a SpaDES module GitHub repository
.moduleDeps-class

The .moduleDeps class
checkPath

Check filepath.
dyears

SpaDES time units
packages

Get simulation package dependencies
.unittrim

Convert grid.locator units
.simList-class

The simList class
clickValues

Mouse interactions with Plots
wrap

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

Determine optimal plotting arrangement of plot objects
classFilter

Filter objects by class
dev

Specify where to plot
.existsSpaDES

Is an object defined in the .spades environment?
initialize,simList-method

Generate a simList object
envir

Simulation environment
getModuleVersion

Find the latest module version from a SpaDES module repository
patchSize

Patch size
simList_-class

The simList_ class
numAgents

SELES - Number of Agents to initiate
Plot

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

Add a module to a moduleList
minTimeunit

Determine the smallest timeunit in a simulation
.makeColorMatrix

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

Convert time units