ps_sfcs_centroid | R Documentation |
Centroid can be found for multiple sfc columns and any geometry type. For polygon and linestring data, centroid is calculated from vertices. Sfc columns must have same crs and should not be longitude/latitude.
ps_sfcs_centroid(x, sfc_names = ps_sfc_names(x), union = TRUE)
x |
The object |
sfc_names |
A character vector of the sfc column names |
union |
A flag indicating whether to use st_union() (the default) versus st_combine() prior to st_centroid() |
Sf object of centroid
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.