[Rd] motivation for setRepositories and chooseCRANmirror

From: Jeffrey Horner <jeff.horner_at_vanderbilt.edu>
Date: Thu 16 Jun 2005 - 15:56:52 GMT

I have some questions and observations about these:

Will these replace manually setting options(CRAN), which doesn't work in R-2.1.0?

In R-2.1.0, setRepositories() looks to see if options("repos") contains a CRAN entry and will not override that CRAN entry even if the
$R_HOME/etc/repositories file (which setRepositories reads from)
contains a CRAN entry. Why is this? The user could easily set options("repos") without the help of this function anyway? And chooseCRANmirror() obviously sets the CRAN entry correctly.

I've checked the latest nightly tarball, R-devel_2005-06-15.tar.gz, and this observations persists.

I also observe that the R-2.1.0 Rprofile in the base package sets options(repos=c(CRAN="@CRAN@")), so it seems that the only way to set the CRAN repository entry is either with chooseCRANmirror() or manually setting options("repos") or options("CRAN"). If this was not the case, then setRepositories() would choose the CRAN entry from

In R-2.1.0 and in R-devel_2005-06-15.tar.gz, the R-admin manual suggests that for packages to be downloaded and installed within R should set options(CRAN = "http://cran.us.r-project.org/"). Will this be changed to calling chooseCRANmirror()?

 From an administrator's point of view, I would like to have the CRAN option set automatically on R startup for ALL users. That way I don't have to set this option before calling update.packages().

Jeffrey Horner       Computer Systems Analyst         School of Medicine
615-322-8606         Department of Biostatistics   Vanderbilt University

R-devel@r-project.org mailing list
Received on Fri Jun 17 02:28:26 2005

This archive was generated by hypermail 2.1.8 : Mon 20 Feb 2006 - 03:21:09 GMT