Description Usage Arguments Details Value See Also
Useful for scaling and (optionally) rounding a RasterLayer
to integer
so that a layer can be saved as an integer datatype such as "INT1U",
"INT1S", "INT2" or "INT2S".
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | scale_raster(x, power_of = 10, max_out = 32767, round_output = TRUE,
do_scaling = TRUE)
## S4 method for signature 'RasterLayer'
scale_raster(x, power_of = 10, max_out = 32767,
round_output = TRUE, do_scaling = TRUE)
## S4 method for signature 'RasterStack'
scale_raster(x, power_of = 10, max_out = 32767,
round_output = TRUE, do_scaling = TRUE)
## S4 method for signature 'RasterBrick'
scale_raster(x, power_of = 10, max_out = 32767,
round_output = TRUE, do_scaling = TRUE)
|
x |
a |
power_of |
raster will be scaled using the highest possible power of this number |
max_out |
the scaling factors will be chosen for each layer to ensure
that the maximum and minimum (if minimum is negative) values of each layer
do not exceed |
round_output |
whether to round the output to the nearest integer |
do_scaling |
perform the scaling and return a |
This function will run in parallel if a parallel backend is registered with
foreach
.
a Raster*
if do_scaling
is TRUE, or a list of scaling
factors if do_scaling
is false.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.