Description Usage Arguments Examples
Categories are usually labelled something like "crust_copepods_calanus", "crust_copepods_euchaeta", "crust_larvae", etc.; with different taxonomic levels separated by "_". This function regroups categories in higher level taxonomic units (such as "crust" here).
1 | regroup_taxa(x, level = 1, pattern = NULL, separator = "_")
|
x |
vector of categories (usually the "Valid" column of the data.frame produced by |
level |
level at which to regroup (1 is what precedes the first separator, 2 is what precedes the second separator, etc.) |
pattern |
when provided, only act on categories whose name matches the pattern (matching is done by |
separator |
character used to separate taxonomic levels in category names; usually "_" |
1 2 3 4 | x <- c("append_fritill", "append_housing", "crust_copepods_calanus", "crust_copepods_euchaeta", "crust_larvae")
regroup_taxa(x)
regroup_taxa(x, level=2)
regroup_taxa(x, pattern="crust")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.