[R] Help with interfacing C & R
Oleg Sklyar
osklyar at ebi.ac.uk
Fri Feb 9 01:20:11 CET 2007
> E:\My Documents\work\projects\landmarks\tryc>ls
> hello.c hello2.r
It is always advisable not to have spaces in such directories (like the
ones you want to include into a system variable), but fine.
> E:\My Documents\work\projects\landmarks\tryc>R CMD SHLIB hello.c
> 'R' is not recognized as an internal or external command,
> operable program or batch file.
Your R is not in the PATH! You need to add it, see also below!
> E:\My Documents\work\projects\landmarks\tryc>echo %PATH%
>
C:\texmf\miktex\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\P
> rogram Files\ATI Technologies\ATI Control
> Panel;E:\PROGRA~1\F-Secure\Ssh;E:\Prog
> ram Files\ESTsoft\ALZip\;C:\Program
> Files\QuickTime\QTSystem\;E:\prg_files\tools
>
\bin;E:\prg_files\cygwin\bin;E:\prg_files\cygwin\lib;E:\prg_files\ActivePerl\Act
>
ivePerl\Perl\bin;E:\prg_files\ActivePerl\ActivePerl\Perl\lib;E:\Program
> Files\ES
> Tsoft\ALZip\
There are at least 2 mistakes that I see in your PATH above:
- you need to add: E:\prg_files\R\R-2.4.1\bin;
- you need to add path to wherever MinGW\bin is and add it before
cygwin! if you do not have MinGW installed, download and install it.
I guess E:\prg_files\tools\bin are RTools, if so, this is fine. Your own
program must not necessarily be in the PATH
--
Dr Oleg Sklyar | EBI-EMBL, Cambridge CB10 1SD, UK | +44-1223-494466
More information about the R-help
mailing list