The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.

Polygons with holes for ggplot2

Michael D. Sumner

2023-09-25

library(ggpolypath)
## Loading required package: ggplot2
ggplot(maphome) + aes(x = x_, y = y_, group = branch_, fill = object_) +
  geom_polypath()

The same example, but using the linked per-object metadata.

ggplot(merge(maphome, dathome[, c("object_", "name")])) + 
  aes(x = x_, y = y_, group = branch_, fill = name) + 
  geom_polypath()

Something more map.

gs <- ggplot(gardenstate)
gs <- gs + aes(x = x, y = y, group = group, fill = id)
gs +  geom_polypath() + geom_path() + coord_equal()

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.