voronoi.Rd
Compute a voronoi tesselation of a map for a set of points.
voronoi(x, ext, eps = 1e-09)
sf POINTS or two-column matrix or data.frame with x and y coordinates.
Extent object.
Numerical tolerance used in triangulation. See deldir
.
sf POLYGON object.
pts <- data.frame(x = c(1:2, 2), y = c(1, 1:2))
region <- terra::ext(c(0, 3, 0, 3))
plot(sf::st_geometry(voronoi(pts, region)))
points(pts)