Re: [R] common title for graphs in a (1x2) layout

From: Michael H. Prager <Mike.Prager_at_noaa.gov>
Date: Thu 16 Feb 2006 - 04:54:56 EST

Something like this?

def.par <- par(no.readonly = TRUE)
nf <- layout(matrix(c(1,2), 1,2,byrow=T), c(1,1), c(1,1), T) plot(rnorm(10,0,1))
plot(rnorm(10,0,0.1))
mtext("Common Title", adj=-1.0, line=2)
par(def.par)

on 2/15/2006 11:22 AM Rodrigo Tsai said the following:
> Dear all,
>
> Many thanks for the help suggesting the use of "layout" cmd.
>
> How to insert a title in a 1x2 layout? The title is related to both graphs.
> I looked for it in help, unsuccessfully.
>
> Thanks in advance,
> Rodrigo.
>
> my reproductible code:
> ----------------------------------------------------------------------
>
> def.par <- par(no.readonly = TRUE)
>
> nf <- layout(matrix(c(1,2), 1,2,byrow=T), c(1,1), c(1,1), T)
>
> layout.show(nf)
>
>
>
> plot(rnorm(10,0,1))
>
> plot(rnorm(10,0,0.1))
>
> par(def.par)
>
> ----------------------------------------------------------------------
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> 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
>

-- 

Michael Prager, Ph.D.
Population Dynamics Team, NMFS SE Fisheries Science Center
NOAA Center for Coastal Fisheries and Habitat Research
Beaufort, North Carolina  28516
http://shrimp.ccfhrb.noaa.gov/~mprager/
Opinions expressed are personal, not official.  No
government endorsement of any product is made or implied.

______________________________________________
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 Thu Feb 16 04:58:08 2006

This archive was generated by hypermail 2.1.8 : Thu 16 Feb 2006 - 16:32:21 EST