Skip to content
Prev 20975 / 63424 Next

install.packages() does not warn when 'lib' arg is missing on Linux or Windows

Hello,

Man page for 'install.packages' says that if the 'lib' arg is missing,
then it "defaults to '.libPaths()[1]' with a warning".
But, given the 'install.packages' source code, it seems that this warning
is issued only when 'length(.libPaths()) > 1'.
So typically, this warning will appear on Mac OS X but not on a Linux
or Windows systems with default settings.
On my Mac OS X system:

     > .libPaths()
    [1] "/Users/biocbuild/Library/R/Library"
    [2] "/Library/Frameworks/R.Framework/Versions/2.3/Resources/library"

but on my Linux system:

     > .libPaths()
    [1] "/home/hpages/arch/x86_64/R-2.3.1/library"

I'm using R-2.3.1 on both systems.
Best,


H.