Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

match_names-methods

ott_id and flags for taxonomic names matched by tnrs_match_names


Description

rotl provides a collection of functions that allows users to extract relevant information from an object generated by tnrs_match_names function.

Usage

## S3 method for class 'match_names'
ott_id(tax, row_number, taxon_name, ott_id, ...)

## S3 method for class 'match_names'
flags(tax, row_number, taxon_name, ott_id, ...)

flags(tax, ...)

Arguments

tax

an object returned by tnrs_match_names

row_number

the row number corresponding to the name for which to list the synonyms

taxon_name

the taxon name corresponding to the name for which to list the synonyms

ott_id

the ott id corresponding to the name for which to list the synonyms

...

currently ignored

Details

These methods optionally accept one of the arguments row_number, taxon_name or ott_id to retrieve the corresponding information for one of the matches in the object returned by the tnrs_match_names function.

If these arguments are not provided, these methods can return information for the matches currently listed in the object returned by tnrs_match_names.

Value

A list of the ott ids or flags for the taxonomic names matched with tnrs_match_names, for either one or all the names.

Examples

## Not run: 
  rsp <- tnrs_match_names(c("Diadema", "Tyrannosaurus"))
  rsp$ott_id    # ott id for match currently in use
  ott_id(rsp)   # similar as above but elements are named

  ## flags() is useful for instance to determine if a taxon is extinct
  flags(rsp, taxon_name="Tyrannosaurus")

## End(Not run)

rotl

Interface to the 'Open Tree of Life' API

v3.0.11
BSD_2_clause + file LICENSE
Authors
Francois Michonneau [aut, cre] (<https://orcid.org/0000-0002-9092-966X>), Joseph Brown [aut] (<https://orcid.org/0000-0002-3835-8062>), David Winter [aut] (<https://orcid.org/0000-0002-6165-0029>), Scott Chamberlain [rev] (<https://orcid.org/0000-0003-1444-9135>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.