Skip to content

Instantly share code, notes, and snippets.

@gshotwell
Created February 3, 2016 17:14
Show Gist options
  • Save gshotwell/e17adcb97c4ee3747383 to your computer and use it in GitHub Desktop.
Save gshotwell/e17adcb97c4ee3747383 to your computer and use it in GitHub Desktop.
ggplot dotplot binned along x and stacked along the y.
library(dplyr)
library(ggplot2)
df <- mtcars %>%
group_by(cyl) %>%
mutate(n = 1: n())
ggplot(df, aes(x = cyl, y = n)) + geom_point()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment