exactextractr quickly and accurately summarizes raster values over polygonal areas, commonly referred to as zonal statistics. It provides the following functions:

  • exact_extract generates a data frame of grid cell values and the fraction of the cell's area that is covered by a polygon. It can also compute statistics on these values without returning them directly.

  • coverage_fraction generates a raster whose values represent the fraction of each grid cell (0-1) covered by a polygon.