Difference between revisions of "R Statistical Package"

From oldwiki.scinet.utoronto.ca
Jump to navigation Jump to search
(Instructions for installing R packages)
 
m
Line 1: Line 1:
[http://www.r-project.org/ R] is powerful statistical and plotting software available on the [[GPC_Quickstart|GPC]].
+
[http://www.r-project.org/ R] is powerful statistical and plotting software available on the [[GPC_Quickstart|GPC]] in the [[Software_and_Libraries|module]] R.
  
 
Many optional packages are available for R which add functionality for specific domains; they are available through the [http://cran.r-project.org/mirrors.html Comprehensive R Archive Network (CRAN)].  
 
Many optional packages are available for R which add functionality for specific domains; they are available through the [http://cran.r-project.org/mirrors.html Comprehensive R Archive Network (CRAN)].  

Revision as of 20:55, 29 March 2011

R is powerful statistical and plotting software available on the GPC in the module R.

Many optional packages are available for R which add functionality for specific domains; they are available through the Comprehensive R Archive Network (CRAN).

R provides an easy way for users to install the libraries they need in their home directories rather than having them installed system-wide; there are so many potential optional packages for R people could potentially want, we recommend users who want additional packages to proceed this way. This is almost certainly the easiest way to deal with the wide range of packages, ensure they're up to date, and ensure that users package choices don't conflict.

In general, you can install those that you need yourself in your home directory; eg,

$ R 
> install.packages("package-name", dependencies = TRUE)

will download and compile the source for the packags you need in your home directory under ${HOME}/R/x86_64-unknown-linux-gnu-library/2.11/ (you can specify another directory with a lib= option.) Then take a look at help(".libPaths") to make sure that R knows where to look for the packages you've compiled.