[R] Multiple formula in one block

YiYao_Jiang YiYao_Jiang at smics.com
Mon Oct 25 09:16:34 CEST 2004


Hi Everybody:

I want to draw some chart using command "histogram" and add another curve in it.
Example:

require(stats)
data(singer)
library(lattice)
histogram( ~ height | voice.part, data = singer, nint = 17,  endpoints = c(59.5, 76.5), layout = c(2,4), aspect = .5,  xlab = "Height (inches)")

Now I got a chart of 8 blocks, then I need add :" abline(v=mean(singer$height), col=2, lwd=2) " or any other curve to every block.
How can I do to achieve it. Thanks.
 

Best Regards

YiYao Jiang  

Product Division/ product Testing Department
Semiconductor Manufacturing International Corporation
18 ZhangJiang Road, PuDong New Area, Shanghai  ZIP: 201203
Tel:86-21-5080-2000 Ext. 15173




More information about the R-help mailing list