For advanced users. fire_exp_validate()
compares the
proportion of exposure classes in a the study area to the proportion of
exposure classes within observed burned areas.
Usage
fire_exp_validate(
burnableexposure,
fires,
aoi,
class_breaks = c(0.2, 0.4, 0.6, 0.8, 1),
samplesize = 0.005
)
Arguments
- burnableexposure
A SpatRaster of exposure, non-burnable cells should be removed using optional parameter
no_burn =
infire_exp()
.- fires
A SpatVector of observed fire perimeters
- aoi
(Optional) A SpatVector that delineates an area of interest
- class_breaks
(Optional) vector of numeric values between 0-1 of the upper limits of each class. The default is
c(0.2, 0.4, 0.6, 0.8, 1)
. See details.- samplesize
Proportion of areas to sample. The default is
0.005
(0.5%)
Value
a table of number of cells (n) and proportions (prop) of exposure classes within a sampled area (Sample) and across the full extent (Total).for the full extent of the exposure data (expected) and only within the burned areas (observed).
Details
This function automates a simple validation method to assess if fire burns
preferentially in areas with high exposure. The methods, and figure produced
with fire_exp_validate_plot()
, are based on Beverly et al. (2021).
The function requires an exposure raster produced for a past point in time.
Cells that cannot burn, or do not represent natural land cover should be
removed by setting the no_burn
parameter in fire_exp()
or
fire_exp_adjust()
.
The function also requires fire perimeter data. Currently, the function takes the fires as a Vector of polygons because that is typically how fire boundaries are stored in spatial databases. The fires input data should include all of the burned area that has occurred following the time period the input exposure layer was produced for. It is up to the user to determine the appropriate amount of burned area required for a meaningful assessment.
A random sample is taken to account for spatial autocorrelation, the
sampled location results can be used to test for significant differences.
The sample size can be adjusted. The sample size represents a proportion of
cells, the default is 0.005
(0.5%). It is the user's responsibility to set
an appropriate sample size.
The class breaks can be customized from the default of 0.2 intervals by
setting the class_breaks
parameter. A class of Nil is automatically added
for values exactly equal to 0.
References
Beverly JL, McLoughlin N, Chapman E (2021) A simple metric of landscape fire exposure. Landscape Ecology 36, 785-801. DOI
Examples
# read example hazard data
hazard_file_path <- "extdata/hazard.tif"
hazard <- terra::rast(system.file(hazard_file_path, package = "fireexposuR"))
# generate example non-burnable cells data
geom_file_path <- "extdata/polygon_geometry.csv"
geom <- read.csv(system.file(geom_file_path, package = "fireexposuR"))
polygon <- terra::vect(as.matrix(geom), "polygons", crs = hazard)
no_burn <- terra::rasterize(polygon, hazard)
# generate example fire polygons by buffering random points
points <- terra::spatSample(terra::rescale(hazard, 0.8),
30, as.points = TRUE)
fires <- terra::buffer(points, 800)
# PLEASE NOTE THIS EXAMPLE DATA DOES NOT GENERATE MEANINGFUL RESULTS
# compute exposure and remove non-burnable cells
exposure <- fire_exp(hazard, no_burn = no_burn)
# validation table
fire_exp_validate(exposure, fires)
#> exposure exp_vals of group n prop
#> 1 0 Nil Total Expected 2464 0.02568272
#> 2 1 0 - 0.2 Total Expected 11679 0.12173233
#> 3 2 0.2 - 0.4 Total Expected 12922 0.13468835
#> 4 3 0.4 - 0.6 Total Expected 14912 0.15543048
#> 5 4 0.6 - 0.8 Total Expected 18595 0.19381905
#> 6 5 0.8 - 1 Total Expected 35368 0.36864707
#> 7 0 Nil Total Observed 262 0.04448973
#> 8 1 0 - 0.2 Total Observed 709 0.12039395
#> 9 2 0.2 - 0.4 Total Observed 647 0.10986585
#> 10 3 0.4 - 0.6 Total Observed 811 0.13771438
#> 11 4 0.6 - 0.8 Total Observed 1237 0.21005264
#> 12 5 0.8 - 1 Total Observed 2223 0.37748344
#> 13 0 Nil Sample Expected 8 0.01666667
#> 14 1 0 - 0.2 Sample Expected 58 0.12083333
#> 15 2 0.2 - 0.4 Sample Expected 76 0.15833333
#> 16 3 0.4 - 0.6 Sample Expected 81 0.16875000
#> 17 4 0.6 - 0.8 Sample Expected 87 0.18125000
#> 18 5 0.8 - 1 Sample Expected 170 0.35416667
#> 19 0 Nil Sample Observed 1 0.03448276
#> 20 1 0 - 0.2 Sample Observed 2 0.06896552
#> 21 2 0.2 - 0.4 Sample Observed 5 0.17241379
#> 22 3 0.4 - 0.6 Sample Observed 4 0.13793103
#> 23 4 0.6 - 0.8 Sample Observed 8 0.27586207
#> 24 5 0.8 - 1 Sample Observed 9 0.31034483