How to make a Vertical Line Plot for counts

24 views
Skip to first unread message

Timothy Lau

unread,
Apr 8, 2016, 12:34:00 PM4/8/16
to ggplot2

I'm trying to recreate the plot below in ggplot2. Is this possible?


Brandon Hurr

unread,
Apr 8, 2016, 12:41:40 PM4/8/16
to Timothy Lau, ggplot2
Yes. 
something like:
geom_segment(aes(x=0, xend=count, y=TotalTest, yend=TotalTest))

Should work, but you'd need some data example for us to make sure. 

B

On Fri, Apr 8, 2016 at 9:33 AM, Timothy Lau <timoth...@gmail.com> wrote:

I'm trying to recreate the plot below in ggplot2. Is this possible?


--
--
You received this message because you are subscribed to the ggplot2 mailing list.
Please provide a reproducible example: https://github.com/hadley/devtools/wiki/Reproducibility
 
To post: email ggp...@googlegroups.com
To unsubscribe: email ggplot2+u...@googlegroups.com
More options: http://groups.google.com/group/ggplot2

---
You received this message because you are subscribed to the Google Groups "ggplot2" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ggplot2+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Timothy Lau

unread,
Apr 8, 2016, 12:45:53 PM4/8/16
to Brandon Hurr, ggplot2
​@Brandon Hurr, works like a charm, thanks!​




Best,
Timothy



"The will to win means nothing without the will to prepare."
Reply all
Reply to author
Forward
0 new messages