Convert polyclip polygon to JamPolygon

polyclip_to_JamPolygon(A, ...)

Arguments

A

output from polyclip functions.

Examples

df <- data.frame(name=c("polygon1", "polygon2"),
   x=I(list(
      list(c(1, 4, 4, 1),
         c(2, 3, 3, 2)),
      c(5, 6, 6, 5))),
   y=I(list(
      list(c(1, 1, 4, 4),
         c(2, 2, 3, 3)),
      c(1, 1, 2, 2))),
   fill=c("gold", "firebrick"))
jpdf <- new("JamPolygon", polygons=df);