collapse_taxonomy: Collapse taxonomy into single strings

View source: R/data_refinement.R

collapse_taxonomyR Documentation

Collapse taxonomy into single strings

Description

Given a phyloseq object with a taxonomy table, this function extracts the taxonomy of each OTU and collapse the result into a single string

Usage

collapse_taxonomy(phyloseq)

Arguments

phyloseq

A phyloseq object containing the tax_table slot. If this slot does not exist, the function will return NULL.

Value

A named character vector, where the names are the OTU names and the values are the collapsed taxonomies.

Examples

library(micInt)
collapsed <- collapse_taxonomy(seawater)
collapsed

AlmaasLab/micInt documentation built on April 1, 2022, 10:37 a.m.