An embedded and charset-unspecified text was scrubbed... Name: not available URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20130717/516f39e7/attachment.pl>
(no subject)
2 messages · labib obaid, Jim Lemon
On 07/17/2013 01:41 PM, labib obaid wrote:
hi I need to use boxplot for two subsets at the same page
Hi labib obaid,
Try this:
test.df<-data.frame(a=rnorm(80)+4,b=rnorm(80)+4,
c=rep(LETTERS[1:4],each=20),
d=rep(rep(letters[1:4],each=4),5))
boxplot(test.df$a[test.df$c %in% c("A","B")],
test.df$a[test.df$c %in% c("C","D")])
That should get you started.
Jim