[R] About upgrade R

John C Frain frainj at gmail.com
Mon Nov 15 16:38:59 CET 2010


Tal

My main use of R now is on Windows 7.  As explained I always retain at
least one previous version on windows 7 PCs.  My upgrade is done as
follows -

1) Download and install the binary install program for R and install.
2) Rename the library directory (default - C:\Program
Files\R\R-2.12.0patched\library) to library2. (Windows 7 will ask for
confirmation)
3) Copy the library directory from the previous version of R to the R
directory (default - C:\Program Files\R\R-2.12.0patched\) ((Windows 7
will ask for confirmation).
4) copy the contents of the library2 directory to the library
directory in the new R directory.
5) Right click on the R directory and select "run as administrator" to
start R as administrator.
6) In R run some variant of update.packages(checkBuilt=TRUE).  On
occasion one will find that packages are reporting errors in the CRAN
compile and binary versions are not yet available for the new version
of R.  I delete these from the library directory and look in CRAN for
possible explanations.  Anyway I can revert back to the old version if
I need these packages.  Generally one may find that the missing
packages are available shortly afterwards.
.
This procedure is fairly close to that recommended in the R FAQ and
meets my needs.  I think that it is necessary to keep libraries for
different versions separate.  Other users may have different
requirements and other update methods may be more appropriate to them.
 There may be no method that is best for all users.  I would imagine
that one could write a DOS or Power Shell or Python (or other) script
that would  automate this process.

Best Regards

John

On 14 November 2010 20:24, Tal Galili <tal.galili at gmail.com> wrote:
> Hi John, thank you for that input.
> It could be that the code I wrote here:
> http://www.r-statistics.com/2010/04/changing-your-r-upgrading-strategy-and-the-r-code-to-do-it-on-windows/
> Should be updated so every time you install a new R version, you run the
> code for it to:
> 1) copy all packages from the old R version to the new R version library
> 2) update all the packages.
> But I have no clue how to do step 1.
> How do you find out the latest R version that was install previous to the
> current one?
> And then, how would you find where it's package library is?
> If you could do this in R, then installing a new version of R could be made
> simpler for you.
> Cheers,
> Tal
>
>
>
> ----------------Contact
> Details:-------------------------------------------------------
> Contact me: Tal.Galili at gmail.com |  972-52-7275845
> Read me: www.talgalili.com (Hebrew) | www.biostatistics.co.il (Hebrew) |
> www.r-statistics.com (English)
> ----------------------------------------------------------------------------------------------
>
>
>
>
> On Sun, Nov 14, 2010 at 10:05 PM, John C Frain <frainj at gmail.com> wrote:
>>
>> The current method allows one to easily retain several versions
>> working in parallel. This particularly important if some package is
>> not available in the new version. A few years ago there were problems
>> such as these during a major overhaul of the rmetrics group of
>> packages. My current practice is to retain older versions until I am
>> sure that all I need is available in the new version. Thus I am in
>> favour of retaining the current system.
>>
>> John
>>
>> On Sunday, Novembe 14, 2010, Uwe Ligges <ligges at statistik.tu-dortmund.de>
>> wrote:
>> >
>> >
>> > On 14.11.2010 17:59, Ajay Ohri wrote:
>> >
>> > wont it make more common sense to make updating packages also as part
>> > of every base version install BY Default...... just saying
>> >
>> >
>> > At least I do not like the idea: If I just want to try a beta version, I
>> > do not want that everything is updated and I can't switch back to my last
>> > stable version.
>> >
>> > Uwe Ligges
>> >
>> >
>> >
>> >
>> >
>> > Websites-
>> > http://decisionstats.com
>> > http://dudeofdata.com
>> >
>> >
>> > Linkedin- www.linkedin.com/in/ajayohri
>> >
>> >
>> >
>> >
>> >
>> > 2010/11/14 Uwe Ligges<ligges at statistik.tu-dortmund.de>:
>> >
>> > Upgrading is mentioned in the FAQs / R for Windows FAQs.
>> >
>> > If you have your additionally installed packages in a separate library
>> > (not
>> > the R base library) you can simply run
>> >
>> > update.packages(checkBuilt=TRUE)
>> >
>> > If not ...
>> >
>> > Uwe Ligges
>> >
>> >
>> > On 14.11.2010 15:51, Stephen Liu wrote:
>> >
>> >
>> > Hi all,
>> >
>> > Win 7 64-bit
>> > R version 2.11.1 (2010-05-31)
>> >
>> > I want to upgrade R to version 2.12.0
>> > R-2.12.0 for Windows (32/64 bit)
>> > http://cran.r-project.org/bin/windows/base/
>> >
>> > I found steps on following site;
>> > How to upgrade R on windows – another strategy (and the R code to do it)
>> >
>> >
>> > http://www.r-statistics.com/2010/04/changing-your-r-upgrading-strategy-and-the-r-code-to-do-it-on-windows/
>> >
>> >
>> > I wonder is there a straight forwards way to upgrade the package direct
>> > on
>> > repo?  TIA
>> >
>> > B.R.
>> > Stephen L
>> >
>> >
>> >
>> > ______________________________________________
>> > R-help at r-project.org mailing list
>> > https://stat.ethz.ch/mailman/listinfo/r-help
>> > PLEASE do read the posting guide
>> > http://www.R-project.org/posting-guide.html
>> > and provide commented, minimal, self-contained, reproducible code.
>> >
>> >
>> > ______________________________________________
>> > R-help at r-project.org mailing list
>> > https://stat.ethz.ch/mailman/listinfo/r-help
>> > PLEASE do read the posting guide
>> > http://www.R-project.org/posting-guide.html
>> > and provide commented, minimal, self-contained, reproducible code.
>> >
>> >
>> >
>> > ______________________________________________
>> > R-help at r-project.org mailing list
>> > https://stat.ethz.ch/mailman/listinfo/r-help
>> > PLEASE do read the posting guide
>> > http://www.R-project.org/posting-guide.html
>> > and provide commented, minimal, self-contained, reproducible code.
>> >
>>
>> --
>> John C Frain
>> Economics Department
>> Trinity College Dublin
>> Dublin 2
>> Ireland
>> www.tcd.ie/Economics/staff/frainj/home.html
>> mailto:frainj at tcd.ie
>> mailto:frainj at gmail.com
>>
>> ______________________________________________
>> R-help at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide
>> http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>
>



-- 
John C Frain
Economics Department
Trinity College Dublin
Dublin 2
Ireland
www.tcd.ie/Economics/staff/frainj/home.html
mailto:frainj at tcd.ie
mailto:frainj at gmail.com



More information about the R-help mailing list