rank_tax: Generate a ranked vector of OTUs or other taxonomic level.

Description Usage Arguments Value Examples

View source: R/rank_tax.R

Description

Generate a ranked vector of OTUs or other taxonomic level.

Usage

1
rank_tax(df, desc = TRUE, tax_level = "OTU", tax_df = otu_good_taxonomy)

Arguments

df

A dataframe containing OTU data to be used to determine ranking.

desc

Boolean for determining whether the OTUs should be sorted in descending (default) or ascending order.

tax_level

Taxonomic level in tax_df to be utilized for ranking. The values within tax_level should also be column names in df. Defaults to OTU.

tax_df

Taxonomy table. Defaults to otu_good_taxonomy.

Value

A ranked character vector based on the mean abundance corresponding to levels in tax_df[, tax_level].

Examples

1
2
rank_tax(df = dplyr::filter(otu_df, Experiment == "Amx"))
rank_tax(phy_filt, tax_level = "Phylum")

cb-42/cbmbtools documentation built on Jan. 9, 2021, 1:38 a.m.