
Quantile-based quantize commsim (sequential / Markov chain)
Source:R/quantize_commsim.R
quantize_commsim_seq.RdConstruct a vegan::commsim() object that uses quantize() as a
sequential null model: successive simulated matrices form a
Markov chain in the space of numeric community matrices.
Internally, each simulation "step" advances the chain by
re-applying quantize() to the current matrix using the settings
provided via ....
Arguments
- ...
Arguments passed to
quantize(), such asbreaks,n_strata,transform,offset,zero_stratum,fixed,method,n_iter, etc. Do not supplyxorn_iterhere;xis provided by vegan andn_iteris set internally fromthin. Seequantize()for details.
Value
An object of class "commsim" suitable for
vegan::nullmodel() and vegan::oecosimu().
Details
This model is sequential: simulated matrices form a Markov chain. The current matrix is updated in-place by repeated calls to the randomization model, and successive matrices are obtained by advancing the chain.
In vegan::simulate.nullmodel(), the control arguments behave as:
nsim: number of matrices to store from the chain.thin: number of trades per step. Each "step" of the chain appliesthintrades of the chosenmethodto the current state before possibly storing it.burnin: number of initial steps to perform (each withthintrades) before storing any matrices, i.e. the Markov chain burn-in.
There is no n_iter argument here: mixing is controlled entirely by
thin (trades per step) and burnin (number of initial steps
discarded), in the same spirit as sequential swap / curveball models
in vegan.