[R] Error: cannot allocate vector of size ...

Uwe Ligges ligges at statistik.uni-dortmund.de
Thu Dec 27 11:14:24 CET 2007



Maura E Monville wrote:
> I read the subject message in a number of R archived emails.
> Since I am experiencing the same problem:
> 
>> upfmla
> A ~ T + cosP + cos2P + cos4P + cos5P + sin3P + sin5P + cosP2 +
>     sinP3 + P2
>> glmod <- gls(upfmla,correlation=corAR1(),method="ML")
> Error: cannot allocate vector of size 491.3 Mb
> 
>> dim(xx)
> [1] 8025   14

How much memory is consumed in your workspace? If so, remove huge 
objects from your workspace
How big is upfmla? Are there factors in it? If so, how many levels? Then 
you can calculate the size of your design matrix.
64-bit is nice, but how much RAM is in your machine?

Uwe Ligges


> and since I'm running R on a 64-bit Linux platform ... I wonder whether this
> problem has
> been solved or I'm better off giving up the Generalized Least Squares
> models.
> Would it make sense to break the data into two halves and fit one half at a
> time ?
> 
> Thank you .
> 
> Happy new year,



More information about the R-help mailing list