[R] How to install a package that needs to see oher pkg dependencies:

Uwe Ligges ligges at statistik.uni-dortmund.de
Sun Oct 10 15:07:39 CEST 2004


Aldi Kraja wrote:

> Prof Brian Ripley wrote:
> 
>> The correct commands are
>>
>> R CMD INSTALL gregmisc_2.0.0.tar.gz
>> R CMD INSTALL genetics_1.1.0.tar.gz
>>
>> Wherever did you get `../bin/INSTALL -l .' from?
>>
>> You need to install into a library that is in the library path for the 
>> package to be usable, and the system library (the default) is the best 
>> choice.  (This is no different from S-PLUS, on which you have been asking
>> questions on s-news for many years.)
>>  
>>
> Thank you Brian for your response. In the online manual for the R 
> installation and administration (2004)
> it says:
> "Note that you need to specify implicitly or explicitly the library to 
> which the package is
> to be installed. This is only an issue if you have more than one 
> library, of course.
> To install packages from source on Unix use
> R CMD INSTALL -l /path/to/library pkg1 pkg2 ..."
> 
> I am working in a case where in the general path is already version 1.9, 
> and I am installing locally version 2.0.0
> My local copy will be removed in the moment that my Net. Adm. will 
> install version 2.0.0 in the general path.
> 
> I am executing INSTALL command under ..../aldi/r/R-2.0.0/gregmisc%
> I am executing INSTALL command under ..../aldi/r/R-2.0.0/genetics%
> So ../bin/ is the local place where I have INSTALL for v. 2,

The correct INSTALL script is found for each R version automatically (in 
its bin directory). You need to call the correct R binary, though.

> -l  . is the path where INSTALL has to look for the package, gregmisc etc.

No. since you are already in a folder called gregmisc.
If you want your private library, do it as mentioned in the doc you have 
cited yourself:
Create your own library tree and and install into that one. Note that 
you have to tell R to look into that library, e.g. by specifying an 
environment variable called R_LIBS.

If you are still confused, you might want to read the Help Desk article 
in R News 3(3).

Uwe Ligges



> The gregmisc works fine, it creates gdata.
> Genetics package is searching for gdata, but does not see it under my 
> local ...../gregmisc/gdata/
> So my question was: what do I need to provide to genetics to see gdata, 
> or what do I need to change to genetics to see the gdata?
> TIA,
> Aldi
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! 
> http://www.R-project.org/posting-guide.html




More information about the R-help mailing list