Search code examples
rmemoryparameterscommand-line-argumentsstatet

How to set R command line parameters in StatET


I want to set command line parameters like --max-mem-size=8192MB or http_proxy=http:proxy.

When running R Gui I can do this by adding it at the end of the shortcut pointing at Rgui.exe

Does StatET support command line arguments?

I tried to add it under Run Configurations in Options/Arguments without success.

EDIT:

StatET doesn't support units like 'MB', only unit prefixes like 'M'. So for example:--max-mem-size=8G works.

For the proxy configuration & where to set what see the accepted answer


Solution

  • Run -> Run Configurations... -> Main -> Options/Arguments

    run config menu

    run config dialog main tab


    http_proxy should be specified as an environment variable (at least for use with download.file). Set those in:

    Run -> Run Configurations... -> Environment -> New...

    run config dialog environment tab


    Note that regardless of your IDE, you can set the memory limit in R on startup by adding

    memory.limit(1234)
    

    to your Rprofile.site or .Rprofile file.

    Likewise the HTTP_PROXY environment variable can be set by adding

    Sys.setenv(HTTP_PROXY = "http://www.myproxydomain.com")
    

    to that file.