help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Can't open R in Emacs


From: poti
Subject: Re: Can't open R in Emacs
Date: Tue, 21 Aug 2007 02:33:30 -0400
User-agent: Mutt/1.5.13 (2006-08-11)

On 21:58 Fri 03 Aug     , Hosley wrote:
> On Aug 3, 11:14 pm, Marc Schwartz <marc_schwa...@comcast.net> wrote:
> > Hosley <kbro...@gmail.com> writes:
> > > I need to setup up R, ESS, and GNU Emacs for a class but am having
> > > problems. I'm trying to open R in Emacs by following these steps:
> >
> > > 1. Open Emacs
> > > 2.Ctrl-x 2, to open 2 buffers
> > > 3. Selecting top buffer and clicking Alt-x
> > > 4. Typing 'R' then hitting 'enter' twice
> >
> > > This is supposed to open R in the top buffer but instead I get a error
> > > saying no such file or directory. It appears to be look into c:/devl/
> > > emacs/bin as the default. Yet if I type in the correct path (c:/
> > > program files/R/R-2.5.0/bin) manually I get the same error.
> >
> > > Bu the way, I can open R by itself (standalone) and it works fine.
> >
> > > I know this is about as novice as it gets, but I'm not used to these
> > > environments. Any suggestions would be great!
> >
> > > Thanks,
> > > Hos
> >
> > You might want to review this from the ESS Manual:
> >
> > http://ess.r-project.org/Manual/ess.html#Microsoft-Windows-installation
> >
> > Also, there is a dedicated ESS mailing list. More info here:
> >
> > https://stat.ethz.ch/mailman/listinfo/ess-help
> >
> > Finally, note that the current version of R is 2.5.1. You should get
> > the latest version from your local CRAN mirror.
> >
> > HTH,
> >
> > Marc Schwartz
> 
> Thanks for letting me know about 2.5.1. Unfortunately it still cannot
> be found by Emacs.

Is R in your path? If not, the following is edited down from
what I do in my startup file (you can put it in _emacs), which 
can be extended to add other programs:

(let* ((rpath (directory-file-name (mapconcat 'file-name-as-directory (list
"C:" "Program Files" "R" "R-2.5.0" "bin") ""))))
  (setq tlpath (list rpath)))
(setq exec-path (append tlpath exec-path))
(setenv "PATH" (concat (mapconcat (lambda (dir) (or dir ".")) tlpath
path-separator)  path-separator (getenv "PATH")))

> 
> Also, I will try to read the manuals again, but a lot of the advice
> I've come across indirectly relates to my issue and involves (meaning
> it may or may not fix the issue) making a lot of changes that alter
> the step by step instructions I was following, which I'm afraid to do
> at this point. Obviously these programs are extremely sensitive to
> small installation errors/typos and I don't want to dig myself further
> into a hole.


Aside from adding R to my path, placing the ess directory in 
Emacs/site-lisp/
and adding 

(require 'ess)

to _emacs works fine for me with no other alterations to my Emacs/ess/R 
installation. 

-Poti





reply via email to

[Prev in Thread] Current Thread [Next in Thread]