need to upgrade my R version from 3.4.2 to 3.5.2

Hi ,

I want to upgrade my R version from 3.4.2 to 3.5.2 any suggestions to follow in upgrade process.

OS: centos 6.2

Thanks,

The current version is 3.6.1, but archived versions of 3.5.2 are available on CRAN to install from source. I'm not familiar with the package manager on Centos, but you may be able to specify a version install.

Rstudio Connect allows for several versions of R to be installed simultaneously. (You don't have to switch entirely. You can keep 3.4.2/3.4.4 etc... available for whomever needs them)

Admin Guide on installing R versions
https://docs.rstudio.com/connect/admin/r.html#r-versions

In line with the above, every so often I add new supported versions of R at /opt/R/

First I get the source of both 3.5.2 and 3.4.2 and drop them in /opt/R/src/ (make the directory if it is not already present)

wget https://cran.r-project.org/src/base/R-3/R-3.4.2.tar.gz /opt/R/src/
wget https://cran.r-project.org/src/base/R-3/R-3.5.2.tar.gz /opt/R/src/

(I get both because, I do not want to rely on the versions installed with the package manager, since there's a risk of an update making those go away)

untar those files and then compile them. It so happens that Rstudio has a guide for compiling in Centos:
https://docs.rstudio.com/connect/admin/getting-started.html#installation

When this is done, Rstudio connect will scan automatically and find these.

(Note if you rely on your Rprofile.site, which I do, you will need to make sure that you edit the files in their new locations)

Example
/opt/R/3.5.2/lib64/R/etc/Rprofile.site rather than/usr/lib64/R/etc/Rprofile.site

2 Likes