auto_calc_predictors: Calculate predictor layers for a classification

Description Usage Arguments Details

View source: R/auto_calc_predictors.R

Description

This function automates the calculation of a layer stack of predictor layers to use in a land use and/or land cover classification. See Details for the output layers.

Usage

1
2
3
auto_calc_predictors(x, dem, slopeaspect, output_path = NULL, ext = "tif",
  overwrite = FALSE, notify = print, glcm_statistics = c("mean",
  "variance", "dissimilarity"), ...)

Arguments

x

path to a preprocessed image as output by auto_preprocess_landsat or auto_cloud_fill.

dem

DEM RasterLayer as output by auto_setup_dem (or missing to exclude DEM from output)

slopeaspect

RasterStack as output by auto_setup_dem (or missing to exclude slope and aspect from output)

output_path

the path to use for the output (optional - if NULL then output images will be saved alongside the input images in the same folder).

ext

file extension to use when saving output rasters (determines output file format).

overwrite

whether to overwrite existing files (otherwise an error will be raised)

notify

notifier to use (defaults to print function). See the notifyR package for one way of sending notifications from R. The notify function should accept a string as the only argument.

glcm_statistics

list of glcm statistics to calculate (see glcm)

...

additional arguments passed to glcm, such as n_grey, window, or shift

Details

The layers in the output layer stack are listed below. Note that all the layers are rescaled so that they range between -32,767 and 32,767 (allowing them to be stored as 16 bit unsigned integers).

Predictor layer stack:

Layer 1: Band 1 reflectance
Layer 2: Band 2 reflectance
Layer 3: Band 3 reflectance
Layer 4: Band 4 reflectance
Layer 5: Band 5 reflectance
Layer 6: Band 7 reflectance
Layer 7: MSAVI2
Layer 8: GLCM mean (from MSAVI2)
Layer 9: GLCM variance (from MSAVI2)
Layer 10: GLCM dissimilarity (from MSAVI2)
Layer 11: Elevation
Layer 12: Slope (radians X 10000)
Layer 13: Aspect (see below)

The aspect is recoded as:

Aspect coding:

1: north facing (0-45 degrees, 315-360 degrees)
2: east facing (45-135 degrees)
3: south facing (135-225 degrees)
4: west facing (225-315 degrees)

azvoleff/teamlucc documentation built on June 4, 2017, 12:08 a.m.