foto: Calculates FOTO classification of texture

View source: R/foto.R

fotoR Documentation

Calculates FOTO classification of texture

Description

Note that the input matrix should be square or results will be discarded

Usage

foto(
  x,
  window_size = 61,
  method = "zones",
  norm_spec = FALSE,
  high_pass = TRUE,
  pca = TRUE,
  plot = FALSE
)

Arguments

x

an image file, or single or multi-layer SpatRaster (RGB or otherwise), multi-layer data are averaged to a single layer

window_size

a moving window size in pixels (default = 61 pixels)

method

zones (for discrete zones) or mw for a moving window approach

norm_spec

normalize radial spectrum, bolean TRUE or FALSE

high_pass

apply high pass filter to radial spectra, bolean TRUE or FALSE

pca

execute PCA, TRUE or FALSE. If FALSE only the radial spectra are returned for additional manipulation. Plotting is ignored if set to FALSE.

plot

plot output, bolean TRUE or FALSE

Value

returns a radial spectrum for a moving window across a raster layer

See Also

rspectrum

Examples

## Not run: 
# load demo data
r <- terra::rast(system.file("extdata",
  "yangambi.png",
  package = "foto",
  mustWork = TRUE
))

# classify pixels using zones (discrete steps)
output <- foto(r,
  plot = FALSE,
  window_size = 25,
  method = "zones"
)

# print data structure
print(names(output))

## End(Not run)


foto documentation built on Oct. 4, 2023, 1:07 a.m.

Related to foto in foto...