[R] Error: cannot allocate vector of size 1.8 Gb

iamsilvermember m2chan at ucsd.edu
Tue Dec 23 00:26:52 CET 2008


> dim(data)
[1] 22283    19

> dm=dist(data, method = "euclidean", diag = FALSE, upper = FALSE, p = 2)
Error: cannot allocate vector of size 1.8 Gb



Hi Guys, thank you in advance for helping. :-D

Recently I ran into the "cannot allocate vector of size 1.8GB" error.  I am
pretty sure this is not a hardware limitation because it happens no matter I
ran the R code in a 2.0Ghz Core Duo 2GB ram Mac or on a Intel Xeon 2x2.0Ghz
quard-core 8GB ram Linux server.

I also tried to clear the workspace before running the code too, but it
didn't seem to help...

Weird thing though is that once in a while it will work, but next when I run
clustering on the above result
>hc=hclust(dm, method = "complete", members=NULL)
it give me the same error...

I searched around already, but the memory.limit, memory.size method does not
seem to help.  May I know what can i do to resolve this problem?

Thank you so much for your help.
-- 
View this message in context: http://www.nabble.com/Error%3A-cannot-allocate-vector-of-size-1.8-Gb-tp21133949p21133949.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list