select_taxa {MiscMetabar} | R Documentation |
Select a subset of taxa in a specified order where possible
Description
Select (a subset of) taxa; if x
allows taxa to be reordered, then taxa are
given in the specified order.
Usage
select_taxa(x, taxa, reorder = TRUE)
## S4 method for signature 'sample_data,character'
select_taxa(x, taxa)
## S4 method for signature 'otu_table,character'
select_taxa(x, taxa, reorder = TRUE)
## S4 method for signature 'taxonomyTable,character'
select_taxa(x, taxa, reorder = TRUE)
## S4 method for signature 'XStringSet,character'
select_taxa(x, taxa, reorder = TRUE)
## S4 method for signature 'phylo,character'
select_taxa(x, taxa)
## S4 method for signature 'phyloseq,character'
select_taxa(x, taxa, reorder = TRUE)
Arguments
x |
A phyloseq object or phyloseq component object |
taxa |
Character vector of taxa to select, in requested order |
reorder |
Logical specifying whether to use the order in |
Details
This is a simple selector function that is like prune_taxa(taxa, x)
when
taxa
is a character vector but always gives the taxa in the order taxa
if possible (that is, except for phy_tree's and phyloseq objects that
contain phy_tree's).
Author(s)
Michael R. McLaren (orcid: 0000-0003-1575-473X)
[Package MiscMetabar version 0.9.1 Index]