Example of stat_summary_hex using alpha aesthetic mapping?
I'm plotting customer churn using the stat_summary_hex function.
stat_summary_hex(aes(x = Lon, y = Lat, z = Churn), bins=100, colour = NA,
geom = "hex", fun = function(x) sum(x))
ScaleFill <- scale_fill_gradient2(low = "blue", high = "orange", na.value
= NA)
Ideally, I would be able to set the alpha scale such that summary values
close to 0 would have an alpha of 0. However, to my beginner's eyes, it
looks like stat_summary_hex does not acknowledge an alpha aesthetic.
Does someone have an example of stat_summary_hex with alpha mapping?
No comments:
Post a Comment