Skip to content

R v2.13.2 - Cannot find Rcmd on path?

9 messages · Uwe Ligges, Hardy Griesbauer, Gabor Grothendieck +4 more

#
On Fri, Oct 21, 2011 at 5:07 PM, Hardy Griesbauer
<hgriesbauer at hotmail.com> wrote:
There is a batch command Rcmd.bat at http://batchfiles.googlecode.com
that when run will find R using the registry and then run the
appropriate Rcmd.exe so that you don't need to change your path or any
other environment variable.

Its a self contained .bat file so just place it anywhere on your
existing path.  At the Windows console this command will show you your
path:  path

Now try

Rcmd.bat build ...whatever...

If your path is not already set to find Rcmd.exe then Rcmd.bat can be
abbreviated to just Rcmd in the above line.
#
On 13.11.2011 17:29, Gabor Grothendieck wrote:
I wonder again and again why you try to obfuscate things by your layer 
of non portable batchfiles. Typing the path correctly and according to 
the syntax is required in both cases anyway.

Best,
Uwe
#
I remember I was torn into pieces a few months back when I made a
wishlist here that R adds its bin path to PATH on Windows during
installation. People had tons of reasons of objection. Although I do
not use these batchfiles (usually I do not actually use Windows), I
see there is a motivation behind them: there needs to be an easy way
for Windows users to use R in command line (e.g. R CMD build...). You
may argue that it is easy to understand PATH and modify it manually,
and I will say nothing but "thank" Windows again. Sorry this seems to
be off-topic.

Regards,
Yihui
--
Yihui Xie <xieyihui at gmail.com>
Phone: 515-294-2465 Web: http://yihui.name
Department of Statistics, Iowa State University
2215 Snedecor Hall, Ames, IA



2011/11/13 Uwe Ligges <ligges at statistik.tu-dortmund.de>:
#
For what it's worth: the fix was to put the x64 folder FIRST in the path. 

-----Original Message-----
From: xieyihui at gmail.com [mailto:xieyihui at gmail.com] On Behalf Of Yihui Xie
Sent: November-13-11 10:16 AM
To: Uwe Ligges
Cc: Gabor Grothendieck; r-help at r-project.org; Hardy Griesbauer
Subject: Re: [R] R v2.13.2 - Cannot find Rcmd on path?

I remember I was torn into pieces a few months back when I made a
wishlist here that R adds its bin path to PATH on Windows during
installation. People had tons of reasons of objection. Although I do
not use these batchfiles (usually I do not actually use Windows), I
see there is a motivation behind them: there needs to be an easy way
for Windows users to use R in command line (e.g. R CMD build...). You
may argue that it is easy to understand PATH and modify it manually,
and I will say nothing but "thank" Windows again. Sorry this seems to
be off-topic.

Regards,
Yihui
--
Yihui Xie <xieyihui at gmail.com>
Phone: 515-294-2465 Web: http://yihui.name
Department of Statistics, Iowa State University
2215 Snedecor Hall, Ames, IA



2011/11/13 Uwe Ligges <ligges at statistik.tu-dortmund.de>:
the
http://www.R-project.org/posting-guide.html
#
On Sun, Nov 13, 2011 at 1:38 PM, Hardy Griesbauer
<hgriesbauer at hotmail.com> wrote:
Of course that only fixes it for now.   Every time you upgrade R you
have to change it all over again.  With the batch files there is
nothing to set and therefore nothing to change each time.
#
On 11-11-13 1:15 PM, Yihui Xie wrote:
I don't remember any rending and tearing, but I do remember objections 
to modifying the path during installation.  I wouldn't want to write 
code to do that, because it's hard:

- Most people don't want to put R first, because it may hide something 
important.

- Putting it last won't work if an earlier version is already there.

So you need to examine the path and correct it, an automatic change is 
unlikely to be successful.

But if you want to write code to do that, just go ahead and do it.  Put 
it in a package, even.

Duncan Murdoch
#
Well, I just mean to give the user an option during installation --
like you did in Rtools. I have decided not to argue on this issue any
more. Thanks a lot anyway!

Regards,
Yihui
--
Yihui Xie <xieyihui at gmail.com>
Phone: 515-294-2465 Web: http://yihui.name
Department of Statistics, Iowa State University
2215 Snedecor Hall, Ames, IA



On Sun, Nov 13, 2011 at 4:20 PM, Duncan Murdoch
<murdoch.duncan at gmail.com> wrote:
#
FYI,

you can use tools such as Path Manager 1.1.1 (GPL) on Windows:

 http://www.softpedia.com/get/System/System-Miscellaneous/Path-Manager.shtml

to list, modify (add, remove, reorder, remove duplicates, normalize)
your PATH environment variable.  For each directory it identifies in
PATH it will also let you know whether it is valid or not and list
files that exist in that directory, iff valid.  So, if you don't see
Rcmd.exe where you expect it to be, you know you did something wrong
when setting PATH.

My $.02

/Henrik
On Sun, Nov 13, 2011 at 9:50 PM, Yihui Xie <xie at yihui.name> wrote: