[R] Axis label spanning multiple plots

Greg Snow Greg.Snow at imail.org
Wed May 27 21:38:35 CEST 2009


Create an outer margin (see ?par), then use mtext to put the title in the outer margin.

-- 
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.snow at imail.org
801.408.8111


> -----Original Message-----
> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
> project.org] On Behalf Of Andre Nathan
> Sent: Wednesday, May 27, 2009 1:40 PM
> To: r-help at r-project.org
> Subject: [R] Axis label spanning multiple plots
> 
> Hello
> 
> I need to plot 3 graphs in a single column; the top two plots have the
> same title, and I would like it to be written only once, centered
> horizontally and spanning the two plots. Something like
> 
> 
>   t +------------+
>     |            |
>   i |            |
>     |            |
>   t +------------+
> 
>   l +------------+
>     |            |
>   e |            |
>     |            |
>   1 +------------+
> 
>   t +------------+
>   i |            |
>   t |            |
>   l |            |
>   e |            |
>   2 +------------+
> 
>        x-title
> 
> Is there a parameter which allows me to do that automatically, or
> should
> I use text() and position the title manually?
> 
> Thanks in advance,
> Andre
> 
> ______________________________________________
> 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