R-beta: Switching between plots without erasing them.

Martin Maechler maechler at stat.math.ethz.ch
Mon Jun 30 17:17:31 CEST 1997

>>>>> "Richard" == Richard Lammers <lammers at edac.sr.unh.edu> writes:

    Richard> I have a question relating to switching between plots within
    Richard> the graphics window [x11()].  If this is not appropriate for
    Richard> this mailing list then please let me know.

Your question was not at all inappropriate for the mailing list.

It's a very good question,
and I don't know an answer.

My guess (after not too extensive amounts of thinking):
	It's not possible currently.

    Richard> What I am doing now:

    Richard> Opening a graphics window and setting two plot regions [ie
    Richard> with par(mfrow=c(2,1))].  In the top section there is a plot
    Richard> with a set of points which represent river gauges located by
    Richard> latitude and longitude pairs. These points are global in
    Richard> extent so I am also using continent boundaries from a data set
    Richard> found on Statlib.  Because there are so many points this takes
    Richard> some time to draw.  Using the identify() function a point is
    Richard> selected and in the lower plot a time series is displayed from
    Richard> that particular river gauge.  This is in a loop which allows
    Richard> repeated clicks on the map and time series plots.  Each time
    Richard> through the loop, the map must be redrawn.

    Richard> I would like to do the following:

    Richard> I would like to keep the upper plot (the map) intact while
    Richard> being able to completely redraw the lower plot (the time
    Richard> series).  Is there some way I can return to the upper plot and
    Richard> invoke the identify function without erasing the map? The
    Richard> function frame() erases the plot.  I suppose the alternative
    Richard> would be to have two independent graphics windows, but I am
    Richard> not sure if that is possible within R.

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