This function uses the rgbif package to get occurrence data of a species.

rgbif2(
  dir = "results/",
  filename = "output",
  species,
  force = FALSE,
  remove_na = TRUE,
  save = TRUE,
  ...
)

Arguments

dir

Path to directory where the file will be saved. Default is to create a "results/" directory

filename

Name of the output file

species

Genus and specific epithet separated by space. Accepts author if inserted correctly. Either a single value or a vector

force

Logical. Force downloading data for more than 10 species in a loop. Default `force = FALSE`

remove_na

Logical. Defalt `TRUE` removes NA in columns decimalLatitude and decimalLongitude

save

Logical. Save output to filename? Defaults to TRUE

...

Any argument from occ_search in rgbif package

Value

A data.frame with the search result. Also saves the output on disk

Author

Sara Mortara & Andrea Sánchez-Tapia

Sara Mortara & Andrea Sánchez-Tapia

Examples

if (FALSE) { ex_rgbif <- rgbif2(filename = "ex-gbif", species = "Asplenium truncorum") }