My goal is to define a single path which R
will use for installing and searching for libraries. I read that this can be done by changing the Rprofile.site
file in the R
installation path. I tried two commands there:
.libPaths("D:/RLibrary")
.Library.site <- file.path("D:/RLibrary")
of which I do not fully understand the difference even after reading the help files.
However after starting R
, libraries are still looked for in two locations.
.libPaths()
[1] "D:/RLibrary" "C:/Program Files/R/R-3.3.1/library"
Why is this, and how do I change the library path to my desired path only?