This function takes information of where and when a set of environmental samples were
collected and retrieves a suite of topographical and hydrological variables for each unique
location. The variables include: elevation, slope, aspect, Topographical Wetness Index (TWI),
flow accumulation, total flow accumulation within 500m, and distance to the nearest stream.
If a DEM is not provided, then a DEM is acquired via elevatr::get_elev_raster
and the suite of variables are calculated using functions from the 'WhiteboxTools'
R frontend.
Arguments
- lon
A numeric vector giving the longitude of the sampling sites in Decimal Degrees.
- lat
A numeric vector giving the latitude of the sampling sites in Decimal Degrees.
- path_dem_raster
The file path to a Digital Elevation Model (DEM) raster. See
download_elevation_data
for methods to download DEM raster data. If NULL, a DEM is downloaded automatically using this function.- path_output
The file path of an output directory where spatial data will be saved.