Re: [R] Legend for 2 plots on same screen

2011-08-01 Thread Jim Lemon
On 08/01/2011 04:52 AM, Cheryl Johnson wrote: Hello, I have two plots on the same screen. I use the command par(mfrow=c(1,2)) in order to do this. When I try to make a legend for both plots, it only puts the legend in the plot on the right side. If I would like a legend that is outside of both o

Re: [R] Legend for 2 plots on same screen

2011-07-31 Thread Daisy Englert Duursma
You could make three plots. The first two you plot in and the third one you place the legend in. nf<-layout(matrix(c(1,2,3), 1, 3, byrow = TRUE), c(6,6,3), c(6)) layout.show(nf) plot(sin, -pi, 2*pi, col = "blue2") plot(sin, -pi, 2*pi, col = "darkorange3") plot(1, xlim=c(1,2), ylim=c(1,2), type=

[R] Legend for 2 plots on same screen

2011-07-31 Thread Cheryl Johnson
Hello, I have two plots on the same screen. I use the command par(mfrow=c(1,2)) in order to do this. When I try to make a legend for both plots, it only puts the legend in the plot on the right side. If I would like a legend that is outside of both of the plots, how would I do this? Thanks