[GRASS-stats] Scatterplot "thinning" (points reduction)?

Roger Bivand Roger.Bivand at nhh.no
Mon Aug 17 03:33:16 EDT 2009


On Sun, 16 Aug 2009, Markus Neteler wrote:

> Hi,
>
> I am plotting elevation against temperature and have the problem that
> including all points leads to heavy slow graphs... Reducing the raster
> resolution is not a solution since it does not maintain the characteristics
> of the graph (since GRASS is using nearest neighbor).

One point initially. I'm assuming that you are using a Linux platform - on 
this platform, there is an order of magnitude speedup if you plot on 
screen without "cairo", the default x11 type= - try using type="Xlib", 
which is much faster but not so refined.

Given that, consider the cex= argument for varying symbol size, and maybe 
the pch="." possibility for using a single pt. point. They still all get 
drawn, so there is no time saving, but they may be more visible.

For very large data sets, consider hexbin() in the hexbin package - I'm 
not sure how best to display three data sets. For single scatterplots, it 
is very powerful. Maybe contours of 2D densities of the extra data sets 
could be overlaid over a base hexbin plot? There is an informative 
vignette in hexbin.

Hope this helps,

Roger

>
> Since I am plotting in many cases one point almost over the other
> a reduction should be reasonable - question is how to do that?
>
> I am speaking about 3 plots in one graph, say "original", "interim"
> and "final" (so, one plot() and two points()).
>
> Any advice welcome,
> Markus
> _______________________________________________
> grass-stats mailing list
> grass-stats at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-stats
>

-- 
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Helleveien 30, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
e-mail: Roger.Bivand at nhh.no



More information about the grass-stats mailing list