fast_tax_glom: Fast alternative to [tax_glom()] from phyloseq.extended...

View source: R/phyloseq_extended_graphical_methods.R

fast_tax_glomR Documentation

Fast alternative to [tax_glom()] from phyloseq.extended package.

Description

Fast alternative to [tax_glom()] from phyloseq.extended package.

Usage

fast_tax_glom(
  physeq,
  taxrank = rank_names(physeq)[1],
  bad_empty = c("", " ", "\t")
)

Arguments

physeq

Required. phyloseq-class object

taxrank

A character string specifying the taxonomic level that you want to agglomerate over. Should be among the results of rank_names(physeq). The default value is rank_names(physeq)[1], which may agglomerate too broadly for a given experiment. You are strongly encouraged to try different values for this argument.

bad_empty

(Optional). Character vector. Default to empty white spaces and tabs. Defines the bad/empty values that should be replaced by "Unknown".

Details

fast_tax_glom differs from [tax_glom()] in three important ways: * It is based on dplyr function and thus much faster * It does not preserve the phy_tree slot * It only preserves taxonomic ranks up to taxrank and discard all other ones. The "archetype" (OTU name) and sequence for each group are chosen as those from the most abundant taxa within that group (for compatibility with [tax_glom()])

Value

A taxonomically-agglomerated phyloseq-class object.

See Also

[tax_glom()], [merge_taxa()]


erifa1/ExploreMetabar documentation built on Jan. 12, 2023, 1:51 a.m.