soi | R Documentation |
Generate time series with the self-organized instable (SOI) model implementing model B by Sole et al. 2002. The model implements a K-leap method for accelerating stochastic simulation according to Cai et al. 2007
soi(N, I, A, m.vector = runif(N), e.vector = runif(N), tend, K = 5, perturb = NULL)
N |
number of species |
I |
number of individuals |
A |
interaction matrix |
m.vector |
species-specific immigration probabilities (these also determine initial abundances) |
e.vector |
species-specific extinction probabilities |
tend |
number of time points (i.e. the number of generations) |
K |
The parameter K gives the number of simulation events occurring during one leap. Cai et al. 2007 propose rules for the selection of K. However, as those rules may be considered conservative, K is a user-supplied parameter with a default of 5. A higher K gives a faster simulation, but is less accurate. Large values of K may also lead to errors caused by population abundances becoming negative, particularly if the extinction and immigration rates are high. |
perturb |
a perturbation object |
a matrix with species abundances as rows and time points as columns
Sole et al. Philos Trans R Soc Lond B Biol. Sci. "Self-organized instability in complex ecosystems" 357:667-671 (2002) Cai et al. The Journal of Chemical Physics "K-leap method for accelerating stochastic simulation of coupled chemical reactions" 126 (2007)
ricker
for the Ricker model
## Not run: N=10 A=generateA(N,c=0.1) tsplot(soi(N=N,I=1000,A=A,tend=100), header="SOI") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.