image_draw_polygons | R Documentation |
Draw polygons on an image
image_draw_polygons(image, x, ...)
image |
|
x |
a list vector where each list element contains columns x and y indicating the positions of the polygon |
... |
further arguments passed on to |
a magick-image
library(magick) path <- system.file(package = "madoc.utils", "extdata", "pagexml-example.xml") x <- read_pagexml(path) x img <- system.file(package = "madoc.utils", "extdata", "pagexml-example.jpg") img <- image_read(img) plt <- image_draw_polygons(img, x$coords, col = "#FF000080", border = "blue", lwd = 2) plt
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.