getextr: Download distribution data, filter, and merge with climate or...

Description Usage Arguments Examples

View source: R/grab.R

Description

getextr is a function that gets GBIF data and extracts climate or environmental data for each occurrence. This is a whole workflow for distribution data acquisition and value addition that draws on several other functions in cRacle including gbif_get and extraction. Parallel option is useful for speeding up data collection for many species when computational resources are available.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
getextr(
  x,
  clim = clim,
  maxrec = 500,
  schema = "flat",
  repo = c("gbif"),
  rm.outlier = FALSE,
  alpha = 0.01,
  factor = 4,
  nmin = 5,
  parallel = FALSE,
  nclus = 4
)

Arguments

x

A taxon name or list of taxon names. It is sometimes good to test these on the cRacle::get_gbif() function first.

clim

A raster object of climate or other environmental data to extract from.

maxrec

Maximum number of records to download.

schema

To be passed to cRacle::extraction

repo

Pass to get_dist_all

rm.outlier

To be passed to cRacle::extraction

alpha

To be passed to cRacle::extraction

factor

To be passed to cRacle::extraction

nmin

To be passed to cRacle::extraction

parallel

TRUE or FALSE. Should this be executed in parallel.

nclus

If parallel == TRUE then how many cores should be used? Default is 4.

Examples

1
2
3
4
5
6
7
## Not run: 
abies <- getextr(c('Abies fraseri', 'Abies lasiocarpa', 'Pinus strobus'),
clim = clim, maxrec=500,
schema= 'flat', rm.outlier = TRUE,
alpha=0.01, factor = 2, nmin = 5, parallel=FALSE, nclus = 4);

## End(Not run)

rsh249/cRacle documentation built on Feb. 2, 2022, 2:01 p.m.