View source: R/check_ring_dir.R
check_ring_dir | R Documentation |
Polygon ring are seen from above: exterior ring counter clockwise, holes clockwise
check_ring_dir(polygons, check.only = TRUE)
polygons |
a sfc object which contains simple feature geometry of
types |
check.only |
a boolean which indicates if the function only
checks the ring direction ( |
Either a logical vector which indicates if line i of polygons
is in the right direction (TRUE
) or not or the corrected sfc object
data(usa)
all(check_ring_dir(sf::st_geometry(usa), check.only=TRUE))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.