Create a histogram of the values of a SpatRaster
.
Arguments
- mosaic
SpatRaster
- layer
positive integer or character to indicate layer numbers (or names). If missing, all layers are used
- ...
Further arguments passed on to
terra::hist()
.
Examples
if (interactive() && requireNamespace("EBImage")) {
library(pliman)
r <- mosaic_input(system.file("ex/elev.tif", package="terra"))
mosaic_hist(r)
}
#> Warning: The current raster is in the lat/lon coordinate system, which may result in processing errors when trying to segment individuals in the `mosaic_analyze()` function. It is highly suggested to reproject the raster using mosaic_project() with EPSG:32632
#> class : SpatRaster
#> dimensions : 90, 95, 1 (nrow, ncol, nlyr)
#> resolution : 0.008333333, 0.008333333 (x, y)
#> extent : 5.741667, 6.533333, 49.44167, 50.19167 (xmin, xmax, ymin, ymax)
#> coord. ref. : lon/lat WGS 84 (EPSG:4326)
#> source : elev.tif
#> name : elevation
#> min value : 141
#> max value : 547