Skip to content
Prev 164618 / 398502 Next

Make installed packages available to new R version

Roy Robertson <jroyrobertson at comcast.net> wrote:

            
Here is my solution. It has worked over many releases of R,
though it will probably require one initial re-installation of
packages.

Set environment variable R_LIBS to some permanent directory
before installing a version of R. (That is, NOT a directory
under the tree of your current R version.) When you subsequently
install packages, they will go into that location and won't need
re-installation with each new version of R. 

It's still necessary to run update.packages() periodically --
such as after installing a new R version -- to keep the
installed packages current.