[R] how to remove paths from where library() looks for packages

Henrique Dallazuanna wwwhsd at gmail.com
Thu Dec 27 11:23:07 CET 2007


Perhaps this:

.libPaths(unique(installed.packages()[,2]))

On 25/12/2007, Lynd Bacon <lbacon at lba.com> wrote:
> Greetings.  My current installation of R 2.6.1 on Unbuntu 7.10 ("Gutsy")
> is looking for packages in a directory that doesn't contain any:
>
>  > library()
> Warning message:
> In library() : library "/usr/lib/R/site-library" contains no packages
>
>  > .libPaths()
> [1] "/usr/local/lib/R/site-library" "/usr/lib/R/site-library"
> [3] "/usr/lib/R/library"
>
> I'd like to eliminate the path to the empty directory so I don't get
> this vexsome warning message.  Any and all suggestions will be greatly
> appreciated!
>
> Cheers,
>
> Lynd
>
> --
> _________________________________________
> Lynd Bacon
> Woodside CA USA GMT-08:00
>
> ______________________________________________
> R-help at r-project.org 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.
>


-- 
Henrique Dallazuanna
Curitiba-Paraná-Brasil
25° 25' 40" S 49° 16' 22" O



More information about the R-help mailing list