[R] How to put multiple plots in the same window? (not par(mfrow=))

Thomas Lumley tlumley at u.washington.edu
Fri Jul 30 17:49:07 CEST 2004


On Fri, 30 Jul 2004, F Duan wrote:

> Dear All,
>
> I am sorry if this question has been asked before. Below is my Question:
>
> I want to put several plots in the same window, but I don’t want the blank
> space between plots (like par(mfrow=)) --- that makes the plots too small.
> Could anyone tell me how to do it?
>

There isn't blank space between the plots. There is blank space around
each plot. The amount of space around each plot is controlled by par(mar),
which specifies the number of lines of space on each side of the plotting
area

The default is
> par("mar")
[1] 5.1 4.1 4.1 2.1
and if you do, say,
  par(mar=c(3.1,3.1,1,1))
you will have much less blank space.  You need to make sure enough space
is left for axis label &c.

	-thomas




More information about the R-help mailing list