KDE#

Note

Kernel density estimation converts point or line data into continuous density surfaces on a raster grid.

kde accepts either raw x, y arrays or a GeoDataFrame of Point geometries (column selects per-point weights). It is also available on the .xrs accessor, where the caller raster supplies the output grid and CRS:

grid.xrs.kde(points_gdf, coregister=True)

coregister=True reprojects the points from their CRS into the caller’s CRS first.

KDE#

xrspatial.kde.kde(x[, y, weights, ...])

Compute 2-D kernel density estimation from point data.

Line Density#

xrspatial.kde.line_density(x1, y1, x2, y2, *)

Compute line density from line-segment data.