Incidence by preferred term and treatment arm (or severity grade), shaded by rate and annotated with counts.
geom_ae_heatmap(mapping = NULL, data = NULL, label = TRUE, label_size = NULL)A Layer to add with +.
d <- expand.grid(arm = c("Placebo", "Low", "High"),
ae = c("Nausea", "Fatigue", "Headache"))
d$pct <- c(5, 12, 22, 8, 15, 26, 3, 6, 11)
ggnext(d, aes(arm, ae, size = pct)) + geom_ae_heatmap()
#> <ggnext plot>
#> data: 9 x 3
#> aes: x = arm, y = ae, size = pct
#> layers: 1
#> coord: cartesian
#> mode: static