I'm aware that there has already been a similar question here, but the answer is out-of-date. The information I've found in the internet refers to RStudio Server rather than Desktop.
I have limited resources on my Windows 7 x64 PC. I've set the environment variable R_MAX_MEM_SIZE and this is accepted by the RGui (as seen when typing memory_limit()
). However, RStudio (Version 0.98.507) ignores this setting and still uses the entire memory of my computer which sometimes leads to crashes of the whole system. How can I limit the amount of memory used by R when running it in RStudio Desktop?
1600, the RStudio IDE includes a small memory usage widget in the Environment pane. This widget helps you track the amount of memory your R session is using. The pie chart shows the total system memory usage; that is, if your system has 8GB of RAM and 4GB is currently in use, it will show at 50%.
Under most 64-bit versions of Windows the limit for a 32-bit build of R is 4Gb: for the oldest ones it is 2Gb. The limit for a 64-bit build of R (imposed by the OS) is 8Tb.
RStudio Connect's hardware specifications will depend on the number and type of applications, documents, and analysis running on the server. Standard specifications for a production server might range from 8-16 cores and 32-128 GB of RAM.
For a 64-bit versions of R under 64-bit Windows the limit is currently 8Tb. Memory limits can only be increased.
This works for my PC :
# Check memory limit memory.limit() # Change memory limit memory.limit(size = 15000)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With