[R] geoR vector length error

Thomas Lumley tlumley at u.washington.edu
Tue Mar 25 16:06:51 CET 2003


On Tue, 25 Mar 2003, Kris Nackaerts wrote:

> Dear,
>
> we have a problem with geoR. We try to read an ASCII table (x,y,z) with 40000
> lines. With read.geodata we get the error:
>
> Error in vector("double", length) : cannot allocate vector of length 799980000
>
> We can read the file without any problem with read.table, but trying to
> convert it to the geodata class gets the same error.

Looking at the source of as.geodata() it seems that it uses dist() to
check for coincident points, and this will involve creating a vector of
length approximately 8x10^8. You can't do that in R.

	-thomas



More information about the R-help mailing list