[ESS] ESS in Windows: Unable to run editor "gnuclient.exe"

Paul Johnson pauljohn32 at gmail.com
Thu Mar 3 07:25:15 CET 2011

On Tue, Mar 1, 2011 at 10:45 PM, Richard M. Heiberger <rmh at temple.edu> wrote:
> Paul,
> you hit two issues.
> 1. ESS by default finds R automatically when R is installed in the standard
> places
> defined by R-Core which are (in English locales, it also does the right
> thing in other languages)
> c:/Program Files/R/R-*/
> When you place R in a non-standard place such as c:/Program Files/R/, a
> workaround
> like the one that you used is necessary.  It would be better to put that
> statement
>   (setq-default inferior-R-program-name "c:/Program
> Files/R/bin/i386/rterm.exe")
> in your .emacs, rather than make changes to ess-site.el.  This type of
> workaround is
> illustrated in ess-site.el.
> 2. The gnuclient issue.  We have gnuclient hardwired in the code for
> Windows.
> The newer emacs distributes with emacsclient.
> You can manually issue the command to R,
>    options(STERM='iESS', editor='emacsclientw.exe')
> I don't like emacsclient as much as I liked gnuclient.  If you still have an
> old gnuclient
> on your machine you can use it by starting it in your .emacs file.
> ESS intercepts R page() commands at the command line and open them in emacs.
> That is somewhat easier since the pager doesn't have a return value.
> It is not obvious to me why you would want to use the R fix() or edit()
> command when you
> are working in the emacs environment.
> Question for other ESS-core members:  would it make sense to intercept the
> edit()
> and fix() commands?  See defun inferior-R-input-sender in ess-inf.el for
> details.
> Rich
Hi, Rich.

Today I was teaching on a RedHat 6 system that I'd never used before
and fix(lm) gave me the error about emacsclient or gnuclient not being
available.  Guess what did work:


But one of the student readers of this list told me a solution that
works,but is somewhat hard to remember.

After starting R, C-c C-d in Emacs opens an editor similar in nature to "fix".

I knew that before, but I did not know that this

C-c C-l

will load that code back into the R session.  So it is exactly like
fix(), but harder to remember and nobody would ever guess it works if
they just read the R Extensions manual.

So, if you could divert fix() to cause C-c C-d to start and C-c C-l at
the end, I'd say you have a winner.

As long as you don't break the fix() that leads to the spreadsheet
data thing.  That spreadsheet data thing, and "Jeopardy Powerpoint",
are the best things that Windows has going for it.

Paul E. Johnson
Professor, Political Science
1541 Lilac Lane, Room 504
University of Kansas

More information about the ESS-help mailing list