User Tools

Site Tools


Table of Contents


R is a free software environment for statistical computing and graphics.



See which versions are available:

$ module avail R

Load one version into your environment and run it:

$ module load R/4.3
$ R

Use installed.packages() to check the list of packages installed in the ILRI environment by default. Here is a good resource on installing R packages into user libraries if you need other packages.


Notes from the sysadmin during installation.

First, compile the main R application:

$ cd /tmp
$ wget
$ tar xf R-4.3.1.tar.gz
$ cd R-4.3.1
$ sudo dnf install tcl-devel tk-devel
$ ./configure --enable-R-shlib --prefix=/export/apps/R/4.3
$ chrt -b 0 make -j4
$ sudo mv /export/apps/R/4.3 /export/apps/R/4.3.bak
$ sudo mkdir /export/apps/R/4.3
$ sudo chown aorth:aorth /export/apps/R/4.3
$ make install

Then install some common libraries used by our users because some of them are quite complicated, and installing them globally saves tens of thousands of header files and libraries being installed into user libraries anyways:

$ /export/apps/R/4.3/bin/R
# > Sys.setenv(MAKEFLAGS = "-j2") # didn't try
> options(Ncpus = 4) # This does 4 parallel package installs
> install.packages('sf', repo='')
> install.packages("hierfstat", repos="")
> install.packages("adegenet", repos="")
> install.packages("BiocManager", repos="")
> install.packages("poppr", repos="")
> install.packages("vcfR", repos="")
> install.packages("devtools", repos="")
> library(devtools)
> install_github("HenrikBengtsson/TopDom")
> install_github("lucidif/HiCeekR", repos=BiocManager::repositories())
> q()
$ sudo chown -R root:root /export/apps/R/4.3
r-software.txt · Last modified: 2023/07/12 06:39 by aorth