del pes wrote:
> Hello,
> 
> I would like to draw vertical yellow bands in my graph, but could not find 
> how to do that in the documentation.
> 
> I set up a page to show what I would like to achieve: 
> http://rstudent.blogg.de/eintrag.php?id=1 (the first picture was manually 
> colored with the Gimp).
> 
Hi Delfina,
For a one-off, I would use the rect function.

fakedat<-0.985+rnorm(80)/100
plot(fakedat,main="My Striped Plot",type="n")
rect(seq(5,75,by=10),par("usr")[3],seq(10,80,by=10),par("usr")[4],
  col="yellow")
points(fakedat,type="b")
abline(h=0.98)

Jim

______________________________________________
R-help@stat.math.ethz.ch 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.

Reply via email to