[Rd] motivation for setRepositories and chooseCRANmirror
ligges at statistik.uni-dortmund.de
Sat Jun 18 15:16:35 CEST 2005
Jeffrey Horner wrote:
> I have some questions and observations about these:
> Will these replace manually setting options(CRAN), which doesn't work in
> 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().
Hence, I have in our department's R installation's
.../R/etc/Rprofile.site file (which is intended for configurations that
apply to all users):
options(repos = c(
CRAN = "http://umfragen.sowi.uni-mainz.de/CRAN",
CRANextra = "http://www.stats.ox.ac.uk/pub/RWin"))
More information about the R-devel