Skip to contents

Get summary taxa abundances.

Usage

taxa_sums(biom, rank = 0)

taxa_means(biom, rank = 0)

Arguments

biom

An rbiom object, such as from as_rbiom(). Any value accepted by as_rbiom() can also be given here.

rank

The taxonomic rank to return sums or means for. The default, 0, returns per-OTU summaries.

Value

A named, sorted numeric vector.

See also

Examples

    library(rbiom) 
    
    taxa_sums(hmp50) %>% head(4)
#> Unc01yki Unc53100 LtbAci52 CnbTube3 
#>    24096    23409    15996    14734 
    
    taxa_means(hmp50, 'Family') %>% head(5)
#>   Lactobacillaceae   Streptococcaceae Corynebacteriaceae     Bacteroidaceae 
#>             803.74             492.16             364.74             323.22 
#>  Staphylococcaceae 
#>             275.52