On Wed, Jun 29, 2011 at 8:05 PM, philippe preux <
[email protected]> wrote:
> Hi Matt,
> maybe the library() command would solve your problem.
>
> However, I take this opportunity to ask an other question related to
> installed packages:
> some packages are installed because I install.package'd them; however, I
> usually add the dep = TRUE option, so that some other packages are installed
> because of the dependencies. Once installed, I do not know of any way to
> distinguish the former from the latter; is there one?
> Now, moving my R installation to a new machine, I would like to re-install
> only those packages I installed by install.package(), with the dep = TRUE
> option. I feel, and fear, that if I install all the packages returned by
> library() with dep =TRUE option, packages that depend on those installed
> because they depend on those I installed by giving their name to
> install.package() will also be installed.
>
My guess is that if package A depends on B and B depends on C, that A and B
will be installed when install.package("A"), as B has to be working as well
- and it needs C to be working - so I would expect no difference in these
two approaches - except if dependencies are dropped in a newer version.
Cheers,
Rainer
>
> Now, my workaround is to keep the history of the install.package() command
> I invoked. Defining a function that does the same thing as
> install.packages(), while logging the information in some file does the
> thing.
>
> Hope that helps,
>
> Philippe
>
>
> On 29/06/2011 19:48, Matt Curcio wrote:
>
>> Greetings All,
>> I would like to find out which R packages I have on my machine and
>> transfer that set of packages to a new machine. I have investigated
>> the command 'installed.packages' and got a partial list but this is
>> not comprehensive. (!?!) The partial list does not include the
>> libraries that I do not normally load on start-up.
>> Any suggestions?
>>
>> Conversely, once I have found the complete list can I use
>> 'install.package' to batch install all the packages to another
>> computer?
>> Cheers,
>> M
>>
>>
>>
> ______________________________**_________________
> [email protected] mailing list
> https://stat.ethz.ch/mailman/**listinfo/r-sig-teaching<https://stat.ethz.ch/mailman/listinfo/r-sig-teaching>
>
--
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology,
UCT), Dipl. Phys. (Germany)
Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa
Tel : +33 - (0)9 53 10 27 44
Cell: +33 - (0)6 85 62 59 98
Fax (F): +33 - (0)9 58 10 27 44
Fax (D): +49 - (0)3 21 21 25 22 44
email: [email protected]
Skype: RMkrug
[[alternative HTML version deleted]]
_______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-sig-teaching