dct_check_sci_name {dwctaxon}R Documentation

Check scientificName

Description

Check for correctly formatted scientificName column in Darwin Core taxonomic data.

Usage

dct_check_sci_name(
  tax_dat,
  on_fail = dct_options()$on_fail,
  on_success = dct_options()$on_success,
  quiet = dct_options()$quiet
)

Arguments

tax_dat

Dataframe; taxonomic database in DwC format.

on_fail

Character vector of length 1, either "error" or "summary". Describes what to do if the check fails. Default "error".

on_success

Character vector of length 1, either "logical" or "data". Describes what to do if the check passes. Default "data".

quiet

Logical vector of length 1; should warnings be silenced? Default FALSE.

Details

The following rules are enforced:

Value

Depends on the result of the check and on values of on_fail and on_success:

Examples

dct_check_sci_name(
  data.frame(scientificName = NA_character_),
  on_fail = "summary", quiet = TRUE
)

dct_check_sci_name(data.frame(scientificName = "a"))

[Package dwctaxon version 2.0.3 Index]