[R] unexpected par('pin') behaviour

Martin Maechler maechler at stat.math.ethz.ch
Fri Jul 15 15:00:12 CEST 2005

>>>>> "MM" == Martin Maechler <maechler at stat.math.ethz.ch>
>>>>>     on Fri, 15 Jul 2005 14:36:16 +0200 writes:


    MM> which I can simplify to

    MM> graphics.off()
    MM> layout(matrix(1:42,7,6))
    MM> par("pin")

    MM> ## [1]  0.2918620 -0.2974408  --- when using x11() "default" 

    MM> clearly a bug in layout()  {which I'll file}

exploring more before filing a bug report,

I've now seen that this  *NO BUG*  of layout() 
but rather of the ``design bug'' of old-style graphics which
bites here.

    MM> and it seems to me, one that is not shared by
    MM> par(mfrow= / mfcol=) settings.

That's wrong, since

  ## [1]  1.0470855 -0.1047263

and when plot() you get message about margins being too wide.

Only after something like

  par(mar= rep(1,4))

you get both valid "pin" and can plot properly.

That's nothing new and not really astonishing,

Martin Maechler, ETH Zurich

More information about the R-help mailing list