Use a judicious combination of par(mai) and par(new = TRUE). For example:

par(mai = c(3,1,1,1))
x <- runif(50)
plot(x, xlim = c(1, 500), ylim = c( -5, 1), bty = "l")

par(mai = c(2,1.5,2,1))
par(new = TRUE)
x <- runif(50)
plot(x, xlim = c(1, 500), ylim = c( -5, 1), bty = "l")

par(mai = c(1,2,3,1))
par(new = TRUE)
x <- runif(50)
plot(x, xlim = c(1, 500), ylim = c( -5, 1), bty = "l")

Does that help?

Partha






"Carlisle Thacker" <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]
11/01/2004 04:09 PM

 
        To:     [EMAIL PROTECTED]
        cc: 
        Subject:        [R] overlapping plots


How to combine three plots so that they partially overlap?  As the data
on all three are near the left side and top, it would be nice to draw
the first, shift axes down and to the right and draw the second, and
shift again to draw the third.

I could shift the data for the 2nd and 3rd plots and construct their
axes by hand, but it would be great if R has an easier way.

______________________________________________
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

______________________________________________
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to