ggfx
ggfx copied to clipboard
with_outer_glow() - Negative values not shown
Labels with negative values passed to with_outer_glow, seem to lose their "-" sign.
See following example...
example contour plots
library(ggplot2) library(geomtextpath) library(ggfx) df <- expand.grid(x = seq(nrow(volcano)), y = seq(ncol(volcano))) df$z <- as.vector(volcano)-150 #make some values negative
this works - shows negative numbers
ggplot(df, aes(x, y, z = z)) + geom_contour_filled(bins = 6, alpha = 0.6) + geom_textcontour(bins = 6, size = 3, linetype = NA)
this doesn't work - negative numbers not shown
ggplot(df, aes(x, y, z = z)) + geom_contour_filled(bins = 6, alpha = 0.6) + with_outer_glow( geom_textcontour(aes(z = z), linetype = NA, size = 3), colour = 'white', expand = 5, sigma = 1 )
Not a problem here. Are you using the latest development version of ggfx or the CRAN version?