[R] figs parameter for split.screen()
Berton Gunter
gunter.berton at gene.com
Tue Feb 14 22:52:09 CET 2006
You may find that ?layout is an easier way to handle multiple plots on the
screen (I do), if you are not already aware of it.
-- Bert Gunter
Genentech Non-Clinical Statistics
South San Francisco, CA
"The business of the statistician is to catalyze the scientific learning
process." - George E. P. Box
> -----Original Message-----
> From: r-help-bounces at stat.math.ethz.ch
> [mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Rodrigo Tsai
> Sent: Tuesday, February 14, 2006 1:31 PM
> To: Prof Brian Ripley
> Cc: R-help at stat.math.ethz.ch
> Subject: Re: [R] figs parameter for split.screen()
>
> Dear Prof Brian Ripley,
>
> Many thanks for your help. Before trying to split.screen
> (1x2) I had set the
> "mar" parameter in par( ) in order to move each graph of another (2x1)
> splitted figure. This setting might have caused the problem.
> Now it works.
>
> Best regards,
> Rodrigo.
>
>
> On 2/14/06, Prof Brian Ripley <ripley at stats.ox.ac.uk> wrote:
> >
> > On Tue, 14 Feb 2006, Rodrigo Tsai wrote:
> >
> > > Dear all,
> > >
> > > I would be pleased if anyone could help me.
> > >
> > > The Rhelp description for the figs parameter is "a
> two-element vector
> > > describing
> > > the number of rows and colunns in a screen matrix".
> > >
> > > So, why does my code (below) produce a 2x1 screen matrix
> instead of
> > > a 1x2 one?
> >
> > Does it? There is no way we can reproduce it as it is
> incomplete, but
> >
> > split.screen(figs=c(1,2))
> > screen(1)
> > plot(1:2)
> > screen(2)
> > plot(10:1)
> >
> > does produce a 1x2 layout.
> >
> > Perhaps your error is call plot.new() in a subdivided
> layout: it makes no
> > sense to select a screen and then move to the next frame.
> >
> > >
> > > Thanks in advance,
> > > rodrigo.
> > >
> > > -----------------------------------------------------------
> > > plot.new()
> > >
> > > split.screen(figs=c(1,2))
> > >
> > >
> > >
> > > screen(1)
> > >
> > > plot.new()
> > >
> > > plot(v16[vd==0], vdep[vd==0], bg="aliceblue", cex= 0.5,
> > > xlab="Age",ylab="AvWei", main="", ylim=c(x1,xn), cex.lab=1.1)
> > >
> > > title(main = "Female", cex.main = 1.1 , font.main = 1, col.main =
> > "black")
> > >
> > >
> > >
> > > screen(2)
> > >
> > > plot.new()
> > >
> > > plot(v16[vd==1], vdep[vd==1], bg="aliceblue", cex= 0.5,
> > > xlab="Age",ylab="AvWei", main="", ylim=c(x1,xn), cex.lab=1.1)
> > >
> > > title(main = "Male", cex.main = 1.1 , font.main = 1,
> col.main = "black")
> > >
> > > *----------------------------------------------------------- *
> > >
> > > **
> > >
> > > [[alternative HTML version deleted]]
> > >
> > > ______________________________________________
> > > R-help at 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
> > >
> >
> > --
> > Brian D. Ripley, ripley at stats.ox.ac.uk
> > Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
> > University of Oxford, Tel: +44 1865 272861 (self)
> > 1 South Parks Road, +44 1865 272866 (PA)
> > Oxford OX1 3TG, UK Fax: +44 1865 272595
> >
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at 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
>
More information about the R-help
mailing list