update_taxonomy {APCalign}R Documentation

Update to currently accepted APC name and add APC/APNI name metadata

Description

For a list of taxon names aligned to the APC, update the name to an accepted taxon concept per the APC and add scientific name and taxon concept metadata to names aligned to either the APC or APNI.

Usage

update_taxonomy(
  aligned_data,
  taxonomic_splits = "most_likely_species",
  quiet = TRUE,
  output = NULL,
  resources = load_taxonomic_resources()
)

Arguments

aligned_data

A tibble of plant names to update. This table must include 5 columns, original_name, aligned_name, taxon_rank, taxonomic_dataset, and aligned_reason. These columns are created by the function align_taxa. The columns original_name and aligned_name must be in the format of the scientific name, with genus and species, and may contain additional qualifiers such as subspecies or varieties. The names are case insensitive.

taxonomic_splits

Variable that determines what protocol to use to update taxon names that are ambiguous due to taxonomic splits. The three options are:

  • most_likely_species, which returns the species name in use before the split; alternative names are returned in a separate column

  • return_all, which returns all possible names

  • collapse_to_higher_taxon, which declares that an ambiguous name cannot be aligned to an accepted species/infraspecific name and the name is demoted to genus rank

quiet

Logical to indicate whether to display messages while updating taxa.

output

(optional) Name of the file where results are saved. The default is NULL and no file is created. If specified, the output will be saved in a CSV file with the given name.

resources

the taxonomic resources required to make the summary statistics. Loading this can be slow, so call load_taxonomic_resources separately to greatly speed this function up and pass the resources in.

Details

Notes:

Value

A tibble with updated taxonomy for the specified plant names. The tibble contains the following columns:

See Also

load_taxonomic_resources

Other taxonomic alignment functions: align_taxa(), create_taxonomic_update_lookup()

Examples

# Update taxonomy for two plant names and print the result

resources <- load_taxonomic_resources()

update_taxonomy(
 dplyr::tibble(
   original_name = c("Dryandra preissii", "Banksia acuminata"),
   aligned_name = c("Dryandra preissii", "Banksia acuminata"),
   taxon_rank = c("species", "species"),
   taxonomic_dataset = c("APC", "APC"),
   aligned_reason = c(NA_character_,
   NA_character_)
 ),
 resources = resources
)


[Package APCalign version 1.0.1 Index]