Skip to contents

This function searches for a name in florula.collection, allowing the user to select which attributes to search in.

Usage

search_name_in_collection(
  name,
  attributes.to.search = c("genus", "epithet", "subspecies", "variety", "form"),
  florula.collection
)

Arguments

name

A character with a Latin name to search in florula.collection.

attributes.to.search

A character vector with the attributes to search in (any of 'genus', 'epithet', 'subspecies', 'variety' and 'form').

florula.collection

An ArangoCollection containing a flora list.

Value

A list with the ArangoDocuments in the florula.collection from which Latin names match the given name. The function returns NULL if no match is found.

Details

The given name is searched separately in each of the given attributes (one by one), for all ArangoDocuments of florula.collection and the results are collected in a list.

Author

Tiago Monteiro-Henriques. E-mail: tmh.dev@icloud.com.