I have a Windows 8.1 / 64bit / SSD 240Gb / 12Gb RAM.
I'm just running Rstudio but I can't complete a task as it gives me the error Error: cannot allocate vector of size 2.1 Gb
. I noticed that while running R it, windows have between 5/6 Gb of RAM left. what could it be?
Asked
Active
Viewed 271 times
0

Phil
- 7,287
- 3
- 36
- 66

carvalhosantos
- 57
- 6
-
Does this answer your question? [Error: cannot allocate vector of size 57.8 Gb](https://stackoverflow.com/questions/56201959/error-cannot-allocate-vector-of-size-57-8-gb) – Phil Sep 27 '21 at 16:35
-
But because even having RAM available, R can't use it? – carvalhosantos Sep 27 '21 at 16:41
-
R can allocate more memory if it's available. Does this post help? https://stackoverflow.com/questions/1395229/increasing-or-decreasing-the-memory-available-to-r-processes – Harrison Jones Sep 27 '21 at 16:52
-
I tried to allocate 11.5 GB, but even so, R returns saying it is impossible to allocate a vector with 28.8 GB. It seems to me that R to execute the command, it generates a 28 GB temporary file and it can't finish!!! – carvalhosantos Sep 27 '21 at 21:53
-
I tried using `memory.limit()` as suggested, but even allocating about 11.5GB /12GB, R generates would need 28.8GB to complete the process. I don't know why it generates such a large data.frame. – carvalhosantos Sep 27 '21 at 22:48
-
Are you perhaps using the 32-bit version of R? – anymous.asker Sep 28 '21 at 04:40