format.fe_species_tum_wwk_short {ForestElementsR} | R Documentation |
Formatted Output of an fe_species_tum_wwk_short Vector
Description
Usually, this function is not required to be called explicitly. It Will
always be used automatically, when an object of type
fe_species_tum_wwk_short
is printed, be it alone, be it as part of
another object (e.g. a tibble)
Usage
## S3 method for class 'fe_species_tum_wwk_short'
format(x, spec_lang = options("fe_spec_lang")$fe_spec_lang, ...)
Arguments
x |
An object of type |
spec_lang |
Choice of how species (group) names or id's are displayed.
Supported choices are "code" (displays the species codes as they are),
"eng" (English species names), "ger" (German species names), and "sci"
(scientific species names). The names and the codes refer to the species
coding given in the object's attribute |
... |
Other parameters (not used) |
Value
A character
vector either displaying the original species
codes provided in x
, or the species (group) names in the desired
language
Examples
# Create an fe_species_tum_wwk_short object
spec_ids <- fe_species_tum_wwk_short(as.character(1:10))
# Display in default style, scientific names, English, and German names
format(spec_ids)
format(spec_ids, spec_lang = "sci")
format(spec_ids, spec_lang = "eng")
format(spec_ids, spec_lang = "ger")
# Usual application: Set option for species code output
# Any print of an fe_species object will use the last setting of the option
options(fe_spec_lang = "sci")
spec_ids