I'd like to have a dot plot that shows the count on the x-axis. How can you get the dotplot below to show the count on the x-asix?
Thank you.
date = seq(as.Date("2016/1/5"), as.Date("2016/1/11"), "day")
value = c(11,11,12,12,13,14,14)
dat =data.frame(date = date, value = value)
dat
library(ggplot2)
library(ggplot2)
ggplot(dat, aes(x = value)) + geom_dotplot(binwidth = .8) +
scale_y_discrete(breaks= seq(1,max(table(dat$value))+2,1),
labels = seq(1,max(table(dat$value))+2,1) ) #tried using scale_y discrete but it does nothing