On Feb 6, 2012, at 11:15 , Alaios wrote:
> Dear all,
> I have tried to create a diagonal matrix of size diag(65536)
>
> I am getting the message that the array function can not create so big
array as the value I ask is larger than the
>
>
> <environment: namespace:base>
>> .Machine$integer
> [1] 2147483647
>
>
> as you will see my .Machine$integer is the one above. What that variable
means? I am using R in a system that has 500 GB of ram available. Would it be
something wrong in the installation?
Well, it means what it says. Indexing is limited by the size of a 32-bit integer
and (2^16)^2 is too big for that. So you are limited to roughly 16 GB for any
single object in R.
This issue has been foreseeable for some time. It can only be fixed by internal
changes in the R engine, but switching to long integers has various issues, so
it is not a straightforward modification.
Meanwhile, you might want to consider whether you really do need a diagonal
matrix of that size stored in full. It's an awful lot of zeroes to carry
around....
>
> Regards
> Alex
>
> [[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.
--
Peter Dalgaard, Professor
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Email: pd.mes at cbs.dk Priv: PDalgd at gmail.com