YtreeFun: Calculate the count on each subtree.

View source: R/YtreeFun.R

YtreeFunR Documentation

Calculate the count on each subtree.

Description

Calculate the count on each subtree.

Usage

YtreeFun(otu.tab, tree)

Arguments

otu.tab

a data frame or matrix containing the count data. Rows of the matrix represent observations and columns are the taxa.

tree

the phylogenetic tree.

Value

Returns a list of abundance matrices corresponding to internal nodes of the tree.

Examples

library(phyloseq)
otu.tab <- t(otu_table(combo.phyloseq.obj))
tree <- phy_tree(combo.phyloseq.obj)
ytree <- YtreeFun(otu.tab, tree)
length(ytree)

liudoubletian/phyloMDA documentation built on April 28, 2022, 6:51 p.m.