[R] Options for zooming plots other than zm()

Abby Spurdle @purd|e@@ @end|ng |rom gm@||@com
Sun Apr 26 03:06:58 CEST 2020


> I am making some plots with plot() which have a fair number of points
> (thousands) and I would like to be able to interactively select a
> region of the plot and zoom in on it.

This doesn't answer your question, but I was wondering why having
thousands of data points is problematic?

Sometimes overplotting of points can make plots difficult to interpret.
(This is probably the most common problem plotting large datasets).

Taking this problem (overplotting) in generality, zooming doesn't
necessarily fix the problem, and even if it does there's a risk of
creating other problems.
Simple solutions include using semitransparent points, plotting a
(smaller) sample, or (in a limited range of situations) using
"jitter".
More sophisticated solutions include plotting binned data or plotting
bivariate kernel density estimates.
It's also possible combine approaches, say plot points on top of a
heatmap representing bivariate kernel density estimates.

If the goal is to inspect specific points, say with individual labels,
or plot high density deterministic data, then may be zooming could be
of some value.



More information about the R-help mailing list