set_scientific_name {corella} | R Documentation |
Set, create or modify columns with scientific name & authorship information
Description
Format the field scientificName
, the lowest identified taxonomic name of an
occurrence, along with the rank and authorship of the provided name to a
tibble
using Darwin Core Standard.
Usage
set_scientific_name(
.df,
scientificName = NULL,
scientificNameAuthorship = NULL,
taxonRank = NULL,
.keep = "unused"
)
Arguments
.df |
A |
scientificName |
The full scientific name in the lower level taxonomic rank that can be determined. |
scientificNameAuthorship |
The authorship information for |
taxonRank |
The taxonomic rank of |
.keep |
Control which columns from .data are retained in the output.
Note that unlike |
Details
In practice this function is used no differently from mutate()
, but gives
users some informative errors, and serves as a useful lookup for accepted
column names in the Darwin Core Standard.
Examples of scientificName
values (we specify the rank in parentheses, but
users should not include this information):
-
Coleoptera
(order) -
Vespertilionidae
(family) -
Manis
(genus) -
Ctenomys sociabilis
(genus + specificEpithet) -
Ambystoma tigrinum diaboli
(genus + specificEpithet + infraspecificEpithet)
Examples of scientificNameAuthorship
:
-
(Györfi, 1952)
-
R. A. Graham
-
(Martinovský) Tzvelev
Examples of taxonRank
:
-
order
-
genus
-
subspecies
-
infraspecies
Value
A tibble with the requested columns added/reformatted.
See Also
set_taxonomy()
for taxonomic name information.
Examples
df <- tibble::tibble(
name = c("Crinia Signifera", "Crinia Signifera", "Litoria peronii"),
latitude = c(-35.27, -35.24, -35.83),
longitude = c(149.33, 149.34, 149.34),
eventDate = c("2010-10-14", "2010-10-14", "2010-10-14")
)
# Reformat columns to Darwin Core Standard terms
df |>
set_scientific_name(
scientificName = name
)