Description Usage See Also Examples
Polygon, a filled path.
1 | geom_polygon(aesthetics = list())
|
geom_path
: an unfilled polygon
geom_ribbon
: a polygon anchored on the
x-axis
1 2 3 4 5 6 7 8 9 | if (require(maps)) {
ni <- data.frame(map("nz", "North.Island", plot = F)[c("x", "y")])
si <- data.frame(map("nz", "South.Island", plot = F)[c("x", "y")])
geom_plot(geom_polygon(), ni)
geom_plot(geom_polygon(list(colour = "grey50", fill = NA)), si)
nz <- rbind(data.frame(ni, group = 1), data.frame(si, group = 2))
geom_plot(geom_polygon(), nz)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.