[R] Centered overall title with layout()
Stephen D. Weigand
weigand.stephen at charter.net
Wed May 18 03:25:00 CEST 2005
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
More information about the R-help
mailing list