A closed shape is a shape with the same first and last coordinates.

coo_close(x, from_col, to_col, ...)

coo_unclose(x, from_col, to_col, ...)

is_closed(x)

is_unclosed(x)

Arguments

x

coo_single, coo_list or mom_tbl

from_col

colnames from where to get the coo_list and how to name the resulting one (only for mom_tbl method)

to_col

colnames from where to get the coo_list and how to name the resulting one (only for mom_tbl method)

...

useless here

Value

a coo_single, coo_list or mom_tbl

Functions

  • coo_unclose: Unclose shapes

  • is_closed: Tests if a coo_single (only) is closed

  • is_unclosed: Tests if a coo_single (only) is unclosed

Examples

bot %>% pick(1) # todo
#> # A tibble: 138 x 2 #> x y #> <dbl> <dbl> #> 1 37 561 #> 2 40 540 #> 3 40 529 #> 4 43 508 #> 5 46 487 #> 6 48 477 #> 7 52 456 #> 8 54 435 #> 9 57 414 #> 10 59 403 #> # … with 128 more rows #> ❯coo_single with 138 coordinates