This started happening a few days ago, that scales::percent
would add a decimal place in its labels, and I can't seem to disable this decimal to display integer values on y-axis.
library(dplyr)
library(ggplot2)
mtcars %>%
count(cyl) %>%
mutate(prop = n / sum(n)) %>%
ggplot(aes(x = cyl, y = prop)) +
geom_point() +
scale_y_continuous(labels = scales::percent)