[R] cannot allocate a vector with 1920165909 length
jim holtman
jholtman at gmail.com
Wed Jul 29 03:59:18 CEST 2009
What are you trying to do? The expand.grid will create an object with
10 billion rows with 5 variables. My guess is that you would need 50G
* 8 bytes/word = 400GB just to hold the one object. How much memory
do you have on your system? Is there some other approach you can use?
You may have problems since I think an object can only have 2^31
values and your would have quite a bit more.
I would suggest that you rethink your problem that you are trying to solve.
On Tue, Jul 28, 2009 at 9:49 PM, zhijie zhang<rusers.sh at gmail.com> wrote:
> Dear Rusers,
> The error for the following was that it cannot allocate the vector of
> length 1920165909.
> a <- expand.grid(se1=0:100/100, sp1=0:100/100, se2=0:100/100, sp2=0:100/100,
> DR=0:100/100)
> How to solve it? Maybe setwd(dir) can, i am not very sure about it.
> Any ideas about it?
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
--
Jim Holtman
Cincinnati, OH
+1 513 646 9390
What is the problem that you are trying to solve?
More information about the R-help
mailing list