Learn R Programming

amadeus (version 1.2.3)

process_nlcd: Process land cover data

Description

The process_nlcd() function imports and cleans raw land cover data, returning a single SpatRaster object.

Reads NLCD file of selected year.

Usage

process_nlcd(path = NULL, year = 2021, extent = NULL, ...)

Value

a SpatRaster object

Arguments

path

character giving nlcd data path

year

numeric giving the year of NLCD data used

extent

numeric(4) or SpatExtent giving the extent of the raster if NULL (default), the entire raster is loaded

...

Placeholders.

Author

Eva Marques, Insang Song

Examples

Run this code
## NOTE: Example is wrapped in `\dontrun{}` as function requires a large
##       amount of data which is not included in the package.
if (FALSE) {
nlcd <- process_nlcd(
  path = "./data/",
  year = 2021
)
}

Run the code above in your browser using DataLab