eBay_comps | R Documentation |
An empirical Bayes approach for transforming raw counts into relative abundances
eBay_comps(otu_tab, prior, tree = NULL, model = "MIX")
otu_tab |
a data frame or matrix containing the count data. Rows of the matrix represent observations and columns are the taxa. |
prior |
Dirichlet, Dirichlet-tree, or zero-inflated Dirichlet-tree prior for the proportions. |
tree |
the phylogenetic tree. |
model |
smooth methods for zero-inflated Dirichlet-tree mulinomial, including 0.5, DM, ZIDM, or MIX. |
Returns the estimated microbial compositions by empirical Bayes.
Liu, T., Zhao, H., Wang, T.: An empirical Bayes approach to normalization and differential abundance testing for microbiome data. BMC Bioinformatics 21, 225 (2020).
Zhou, C., Zhao, H., and Wang, T.: Transformation and differential abundance analysis of microbiome data incorporating phylogeny. Bioinformatics btab543, https://doi.org/10.1093/bioinformatics/btab543 (2021).
library(phyloseq) otu_tab <- t(combo.phyloseq.obj@otu_table@.Data) tree <- phy_tree(combo.phyloseq.obj) eBay.comps <- eBay_comps(otu_tab, prior = "Dirichlet", tree=NULL) eBay.tree.comps <- eBay_comps(otu_tab, prior = "Dirichlet-tree", tree = tree) eBay.zitree.comps <- eBay_comps(otu_tab, prior = "zero-inflated-Dirichlet-tree", tree = tree, model= "MIX")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.