Description Usage Arguments Value See Also Examples
View source: R/modeling_tools.R
Fits the neutral model from Sloan et al. (2006) to an OTU table and returns several fitting statistics as well as predicted occurrence frequencies for each OTU based on their abundance in the metacommunity. The author of this function is Adam Burns (aburns2@uoregon.edu), and was originally published in Burns et al. (2016).
1 |
spp |
A community table for communities of interest with local communities/samples as rows and taxa as columns. All samples must be rarefied to the same depth. |
pool |
(optional) A community table for defining source community. |
taxon |
(optional) A table listing the taxonomic calls for each otu, with OTU ids as row names and taxonomic classifications as columns. |
This function returns list of two elements.
The first element, spp.out$fitstats, contains various fitting stats.
The second element contains the predicted occurrence frequencies for each OTU/ASV, as well as their fit_class
1 2 3 4 | spp <- otu_table(ps)@.Data
spp2 <- otu_table(ps2)@.Data
spp.out <- fit_sncm(spp, pool=NULL, taxon=NULL)
spp.out <- fit_sncm(spp, pool=spp2, taxon=data.frame(tax_table(ps)))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.