Closed
Description
In ggplot2
3.5.1 the fill guide for a factor where not all level sare present but drop=FALSE
is used shows the label for the missing level but not the color. A simple example:
library(ggplot2)
d <-data.frame(x = factor(1:3, levels = 1:4), y = 1:3)
ggplot(d, aes(x, y, fill = x)) +
geom_col() +
scale_fill_discrete(drop = FALSE)
This was different in the version available a year ago. Compare
this from 2024 to this from 2023.