[R] Display more than one plot

joris meys jorismeys at gmail.com
Sun Oct 11 00:50:20 CEST 2009


Hi Emkay,

If you want to look at different plots together, you can also plot
them side by side in the same plot window.

You can specify this using for example:
        par(mfcol=c(2,2))
( see ?par and check mfrow and mfcol)
or
        layout(matrix(1:4,2,2))
(see ?layout and ?matrix)

eg :
x <- c(1,2,3,4,5,6,7,8,9,0)
y <- c(1,2,3,4,5,6,7,8,9,0)
z <- c(8,7,6,5,4,3,2,1,0,9)

par(mfcol=c(2,2))
plot(x,y)
plot(x,z)

Kind regards
Joris

On Sat, Oct 10, 2009 at 4:51 AM, emkayenne
<michaelkristoffernagl at gmail.com> wrote:
>
> Nobody? :-(
>
> emkayenne wrote:
>>
>> Hello, I'm pretty new to R and I am having a hrd time getting a grip. Just
>> a question: can someone tell me how to have more than one graphics windown
>> open at the same time? I want to look at some plote at the same time...,
>> how is this done? If someone has a suggestion for a (good) introductory
>> guide to R, much appreciated, but not the manual..., this one I do have.
>> :confused:
>> Thank you for your help guys, Emkay
>>
>
> --
> View this message in context: http://www.nabble.com/Display-more-than-one-plot-tp25829214p25830526.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help at r-project.org 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.
>




More information about the R-help mailing list