View source: R/phyloseq_to_MetaCommunity.R
phyloseq_to_MetaCommunity | R Documentation |
The phyloseq data is converted to the MetaCommunity object (entropart package), which can then be used for measurement and partitioning of diversity, including species-neutral, phylogenetic and functional diversity metrics.
phyloseq_to_MetaCommunity(physeq, wei = NULL)
physeq |
A phyloseq-class object |
wei |
A vector of positive numbers equal to community weights (could be NULL for equal weights) |
A MetaCommunity
class object
MetaCommunity
# Load data
data("esophagus")
library(entropart)
# Convert phyloseq to MetaCommunity class
eso <- phyloseq_to_MetaCommunity(esophagus)
summary(eso)
# Estimate diversity (Shannon diversity, q=1)
ad <- AlphaDiversity(eso, q = 1, Correction = "None")
summary(ad)
plot(ad)
# Diversity partitioning into alpha and beta components
dp <- DivPart(q = 1, eso, Correction = "None")
summary(dp)
plot(dp)
# Diversity profile
dpr <- DivProfile(q.seq = seq(0, 2, 0.1), eso, Correction = "None")
summary(dpr)
plot(dpr)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.