R/PN-lifecycle-network-T.R
spn_T_lifecycle_network.Rd
This function makes the set of transitions (T) for a SPN model of a
metapopulation network. It is the network version of spn_T_lifecycle_node
.
spn_T_lifecycle_network(spn_P, params, cube, n = NULL, m_move = NULL)
spn_P | set of places produced by |
---|---|
params | a named list of parameters (see details) |
cube | an inheritance cube from the |
n | an integer giving the number of nodes |
m_move | binary adjacency matrix indicating if movement of mosquitoes between nodes is possible or not |
a list with two elements: T
contains transitions packets as lists,
v
is the character vector of transitions (T)
This function takes the places produced from spn_P_lifecycle_network
and builds all possible transitions between subsets of those places.
The params
argument supplies all of the ecological parameters necessary
to calculate equilibrium values. This function requires the nE
,
nL
, and nP
parameters to be specified. For more details, see
equilibrium_lifeycle
While this function produces all structural information related to transitions,
hazards are produced by a separate function, spn_hazards
.
For larger networks, this function may take some time to return, please be patient; the Petri Net modeling formalism trades additional computation time at model initialization for faster sampling of trajectories within a simulation.
Please note, the movement matrix (m_move
) is NOT a
stochastic matrices, just a binary matrix that say if i,j can exchange population.
Diagonal elements must be FALSE
.
At least one of the arguments n
and m_move
must be provided. If both are provided
n
is ignored.
For examples of using this function, see:
vignette("lifecycle-network", package = "MGDrivE2")