Large data set contour plot in R/Splus?

389 views Asked by At

I am working with very large data sets named u10 and u10s consisting of 30016950 values.

Now what I am trying to do is a contour plot to aid in the comparison of the two (a scatter plot is just too messy).

I've looked around and found code such as;

x<-u10
y<-u10s
zfunc <- function (x,y) {
1/2/pi*exp(-(x^2+y^2)/2)
}
z<-outer(x,y,zfunc)

contour(x,y,z,nlevels=10)

However,

Error: cannot allocate vector of size 6835453.9 Gb, 
Reached total allocation of 4025Mb: see help(memory.size)

This works with a small data set but unfortunately not a large one like mine.

I have also tried using kde2d which again works with a small data set but not mine since it produces the same error.

Any hints on how I would go about producing such a contour/filled.contour plot successfully in R/splus?

0

There are 0 answers