filter_id {taxadb} | R Documentation |
Return a taxonomic table matching the requested ids
Description
Return a taxonomic table matching the requested ids
Usage
filter_id(
id,
provider = getOption("taxadb_default_provider", "itis"),
type = c("taxonID", "acceptedNameUsageID"),
version = latest_version(),
collect = TRUE,
db = td_connect()
)
Arguments
id |
taxonomic id, in prefix format |
provider |
from which provider should the hierarchy be returned?
Default is 'itis', which can also be configured using |
type |
id type. Can be |
version |
Which version of the taxadb provider database should we use? defaults to latest. See tl_import for details. |
collect |
logical, default |
db |
a connection to the taxadb database. See details. |
Details
Use type="acceptedNameUsageID"
to return all rows
for which this ID is the accepted ID, including both synonyms and
and accepted names (since both all synonyms of a name share the
same acceptedNameUsageID
.) Use taxonID
(default) to only return
those rows for which the Scientific name corresponds to the taxonID.
Some providers (e.g. ITIS) assign taxonIDs to synonyms, most others
only assign IDs to accepted names. In the latter case, this means
requesting taxonID
will only match accepted names, while requesting
matches to the acceptedNameUsageID
will also return any known synonyms.
See examples.
Value
a data.frame with id and name of all matching species
See Also
Other filter_by:
filter_by()
,
filter_common()
,
filter_name()
,
filter_rank()
Examples
filter_id(c("ITIS:1077358", "ITIS:175089"))
filter_id("ITIS:1077358", type="acceptedNameUsageID")