h
will be agglomerated into one taxa using merge_taxa
.tip_glom(physeq, h = 0.2, hcfun = agnes, ...)
phyloseq-class
,
containing a phylogenetic tree.
Alternatively, a phylogenetic tree phylo
will also work.cophenetic.phylo(phy_tree(physeq))
,
not necessarily the original phylogenetic tree, phy_tree(physeq)
.
Default value is 0.2
.
Note that this argument used to be named speciationMinLength
,
before this function/method was rewritten.hcfun
.phyloseq-class
.
Or alternatively, a phylo
object if the
physeq
argument was just a tree.
In the expected-use case, the number of OTUs will be fewer
(see ntaxa
),
after merging OTUs that are related enough to be called
the same OTU.For now, a simple, ``greedy'', single-linkage clustering is used. In future releases
it should be possible to specify different clustering approaches available in R
,
in particular, complete-linkage clustering appears to be used more commonly for OTU
clustering applications.
merge_taxa
data("esophagus")
# for speed
esophagus = prune_taxa(taxa_names(esophagus)[1:25], esophagus)
plot_tree(esophagus, label.tips="taxa_names", size="abundance", title="Before tip_glom()")
plot_tree(tip_glom(esophagus, h=0.2), label.tips="taxa_names", size="abundance", title="After tip_glom()")
Run the code above in your browser using DataLab