Replaces unreadable 4+ way Venn diagrams: a bar chart of intersection sizes above a dot matrix showing which sets each bar belongs to.
geom_upset(mapping = NULL, data = NULL, alpha = NULL, dot_size = NULL)A Layer to add with +.
d <- data.frame(sets = c("A", "A&B", "B", "A&B&C", "C", "A&B", "A"))
ggnext(d, aes(label = sets)) + geom_upset() + theme_void()
#> <ggnext plot>
#> data: 7 x 1
#> aes: label = sets
#> layers: 1
#> coord: cartesian
#> mode: static