[R-sig-Debian] setting R_LIBS
Dirk Eddelbuettel
edd at debian.org
Thu Dec 1 03:03:16 CET 2005
On 30 November 2005 at 16:44, Sebastian Luque wrote:
| I'm adding a private library tree in my home directory by adding this to
| my ~/.Renviron:
|
| R_LIBS="~/R/library:${R_LIBS}"
|
| so that once in R:
|
| R> cat(Sys.getenv("R_LIBS"), "\n")
| ~/R/library:/usr/local/lib/R/site-library:/usr/lib/R/site-library:/usr/lib/R/library
|
|
| Is this the best way to proceed?
Sure, after all it's in the FAQ (Q5.2) and documented under help(Startup).
I also use it at work on different system where
a) I may or may not have write permissions (Linux), or
b) want to keep my package directory outside of the versioned R
directory tree (Windoze).
So thumbs up from me. And under Debian, thanks to the useful expansion of
R_LIBS from pre-defined values, you get your own as well as the systems
directory in /usr/lib and /usr/local/lib.
The only other thing to consider would be a multi-user setting. You could
experiement with Renviron.site if you want to leave the conffile
/etc/R/Renviron alone. I have not tried this.
Dirk
--
Statistics: The (futile) attempt to offer certainty about uncertainty.
-- Roger Koenker, 'Dictionary of Received Ideas of Statistics'
More information about the R-SIG-Debian
mailing list