[R] Upgrading an installation of R

Prof Brian D Ripley ripley at stats.ox.ac.uk
Sun Mar 3 08:22:14 CET 2002

On Sun, 3 Mar 2002, Kenneth Cabrera wrote:

> ggrothendieck at yifan.net wrote:
> > I have installed R 1.4.0 on Windows 2000 and would like  to
> > upgrade to the newest version of R.  I am scared of messing
> > this up badly and would like to know if I should:
> >
> > - uninstall my current version first, or
> > - just install the newer version without uninstalling
> > the current version
> >
> > Do either of these work?  If both work, which is
> > preferable? Will I have to reinstall various
> > packages that I previously installed on 1.4.0?
> >
> When I upgrade R, y make the second option, because
> sometimes there are new bugs on the new version, or
> some of my old functions don't work on the new version
> for one reason or another...either way I install the new version
> on a different place (usually the setup installs it on a new directory
> rw1041) so there are independent.

That is relevant in moving from rw1031 to rw1040, say, but I don't think
so for patch releases.

> And later if you want to delete the old version it is very easy...
> Just delete the directory and the links and/or the shortcuts to
> the Rgui.exe program. R is a very clean program (no register stuff... )

You can also run the uninstall program in the old directory.

> And yes... you must reinstall the packages, but I make
> a copy of the \library directory to the new one... and then
> I use the upgrade.package() function to get the latest
> pre compiled packages.

You must do that rather carefully: library contains the standard packages
too, and they must be the correct versions.  It is better to use a separate
library for packages you install: see the rw-FAQ for how to do so.
Alternatively, uninstall 1.4.0, install 1.4.1 and then copy across the
rw1040\library directory.  Anything packages you added will be left alone
by the uninstall.

However you do it, run link.html.help() afterwards.

Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272860 (secr)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch

More information about the R-help mailing list