Cell polygons are generated only for the supplied cells. Extraction uses
exact raster-pixel coverage through exactextractr::exact_extract(). With
fun = NULL, continuous layers use an area-weighted mean and categorical
layers use a coverage-weighted mode. This makes longitude/latitude rasters
safe by default, because their pixels do not have equal physical area.
Arguments
- cell
A
globalhex_cellvector.- raster
- fun
A named
exactextractrsummary, a vector of summary names, or a custom summary function.NULLchooses a type-aware default.- weights
Weights for continuous defaults and explicit weighted summaries. Use
"area"(the default),NULLfor coverage fractions alone, or a compatible terra::SpatRaster.- ...
Additional arguments passed to
exactextractr::exact_extract().- progress
Whether
exactextractrdisplays progress.NULLfollowsinteractive().
Value
A hex_data() object with one row per input cell.