Closed itcarroll closed 6 years ago
Hi!
Probably in issue in ggplot2
, size
dont seems to handle missing values, if you remove it, it works :
library(ggplot2)
data('meuse', package = "sp")
df <- sf::st_as_sf(meuse, coords = c('x', 'y'), crs = 28992)
# one missing value : error
ggplot(data = df) +
aes(size = landuse) +
geom_sf() +
theme_minimal()
# remove missing value : works
df <- df[!is.na(df$landuse), ]
ggplot(data = df) +
aes(size = landuse) +
geom_sf() +
theme_minimal()
I took the opportunity to add a better management of warnings and errors, now it looks like this:
Nice! Maybe I'll poke the tidyverse ...
Worked awesome with the meuse dataset's landuse variable set to "Color", but borked on setting the same to "Size".
esquisser version: 9340e358af76f6f44307d4501ce2659fd34eec6f