extractEnv: Extract environmental data

Description Usage Arguments Details Value

Description

Extract and associate environmental data from GIS layers with eBird records.

Usage

1
2
extractEnv(ebird.data, env.wd, keep, longitude, latitude,
  cut.incomplete = TRUE)

Arguments

ebird.data

Dataframe of eBird records.

env.wd

Working directory where the environmental data is currently stored. It would be very easy to make this able to download environmental data, set the resolution you want in the data, and to use other forms of environmental data besides bioclim, but those things are currently hardwired in. It won't be much more work to make this more flexible when we're ready to take that step.

keep

Character vector of column names in the existing eBird records that you would like to be passed along/kept in the cleaned files. Specify names(ebird.data), (but substitute the actual name of your data frame, see example) to keep all columns.

longitude

The name of the column in the eBird data files where the longitude data is kept.

latitude

The name of the column in the eBird data files where the latitude data is kept.

cut.incomplete

Default is TRUE. If a point is missing environmental data, will remove that point before saving out the file.

Details

There is a lot of room to make this function more flexible. Currently it assumes you have bioclim data in a folder already on your computer at a resolution of 2.5 minutes. There is no reason the function cannot be generalized to download bioclim data at whatever resolution you prefer, and there is no reason it cannot be generalized to extract data from other GIS layers.

Value

Saves data files with associated environmental data to the write.wd, returns a data frame summarizing sample sizes to the workspace.


eliotmiller/ebirdr documentation built on May 14, 2019, 10:33 a.m.