2009-09-09

Installing R from CRAN, Bioconductor and Related Interfaces

Use the following link to fetch the last stable version from CRAN .

R for All
Choose the last universal tar.gz file.

R for Windows
Choose the last installable file.
We can use R in the CommandPrompt if we add Path=Path;%R_PATH%

RDCOMServer: Look for other software and install R(D)COM Interface as DCOMServer usig R\DCOMServer and the variable RDCOM_PATH=D:\GNU\R\DCOMServer\bin. But you need rscproxyand rcom installed on R.
RExcel: Look for this link.

R for MacOS X
Choose the last dmg file.

R for Ubuntu
Choose the last binary file in /bin/linux/ubuntu or
&] sudo apt-get -y install r-*

R for fedora
Choose the last rpm file in /bin/linux/redhat/fedora1*/{i386,x86_64,src) or
&] sudo yum -y install R-*

RStudio (R multiform IDE)
Choose the last version of R to install in your machine (multiple version are allowed) and install IDE from their site.

GGobi for R

iPlots for R

iPlots eXtreme for R

ReShape for R

Plyr for R

R-commander from R
Read the documentation.
You can choose your packages to install from repository or to do it directly from R CMD
&] sudo R
&] install.packages("Rcmdr", dependencies=TRUE)
] install.packages(c("car","MASS","nnet","XLConnect"))

Bioconductor from R
Read the documentation.
You can choose your packages to install from repository or to do it directly from R CMD
&] sudo R
> source("http://bioconductor.org/biocLite.R") ; biocLite()
> source("http://bioconductor.org/getBioC.R") ; getBioC()

R Environment Variable
Windows:
R_HOME=D:\GNU\R\R-2.10.1
Ubuntu:
R_HOME=/usr/lib/R
OSX:
R_HOME=/Library/Frameworks/R.framework/Resources
At the end:
RHOME=$R_HOME
R_PATH=$R_HOME/bin
R_PATH=D:\GNU\R\R-2.10.1\bin
R_LIBS=$R_HOME/library

Windows R(D)COM interface for R using CSharp
Read the documentation.

RPy interface for R
Read the documentation.
&] sudo yum install rpy.i686 #in fedora
The steps are:
  1. Check that you have built R with the configure option '--enable-R-shlib' to make R as a shared library
  2. &]cd $R_HOME
  3. &]make distclean
  4. &]./configure --enable-R-shlib
  5. &]make
  6. &] make install 
The 2 following steps are optional:
  1. make a link to RHOME/bin/libR.so in /usr/local/lib or /usr/lib, then run 'ldconfig'
  2. or put the following line in your .bashrc (or equivalent) &] export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:RHOME/bin
  3. or edit the file /etc/ld.so.conf and add the following line RHOME/bin, then run 'ldconfig'.
  4. &] python setup.py install

RPy2 interface for R
Read the documentation.
The steps are:
  1. &] easy_install rpy2
  2. &] tar -zxf rpy2_package.tar.gz
  3. &] cd rpy2_package
  4. &] python setup.py install
Test:
import rpy2.tests
import unittest

# the verbosity level can be increased if needed
tr = unittest.TextTestRunner(verbosity = 1)
suite = rpy2.tests.suite()
tr.run(suite)

RSPython interface for R
Read the documentation.
The steps:
  1. &] sudo cp ~/Downloads/RSPython_0.7-1.tar.gz /opt ; cd /opt
  2. &] sudo chmod -R +x RS*
  3. &] sudo R CMD INSTALL -c RSPython_0.7-1.tar.gz

RSPerl interface for R
The steps:
  1. &] sudo cp ~/Downloads/RSPerl_0.92-1.tar.gz /opt ; cd /opt
  2. &] sudo chmod -R +x RS*
  3. &] sudo R CMD INSTALL -c -l --configure-args='--with-in-perl' RSPerl_0.92-1.tar.gz # -l is option for PERL5LIB
Rserve interface for R
You can try another mirror to fetch the file.
Read the documentation.
In R, sudo R
> install.packages(Rserve)

RRuby interface for R
You can try another mirror to fetch the file.
Read the documentation.
&] sudo gen install rinruby

RinRuby interface for R
You can try another mirror to fetch the file.
Read the documentation.

RSRuby interface for R
You can try another mirror to fetch the file.
Read the documentation.

First option:
  1. &] sudo cp ~/Downloads/rsruby*{gem,tgz} /opt ; cd /opt
  2. &] sudo chmod -R +x rs*
  3. &] sudo gem install rsruby-0.5.1.1.gem --with-R-dir=$R_HOME
Second option:
  1. &] sudo tar -zxf rsruby-0.5.tgz
  2. &] sudo chmod -R +x rs*
  3. &] cd rsruby
  4. &] ruby setup.rb config -- --with-R-dir=$R_HOME
  5. &] ruby setup.rb setup
  6. &] ruby setup.rb test
  7. &] sudo ruby setup.rb install
This is a new Ruby interface for R/S found at RubyForge .
Note that you’ll need to set the R_HOME and RHOME environment variable prior to installation.
On MacOX, RHOME=R_HOME=/Library/Frameworks/R.framework/Resources.
On Ubuntu, when installed from source, RHOME=R_HOME=/usr/local/lib/R. It is useful to just drop this into /etc/environment so that this variable is set upon login.
Otherwise update /etc/bash_profile .

&] export R_HOME=/path/to/R/for/your/OS
&] export RHOME=/path/to/R/for/your/OS
&] sudo gem install rsruby -- --with-R-dir=$R_HOME
On Ubuntu
&] sudo gem install rsruby -- --with-R-home=/usr/lib/R --with-R-include=/usr/share/R/include

You may try to install it from source. Compile and install the Ruby library using setup.rb as shown. You need to supply
the location of your R installation for the libR shared library. This will usually be
the same as R_HOME.

&] cd rsruby
&] ruby setup.rb config -- --with-R-dir=/usr/lib/R
&] ruby setup.rb setup
&] sudo ruby setup.rb install

You may test it
&] ruby setup.rb test


&] irb -rrsruby
>> @R = RSRuby.instance
>> @R.wilcox_test([1,2,3],[4,5,6])
>> foo = @R.as_data_frame(1)



No comments:

HTMLCode

HTMLCode Content