Re: [R] Combining boxplot

2013-02-25 Thread soon yi
does this work for you? df1 = data.frame(x = rnorm(100)) df1$type = ifelse(df1$x <= 0 , "type1", "type2") df1$group<-1 df2 = data.frame(x = rnorm(50,0,2)) df2$type = ifelse(df2$x <= 0 , "type1", "type2") df2$group<-2 combined.df<-rbind(df1,df2) boxplot(combined.df$x ~ combined.df$group *co

Re: [R] Combining boxplot

2013-02-25 Thread William Dunlap
ill Dunlap Spotfire, TIBCO Software wdunlap tibco.com > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On > Behalf > Of Philippe Massicotte > Sent: Monday, February 25, 2013 8:04 AM > To: r-help@r-project.org > Subject:

[R] Combining boxplot

2013-02-25 Thread Philippe Massicotte
Hi everyone. I have two data frames that contain the same variables but with different number of observation. I would like to know it was possible to combine the data so I can have "paired" boxplot on the same figure. For example, df1 = data.frame(x = rnorm(100)) df1$type = ifelse(df1$x