create_centroids {sugarbag} | R Documentation |
Create a data frame of longitude and latitude centroids of each polygon.
Description
Create a data frame of longitude and latitude centroids of each polygon.
Usage
create_centroids(shp_sf, sf_id, largest = TRUE, verbose = FALSE)
Arguments
shp_sf |
an sf object, a data set with a simple feature list column |
sf_id |
a string to indicate the column to identify individual polygons |
largest |
logical; for |
verbose |
a boolean to indicate whether to show function progress |
Value
a tibble containing longitude and latitude
Examples
centroids <- create_centroids(tas_lga, "lga_code_2016")
[Package sugarbag version 0.1.6 Index]