Reputation: 3
I recently want to follow the checkerboard score under a null model method to calculate the pvalue
for co-occurrence analysis as adopted by this paper "Using network analysis to explore co-occurrence patterns in soil microbial communities".
Unfortunately, the usage of commands and arguments of vegan package was not well described in the paper.
I believe there must be some expert of vegan package in R to do such co-occurrence analysis based on checkerboard score under a null model.
Could any one help with the scripts or the commands and arguments I should use to calculate the C-score under a null model in R?
Will this C-score thing return me a matrix of pvalue
that I could use to indicate the co-occurrence?
Upvotes: 0
Views: 4066
Reputation: 16
this should give a quick estimate of C-score
library(vegan)
library(bipartite)
C.score(species, normalise=T, FUN=mean, na.rm=T)->cscore.speciesN
C.score(species, normalise=F, FUN=mean, na.rm=T)->cscore.speciesS
cscore.speciesN
cscore.speciesS
Upvotes: 0
Reputation: 21
I guess this may answer your question:
library(vegan)
library(bipartite)
null.model <- oecosimu(species, bipartite::C.score, "swap", burnin=100, thin=10, statistic="evals", nsimul=10000) #where species is you species by sites matrix
print(null.model)
Upvotes: 2