R/projection-units.r
Get projection units of an sf object
projection_units(x)
x | an sf object |
---|
A units object with the units of the projection.
pts <- sf::st_sfc(sf::st_point(c(0, 0)), sf::st_point(c(1, 1))) pts_df <- sf::st_sf(a = 1:2, geom = pts) sf::st_crs(pts_df) = "+proj=aea" projection_units(pts_df)#> 1 m