simulateSOI {miaSim}R Documentation

Self-Organised Instability model (SOI) simulation

Description

Generate time-series with The Self-Organised Instability (SOI) model. Implements a K-leap method for accelerating stochastic simulation.

Usage

simulateSOI(n.species, I, A, k = 5, com = NULL, tend, norm = FALSE)

Arguments

n.species

Integer: number of species

I

Integer: community size, number of available sites (individuals)

A

interaction matrix

k

Integer: the number of transition events that are allowed to take place during one leap. (default: k = 5). Higher values reduce runtime, but also accuracy of the simulation.

com

a vector: initial community abundances If (default: com = NULL), based on migration rates

tend

Integer: number of timepoints to be returned in the time series (number of generations)

norm

Logical: indicates whether the time series should be returned with the abundances as proportions (norm = TRUE) or the raw counts (default: norm = FALSE)

Value

SummarizedExperiment object containing abundance matrix consisting of species abundance as rows and time points as columns

Examples

A <- miaSim::powerlawA(10, alpha = 1.2)

ExampleSOI <- simulateSOI(n.species = 10, I = 1000, A, k=5, com = NULL,
                                            tend = 150, norm = TRUE)

[Package miaSim version 0.99.1 Index]