billboarder
billboarder copied to clipboard
Scatterplot in which the grouping variable takes more than 4 different values does not work
Example from Documentation with grouping by cyl works. cyl takes three different values 4 6 and 8
billboarder(data = mtcars) %>%
bb_scatterplot(
mapping = aes(wt, mpg, group = cyl, size = scales::rescale(qsec, to = c(0.2, 7))),
point_opacity = 1
) %>%
bb_axis(x = list(tick = list(fit = FALSE))) %>%
bb_x_grid(show = TRUE) %>%
bb_y_grid(show = TRUE)
whereas grouping by carb does not work. carb takes six different values 1 2 3 4 6 and 8
billboarder(data = mtcars) %>%
bb_scatterplot(
mapping = aes(wt, mpg, group = carb, size = scales::rescale(qsec, to = c(0.2, 7))),
point_opacity = 1
) %>%
bb_axis(x = list(tick = list(fit = FALSE))) %>%
bb_x_grid(show = TRUE) %>%
bb_y_grid(show = TRUE)
Hello,
Thanks for reporting this. That's a bug due to groups of length one (carb == 6 or carb == 8).
That's fixed if you re-install from GitHub.
Victor
Thanks!!