April 2011 Archives

Geek talk: Running R processes remotely through ESS

I've been wondering for a while how to use the convenience of Emacs on a local machine, while running R processors on a server remotely. According to http://www.xemacs.org/Documentation/packages/html/ess_3.html, this can be done with the ess-remote environment.

1) Use M-x shell to open a shell environment.

2) Use ssh to connect to the server of interest. If desired, use "screen" to make the process resilient to disconnection.

3) Run R.

4) Use M-x ess-remote to enable the shell as an ESS process.

The advantages of this process are the added convenience of an environment that allows instant execution of lines of R code. Files still must be loaded on the remote server, rather than referenced on the local machine, but it's still an improvement.