gs_nlcd: gs_nlcd

Description Usage Arguments Examples

Description

This function takes an input landscape, a user-defined land area as an [sf] polygon and returns the NLCD landscape, canopy, or impervious cover for the polygon. The input polygon must be projected and must overlap a USA NLCD area Data are returned for years 2001, 2006, or 2011; The default is 2011

Usage

1
2
3
4
gs_nlcd(landscape, spatial = TRUE, label = NA, year = 2011,
  dataset = "landcover", force.redo = TRUE, raw.dir = "./nlcd_data/raw",
  extraction.dir = "./nlcd_data/cropped",
  raster.options = c("COMPRESS=DEFLATE", "ZLEVEL=9"))

Arguments

landscape

A spatial polygon of class "sf" (see package [sf]) to serve as a template for cropping the NLCD tile(s). Note: the object must be projected (i.e. has a coordinate reference system and must overlap the NLCD area).

spatial

keep the spatial data? Default = TRUE.

label

A character string naming the study area. If no label is supplied the function will use the name of the input landscape as the label. A unique label for each input landscape is required if force.redo = FALSE.

year

An integer representing the year of desired NLCD product. Acceptable values are 2011 (default), 2006, and 2001.

dataset

A character string representing type of the NLCD product. Acceptable values are landcover' (default), 'impervious', and 'canopy'. NOTE: canopy data not currently available for year = 2006 and sometimes year = 2001; appears to work for year = 2011.

force.redo

If an extraction for this template and label already exists, should a new one be created?

raw.dir

A character string indicating where raw downloaded files should be put. The directory will be created if missing. Defaults to './nlcd_data/raw/'.

extraction.dir

A character string indicating where the extracted and cropped NLCD tile should be put. The directory will be created if missing. Defaults to './nlcd_data/cropped/'.

raster.options

A vector of options for raster::writeRaster (see also FedData::get_nlcd).

Examples

1

USEPA/goatscape documentation built on May 15, 2019, 1:27 p.m.