get_hand_raster: Get HAND Raster for an AOI

Description Usage Arguments Value

View source: R/hand_tiles.R

Description

This function provides access to a Amazon Web Services HAND S3 Bucket. The function accepts a data.frame of x (long) and y (lat), a sf, or raster object as input. A raster object is returned.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
get_hand_raster(
  locations,
  prj = NULL,
  expand = NULL,
  clip = c("tile", "bbox", "locations"),
  verbose = getOption("verbose"),
  neg_to_na = FALSE,
  override_size_check = FALSE,
  ...
)

Arguments

locations

Either a data.frame of x (long) and y (lat), a sf, or raster object as input.

prj

A PROJ.4 string defining the projection of the locations argument. If a sp or raster object is provided, the PROJ.4 string will be taken from that. This argument is required for a data.frame of locations."

expand

A numeric value of a distance, in map units, used to expand the bounding box that is used to fetch the terrain tiles. This can be used for features that fall close to the edge of a tile and additional area around the feature is desired. Default is NULL.

clip

A character value used to determine clipping of returned HAND. The default value is "tile" which returns the full tiles. Other options are "bbox" which returns the HAND clipped to the bounding box of the original locations (or expanded bounding box if used), or "locations" if the spatials data (e.g. polygons) in the input locations should be used to clip the HAND. Locations are not used to clip input point datasets. Instead the bounding box is used.

verbose

Toggles on and off the note about units and coordinate reference system, as well as download progress and merging messages. This does not prevent download size related messages from appearing.

neg_to_na

Some of the data sources return large negative numbers as missing data. When the end result is a projected those large negative numbers can vary. When set to TRUE, only zero and positive values are returned. Default is FALSE.

override_size_check

Boolean to override size checks. Any download between 100 Mb and 500Mb report a message but continue. Between 500Mb and 3000Mb requires interaction and greater than 3000Mb fails. These can be overriden with this argument set to TRUE.

...

Extra arguments to pass to httr::GET via a named vector, config. See download_tiles for more details.

Value

Function returns a raster object.


mikejohnson51/FloodMapping documentation built on April 7, 2021, 5:19 p.m.