I am new to ggplot2 and cannot figure out how to draw vertical dotted grey lines between
ggplot2
the points/dots along the x-axis. Here\'s my example code:
If your actual data is structured like the one used for your example, just add geom_line(aes(group = d3)) to the plot.
geom_line(aes(group = d3))
ggplot(df, aes(x=x, y=y)) + geom_point() + geom_line(aes(group = d3))