Sums the absolute change between consecutive bands at every pixel, giving a field of total spectral variability. Flat spectra appear dark; pixels whose reflectance swings across the spectrum appear bright.
Arguments
- cube
An
hsi_cube(from hyperspectR) or a 3-D array with dimensions(rows, cols, bands).- palette
Palette name passed to
hsa_palette().- normalise
Logical. Divide by the number of band steps, so the value is a mean absolute step rather than a total. Default
TRUE, which makes cubes with different band counts comparable.- stretch
Contrast stretch:
"percentile"(default),"range"or"none".- probs
Percentiles for
stretch = "percentile". Defaultc(0.02, 0.98).
Details
Unlike a single-band image this cannot be produced from any one wavelength, and unlike a variance map it is sensitive to the ordering of the bands, so it responds to spectral shape rather than spread alone.
Examples
cube <- hsa_demo_cube()
hsa_spectral_flux(cube)