Re: [R] Centered overall title with layout()

From: Stephen D. Weigand <weigand.stephen_at_charter.net>
Date: Wed 18 May 2005 - 11:25:00 EST

Dear Pierre,

On May 15, 2005, at 6:36 PM, Lapointe, Pierre wrote:

> Hello,
>
> I would like to have a centered overall title for a graphics page
> using the
> layout() function.
>
> Example, using this function:
>
> z <- layout(matrix(c(1:6), 3,2, byrow = TRUE))
> layout.show(6)
>
> I'd like to get this:
>
>
> Centered Overall Title
> --------------------------------
> | | |
> | | |
> | | |
> | | |
> | | |
> --------------------------------
> | | |
> | | |
> | | |
> | | |
> | | |
> --------------------------------
> | | |
> | | |
> | | |
> | | |
> | | |
> --------------------------------
>
> I really want to use layout(), not par(mfrow())
>
> Thanks
>
>
> Pierre Lapointe

Does mtext give you what you want? E.g.,

par(oma = c(0, 0, 3, 0))
z <- layout(matrix(c(1:6), 3,2, byrow = TRUE))
layout.show(6)

mtext("Centered Overall Title", side = 3, line = 1, outer = TRUE)

Hope this helps,
Stephen



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Wed May 18 11:33:27 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:31:50 EST