| resolve_bands | R Documentation |
Matches required band roles (e.g., "nir", "red") against the layers
of a terra::SpatRaster using custom user mapping, sensor presets, or
heuristic name aliases. Optionally applies a scale factor (e.g. 10000) to
convert raw integer Digital Numbers into physical reflectance [0, 1].
resolve_bands(
image,
required_bands,
custom_mapping = NULL,
sensor = NULL,
index_name = "Index",
scale_factor = NULL
)
image |
A |
required_bands |
Character vector of required standardized band names. |
custom_mapping |
Optional named vector or list mapping required names
to layer names or layer indices in |
sensor |
Optional character string for sensor presets. |
index_name |
Optional character string of the index being calculated (for error reporting). |
scale_factor |
Optional numeric scaling divisor (e.g. |
A named list of single-layer terra::SpatRaster objects.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.