points_to_convexhull: Compute the convex hull of a set of points

View source: R/geometry.R

points_to_convexhullR Documentation

Compute the convex hull of a set of points

Description

Compute the convex hull of a set of points

Usage

points_to_convexhull(x)

Arguments

x

sf object with geometry of type POINT

Value

sf POLYGON table

See Also

stackoverflow

Examples

## Not run: 
pts <- sf::read_sf(system.file("datasets/penbay-points.gpkg", package = 'twinkle'))
ch <- points_to_mesh(pts)
sst <- stars::read_stars(system.file("datasets/20140601-20140630-sst.tif", package = "twinkle"))
plot(sst[,,,1],
     main = "sst 2014-01-01",
     reset = FALSE,
     add.geom = list(sf::st_geometry(pts), col = 'blue', pch = 19))
plot(sf::st_geometry(ch), add = TRUE, border = 'orange', lwd = 2, col = NA)

## End(Not run)

BigelowLab/twinkle documentation built on Jan. 26, 2025, 6:34 a.m.