[R] HOW to resize existing graphics window??

ripley@stats.ox.ac.uk ripley at stats.ox.ac.uk
Mon Oct 14 12:34:40 CEST 2002


You can do what you want by re-drawing the plot at the size you want on a
new device.  Copying plots is approximate at best, and I would not
recommend it for precise work.  Just rerun the R commands to generate the
plot.

On Mon, 14 Oct 2002, [koi8-r] ........ wrote:

> <<There is no way to resize an existing graphics window from the command
> <<ine on any of the R graphics platforms, and no one has ever asked for
> <<this before.
> I found in mailing list archives article, that describes how to resize
> X11 graphical window on *nix through *nix command-line interface from R.:)
> We can not say that "no one" asked for it:)

> <<Why do you want to do it?
> I want to do it cause i need to preserve size of plot when i copy it to the
> other program or when i save it to file. I mean, that, for some reasons, i
> dont want to resize plot after i have copied it or after i've save it to
> file.
> I need to adjust plot size 'on the fly' and _before_ i export it.
>
> When i copy a plot i think it copies in sizes of device size, am i right?
> Or which object (or which region) i really copying when i copying the plot?
> Is it 'figure region'? Or
> it is 'display region' of the device? or 'plot region'? I just have not find
> a way, that i can
> setup overall size of region, which copies when i trying to copy a plot. And
> for this
> reason i have thought, that only way to resize region, that actually copies,
> is to resize
> device.

Copying a plot replays the display list on a new device.  So it is the
device region.

> Now i do resizing in such manner:
> i open new device with size, that i need and copying the plot to this device
> and closing
> 'old' device. Or i do it through R recordPlot - replayPlot capabilities.
>
> Thanks for your help and sorry for my english not very well.

--
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 272860 (secr)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595


-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list