[R] colors for background and plotting area

Peter Dalgaard BSA p.dalgaard at biostat.ku.dk
Sat Sep 2 11:56:22 CEST 2000

Ramon Diaz-Uriarte <ramon-diaz at teleline.es> writes:

> Dear all,
> I am trying to prepare some figures where I'd like the color of the plot region
> (i.e., the area bounded by the axes) to be different from the margin area
> (i.e., the area of the figure not within the axes region).  I can use "bg" but
> that changes the background of everything? How can I accomplish what I want?

I think one is stuck with things like


(or for the middle line, somewhat simpler

bb <- par("usr")
rect(bb[1],bb[3],bb[2],bb[4], col="pink")


   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk)             FAX: (+45) 35327907
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch

More information about the R-help mailing list