Generate Urban Greening Zone Raster for ELSA Analysis
make_urban_greening_zone.RdThis function creates a SpatRaster layer representing planning units where urban
greening interventions are applicable in the ELSA framework. The Urban Greening Zone
identifies built/urban areas where greening actions (e.g., tree planting, green
infrastructure) can be implemented.
Uso
make_urban_greening_zone(
iso3,
pus,
built_areas_input = NULL,
lulc_proportions = NULL,
lulc_raster = NULL,
lulc_product = c("esri_10m", "dynamic_world", "esa_worldcover", "local"),
built_area_lulc_value = NULL,
built_area_threshold = 0,
filter_patch_size = FALSE,
min_patch_size = 10,
output_path = NULL
)Argumentos
- iso3
ISO3 country code (e.g., "NPL").
- pus
A
SpatRasterdefining the planning units.- built_areas_input
A
SpatRasterrepresenting binary or probabilistic built-up areas (optional). If provided, this takes priority over extraction from other inputs.- lulc_proportions
A multi-band
SpatRasteror list fromdownload_lulc_proportions()containing pre-computed class proportions. If provided and contains "built_area", will be used ifbuilt_areas_inputis NULL.- lulc_raster
A
SpatRasterLULC map used to extract built-up areas if not already provided (default: NULL).- lulc_product
Character. LULC product used for class value lookups: "esri_10m" (default), "dynamic_world", "esa_worldcover", or "local". When "local",
built_area_lulc_valuemust be provided.- built_area_lulc_value
Integer or NULL. LULC value representing built-up areas. If NULL, automatically determined from
lulc_product. Default is NULL.- built_area_threshold
Minimum fraction for built-up area to be included (default: 0). A threshold of 0 includes all urban areas, which is recommended since urban areas are often small and should be preserved.
- filter_patch_size
Logical. Whether to remove small isolated patches (default: FALSE). Defaults to FALSE because urban areas are often small and should be preserved.
- min_patch_size
Integer. Minimum patch size to retain (in raster cells; default: 10). Only used if
filter_patch_size = TRUE.- output_path
Optional directory to write the result as a COG.