You may want to look into st_wrap_dateline(), which cuts LINESTRING and
POLYGON geometries in multi-part equivalents where parts do not cross
the antimeridian.
As in:
seg2 <- st_segmentize(st_wrap_dateline(sf), units::set_units(1000, km))
On 29/12/2020 00:24, Amanda Rehbein wrote:
Dear
Dear Amanda,,
I think this unwanted, nearly horizontal segment is unavoidable if you
simply plot() the results and you use a CRS such as 4326. Of course, you
can st_transform() your sf object to e.g. Robinson or Miller projection
before st_segmentize()-ing.
But this segment is correct in