Re: [Rd] package installation order

From: Prof Brian Ripley <>
Date: Wed, 14 Nov 2007 16:43:05 +0000 (GMT)

On Wed, 14 Nov 2007, Kuhn, Max wrote:

> Professor Ripley,
>> You need the information from available.packages() to do the ordering,
> so
>> you need a non-NULL repository. This works if you convert your local
>> collection into a local repository. You will need a PACKAGES file, but
>> tools::write_PACKAGES can re-create one for you.
>> There are also dependency tools in package tools and on BioC.
> This is probably a better option for me given that my source files are a
> little out of date. I couldn't get it to work though.
> I put the tar.gz files into a sub-directory (./src/contrib)
> I ran write_PACAKGES referencing that directory and type = "source" and
> verbose = TRUE. No error messages were given and it resulted in PACKAGES
> and PACKAGES.gz files that appeared to have all the right info in it.
> I figured out the package names by parsing the names of the tar.gz
> files.
> I then ran
> install.packages(pckList[1:3],
> repos = "/home/max/tmp/r-2.5.1-pkgs-updated/src/contrib",
> contriburl = "/home/max/tmp/r-2.5.1-pkgs-updated/src/contrib",
> type = "source")

It does say 'URL(s)', hence

repos = "file:///home/max/tmp/r-2.5.1-pkgs-updated"

is I think all you need. Here's a (working) example local to me:

> install.packages("yags", repos="file:///data/ftp/pub/RWin")

> No packages were installed and I had the warnings:
> Warning: unable to access index for repository
> /home/max/tmp/r-2.5.1-pkgs-updated/src/contrib
> Warning message:
> packages 'Cairo', 'Design', 'ElemStatLearn' are not available in:
> install.packages(pckList[1:3], repos =
> "/home/max/tmp/r-2.5.1-pkgs-updated/src/contrib",
> (those particular packages are in ./src/contrib.) I also tried different
> variations of using the file names etc.
> I'm assuming that I don't have a proper repository. Am I missing
> something obvious here and/or is there some documentation on what the
> elements of a repository are?

There is, in the R-admin manual.

> Thanks again,
> Max

Brian D. Ripley,        
Professor of Applied Statistics,
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

______________________________________________ mailing list
Received on Wed 14 Nov 2007 - 16:59:23 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 14 Nov 2007 - 21:30:19 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.