[R] problem with multiple plots (mfrow, mar)
Peter Neuhaus
pneuhaus at pneuhaus.de
Fri Feb 19 14:07:07 CET 2010
Jim Lemon wrote:
> Hi Peter,
> The two par arguments "fin" and "pin" allow a solution. What you want is
> for the second values in "pin" (Plot dimensions in INches) to be the
> same for all your plots. You can get an approximation by using the
> layout function instead of mfrow and setting the height vector to
> correct for the space used in the top and bottom plots. If you are not
> doing lots of these plots or you are doing only a few variations, you
> can just print out par("pin") after each plot and see how much they
> differ and adjust the height vector until all "pin"s are the same. Try
> setting the height vector in layout to the "fin"s (Figure dimensions in
> INches) that are printed out using the default of all heights equal.
Thanks, Jim. I'll try and see which solution works best for me. I often
use layout() for more complicated and print-quality plots, where "fin"
and "pin" will come in handy.
It's just amazing how much I still don't know after one year of daily
R-programming...
More information about the R-help
mailing list