CreateSimulationObject {scSpatialSIM} | R Documentation |
Create a spatial simulation object.
Description
This function creates a SpatSimObj
for
spatial simulations. The object contains information about the
simulation window, the number of simulations to perform, and
lists of cells, Tissue1/Tissue2, holes, and spatial files.
Usage
CreateSimulationObject(window = NULL, sims = NULL, cell_types = 1)
Arguments
window |
An object of class |
sims |
The number of simulations to perform. If |
cell_types |
The number of cell types. Defaults to 1. |
Details
The simulation window is represented by an object of class
owin
, which specifies the extent and shape of the spatial
domain in which the simulations will be performed. If no window
is provided, the function creates a rectangular window of size
(0,10) in both x and y directions.
The sims
argument specifies the number of simulations to
perform. If it is set to NULL
or less than 1, the function
defaults to 3.
The cell_types
argument specifies the number of cell
types to include in the simulation. By default, the function
creates a single cell type, represented by an object of class
Cell
.
The SpatSimObj
is composed of the following classes:
A
Window
object of classowin
.An integer
Sims
specifying the number of simulations to perform.A list of
Cells
of classCell
.A
Tissue
object of classTissue1/Tissue2
, representing the Tissue1/Tissue2 components of the simulation.A
Holes
object of classHoles
, representing holes in the simulation.A list of
Spatial Files
containing any spatial data associated with the simulation.
Value
A SpatSimObj
containing the simulation
window, the number of simulations to perform, and lists of cells,
Tissue1/Tissue2, holes, and spatial files.
Examples
CreateSimulationObject()