[R] Combine colors and shading lines

From: Josh Roofchop <josh_at_roofchop.com>
Date: Fri, 20 Jun 2008 09:55:07 -0700 (PDT)

Hi, basically I am trying to create a grouped bar graph with each group a different color and a bar in each group to have shading lines. Basically combine the 2 graphs created below.
Thanks,
Josh

data(HairEyeColor)
a <- as.table( apply(HairEyeColor, c(1,2), sum) ) a1<-a[1:2,]

par(mfcol=c(1,2), bg="white")

barplot(a1,

	type="n",
	col=c(2,2,4,4,6,6,3,3),
        beside = TRUE, )

barplot(a1,
col=1,
density=c(0,7,0,7,0,7,0,7),

        beside = TRUE, )

http://www.nabble.com/file/p18033630/graph.JPG graph.JPG

-- 
View this message in context: http://www.nabble.com/Combine-colors-and-shading-lines-tp18033630p18033630.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help_at_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.
Received on Sat 21 Jun 2008 - 05:09:46 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Sat 21 Jun 2008 - 12:30:57 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive