Unary
Unary transformers
Transformations work on a per-geometry basis. Return for each geometry a new geometry.
transformer | returns a geometry … |
---|---|
centroid |
of type POINT with the geometry’s centroid |
buffer |
that is larger (or smaller) than the input geometry, depending on the buffer size |
jitter |
that was moved in space a certain amount, using a bivariate uniform distribution |
wrap_dateline |
cut into pieces that no longer cover or cross the dateline |
boundary |
with the boundary of the input geometry |
convex_hull |
that forms the convex hull of the input geometry ((fig-vor?)) |
line_merge |
after merging connecting LINESTRING elements of a MULTILINESTRING into longer LINESTRING s. |
make_valid |
that is valid |
node |
with added nodes to linear geometries at intersections without a node; only works on individual linear geometries |
point_on_surface |
with a (arbitrary) point on a surface |
polygonize |
of type polygon, created from lines that form a closed ring |
segmentize |
a (linear) geometry with nodes at a given density or minimal distance |
simplify |
simplified by removing vertices/nodes (lines or polygons) |
split |
that has been split with a splitting linestring |
transform |
transformed or convert to a new coordinate reference system ((sec-cs?)) |
triangulate |
with Delauney triangulated polygon(s) ((fig-vor?)) |
voronoi |
with the Voronoi tessellation of an input geometry ((fig-vor?)) |
zm |
with removed or added Z and/or M coordinates |
collection_extract |
with sub-geometries from a GEOMETRYCOLLECTION of a particular type |
cast |
that is converted to another type |
+ |
that is shifted over a given vector |
* |
that is multiplied by a scalar or matrix |
par(mar = rep(0,4), mfrow = c(1, 3))
set.seed(133331)
mp <- st_multipoint(matrix(runif(20), 10))
plot(mp, cex = 2)
plot(st_convex_hull(mp), add = TRUE, col = NA, border = 'red')
box()
plot(mp, cex = 2)
plot(st_voronoi(mp), add = TRUE, col = NA, border = 'red')
box()
plot(mp, cex = 2)
plot(st_triangulate(mp), add = TRUE, col = NA, border = 'darkgreen')
box()