install.packages("foo", dep="Depends")

See online help. I think that the GUI version of install.packages
automatically does that.

Antonio.

2006/9/29, Søren Højsgaard <[EMAIL PROTECTED]>:
> I write a package foo which requires a package bar (from CRAN) to work. So in 
> the DESCRIPTION file I write Depends: bar. I would like it to be so that when 
> one installs foo, then it is automatically checked whether bar is installed, 
> and if not then bar is also installed at the same time. I remember having 
> seen packages which do so, but I can not figure out the mechanism
> 'Depends: bar' in the DESCRIPTION file does not solve the problem. Can anyone 
> help?
>
> A related question: How to check programmatically that a specific package is 
> loaded?
>
> Best regards
> Søren
>
>         [[alternative HTML version deleted]]
>
>
>
> ______________________________________________
> [email protected] 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.
>
>
>

______________________________________________
[email protected] 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.

Reply via email to