Try this; DF <- as.data.frame(matrix(rnorm(60), 10)) boxplot(DF, col = rep(seq(ncol(DF)) + 1, each = 2))
On Tue, Oct 13, 2009 at 2:11 AM, kennyPA <tao...@yahoo.com> wrote: > > Can anybody help me on how to boxplot multiple groups with different color? > Say, I have 3 groups of data, each group with 2 boxes, and I'd like to have > the following layout in the boxplot: > > red, red, green, green, blue, blue > > thanks in advance. > -- > View this message in context: > http://www.nabble.com/multiple-groups-with-different-colors-in-boxplot-tp25867267p25867267.html > Sent from the R help mailing list archive at Nabble.com. > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > -- Henrique Dallazuanna Curitiba-Paraná-Brasil 25° 25' 40" S 49° 16' 22" O ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.