Learn R Programming

originr (version 0.4.0)

nsr: Search the Native Species Resolver

Description

Search the Native Species Resolver

Usage

nsr(species, country, stateprovince = NULL, countyparish = NULL, ...)

Arguments

species

(character) One or more species names. required.

country

(character) A country name. required.

stateprovince

(character) A state or province name

countyparish

(character) A county or parish name

...

curl options passed on to crul::HttpClient

political names

  • nsr_countries: is a vector of country names that we use to check your country names

  • nsr_pol_divisions: is a data.frame of country names and state/province names that we used to check your parameter inputs - these are for checklists that NSR has complete coverage for

Details

Currently, only one name is allowed per request. We loop internally over a list of length > 1, but this will still be slow due to only 1 name per request.

Note that this service can be quite slow.

References

http://bien.nceas.ucsb.edu/bien/tools/nsr/nsr-ws/

Examples

Run this code
# NOT RUN {
nsr("Pinus ponderosa", country = "United States")
nsr(c("Pinus ponderosa", "Poa annua"), country = "United States")
splist <- c("Pinus ponderosa", "Poa annua", "bromus tectorum", "Ailanthus altissima")
nsr(splist, country = "United States")
nsr(splist, country = "United States", stateprovince = "California")

# curl options
nsr("Pinus ponderosa", "United States", verbose = TRUE)
# }

Run the code above in your browser using DataLab