Re: [R] ggplot - boxplot and points split by two factors

2014-09-08 Thread Federico Lasa
Use geom_jitter() instead of geom_point On Mon, Sep 8, 2014 at 12:37 PM, Tom Wright wrote: > ggplot(data,aes(x = z1, y = x, fill=x2)) + > geom_boxplot() + > geom_point(alpha=0.5, > position=position_jitterdodge(jitter.width=0.1), > aes(group=x2)) > > On Mon, 2014-09-08 at 13:1

Re: [R] ggplot - boxplot and points split by two factors

2014-09-08 Thread Tom Wright
ggplot(data,aes(x = z1, y = x, fill=x2)) + geom_boxplot() + geom_point(alpha=0.5, position=position_jitterdodge(jitter.width=0.1), aes(group=x2)) On Mon, 2014-09-08 at 13:10 -0400, Tom Wright wrote: > Hi, > I'm trying to create a boxplot overlayed with points where the data is

[R] ggplot - boxplot and points split by two factors

2014-09-08 Thread Tom Wright
Hi, I'm trying to create a boxplot overlayed with points where the data is split by two factor groups. So far: x1<-factor(rep(LETTERS[1:4],5)) x2<-factor(rep(letters[1:2],10)) z<-runif(20,0,10) data<-data.frame(x1=x1,x2=x2,z=z) ggplot(data,aes(x=x1,y=z,fill=x2)) + geom_boxplot() +

Re: [R] How to drop unused factors in faceted R ggplot boxplot?

2013-01-24 Thread arun
-- From: Niec To: r-help@r-project.org Cc: Sent: Thursday, January 24, 2013 1:13 PM Subject: Re: [R] How to drop unused factors in faceted R ggplot boxplot? Thank you, Jeff. I think I should have been more clear.  I don't want to modify my data. I need to create a series of box plots for dif

Re: [R] How to drop unused factors in faceted R ggplot boxplot?

2013-01-24 Thread Gorczynski, George
Subject: Re: [R] How to drop unused factors in faceted R ggplot boxplot? HI, You can get the plot in the same window, but the width seems to be a problem. stest<- read.table(text="     site year conc     south 2001 5.3     south 2001 4.67     south 2001 4.98     south 2002 5.76     south 2

Re: [R] How to drop unused factors in faceted R ggplot boxplot?

2013-01-24 Thread Niec
ngs of my posted data sample. I'll be better prepared next time. -- View this message in context: http://r.789695.n4.nabble.com/How-to-drop-unused-factors-in-faceted-R-ggplot-boxplot-tp4656480p4656535.html Sent from the R help mailing list archive at Nabble.com. ___

Re: [R] How to drop unused factors in faceted R ggplot boxplot?

2013-01-23 Thread Jeff Newmiller
rth 200639.17 >north 200643.51 >north 200676.21 >north 2006158.89 >north 2006122.27 > ><http://r.789695.n4.nabble.com/file/n4656480/2013-01-23_2130.png> > > > > > >-- >View thi

[R] How to drop unused factors in faceted R ggplot boxplot?

2013-01-23 Thread Niec
43.51 north 200676.21 north 2006158.89 north 2006122.27 <http://r.789695.n4.nabble.com/file/n4656480/2013-01-23_2130.png> -- View this message in context: http://r.789695.n4.nabble.com/How-to-drop-unused-factors-in-faceted-R-ggplot-boxplot-tp4

Re: [R] ggplot boxplot

2011-01-20 Thread Dennis Murphy
Hi: See inline, please. On Thu, Jan 20, 2011 at 4:22 PM, Nathan Miller wrote: > Hello, > > I am trying to generate a set of boxplots using ggplot with the following > data with 4 columns (Day, Site, VO2, Cruise) > > AllCorbulaMR >Day Site VO2 Cruise > 1 11 148.43632670

[R] ggplot boxplot

2011-01-20 Thread Nathan Miller
Hello, I am trying to generate a set of boxplots using ggplot with the following data with 4 columns (Day, Site, VO2, Cruise) AllCorbulaMR Day Site VO2 Cruise 1 11 148.43632670 1 2 11 61.73864969 1 3 11 92.64536096 1 4 11 73.35434957

Re: [R] ggplot boxplot - how to order categories

2008-08-25 Thread Raj Minhas
Hadley, Many thanks - I have just started using ggplot and it is an amazing package. -Raj. -- View this message in context: http://www.nabble.com/ggplot-boxplot---how-to-order-categories-tp19147920p19148953.html Sent from the R help mailing list archive at Nabble.com. ___

Re: [R] ggplot boxplot - how to order categories

2008-08-25 Thread hadley wickham
Hi Raj, It's the same as the other plotting systems in R: you need to change the order of the underlying factor levels. e.g.: levels(diamonds$color) <- c("J", "D", "E", "I", "H", "F", "G") If you're reordering then according to the value of another variable, also see ?reorder Hadley On Mon, A

[R] ggplot boxplot - how to order categories

2008-08-25 Thread Raj Minhas
I am interested in creating a boxplot using ggplot or qplot where I can specify the order of the categories being plotted on the x-axis. For example, the following command plots the categories (diamond color) in alphabetic order (D, E, ..., J): qplot(color, price/carat, data=diamonds, geom="boxpl