get_all_clades {yatah} | R Documentation |
Extract all clades present in the lineages
Description
Extract all clades present in the lineages
Usage
get_all_clades(lineage, simplify = TRUE)
Arguments
lineage |
string. Vector of lineages. |
simplify |
logical. Should the output be a vector or a dataframe? |
Details
If a clade correspond to different ranks (e.g. Actinobacteria
is both a phylum and a clade), it will be displayed only one time when
simplify
is set to TRUE
. It is also the case for different
clades with same name and same rank when simplify
is set to
FALSE
.
Value
The clades present in the lineage. Vector of ordered strings or data.frame.
Examples
lineage1 <- "k__Bacteria|p__Verrucomicrobia|c__Verrucomicrobiae"
lineage2 <- "k__Bacteria|p__Firmicutes|c__Clostridia"
lineage3 <- "k__Bacteria|p__Actinobacteria|c__Actinobacteria"
get_all_clades(c(lineage1, lineage2, lineage3))
get_all_clades(c(lineage1, lineage2, lineage3), simplify = FALSE)
[Package yatah version 1.0.0 Index]