Step 1: Open terminal
Step 2:
cd ~
touch .Renviron
open .Renviron
Step 3: Save the following as the first line of .Renviron
:
R_MAX_VSIZE=100Gb
As noted in the source,
Sys.setenv('R_MAX_VSIZE'=32000000000)
only works in command line, doesn’t work for Rstudio
Source:
https://stackoverflow.com/questions/51295402/r-on-macos-error-vector-memory-exhausted-limit-reached