Re: [R] figs parameter for split.screen()

From: Prof Brian Ripley <ripley_at_stats.ox.ac.uk>
Date: Wed 15 Feb 2006 - 08:13:39 EST

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@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@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

______________________________________________
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 Feb 15 08:17:56 2006

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