Hi, I'm a new R users (although I have a little experience with S+). I am using the latest version (1.4.1) of R on a Windows 2000 system. I have obtained several of the additional R packages ("modules") and would like to know how to permanently install them. What I am after is something similar to the following in S+> .First <- function() { module("module_name") }This loads a given module at the start of the S+ session so that it is always available. I'm sure there must be a way to do this in R, but I have not been able to find it in the documentation or on the FAQ web site. Thanks, Chris Edge -------------- next part -------------- An HTML attachment was scrubbed... URL: https://stat.ethz.ch/pipermail/r-help/attachments/20020218/99f59d2c/attachment.html
On Mon, 18 Feb 2002, Christopher W. Edge wrote: %Hi, % %I'm a new R users (although I have a little experience with S+). I am using the latest version (1.4.1) of R on a Windows 2000 system. % %%I have obtained several of the additional R packages ("modules") and would %like to know how to permanently install them. What I am after is something I don't think that it is about installation the packages are installed it is about loading them, so the issue is about performance and I think that loading libraries when you need them and unloading them afterwards is the better approach %similar to the following in S+ % %> .First <- function() { module("module_name") } % %%This loads a given module at the start of the S+ session so that it is always %available. I'm sure there must be a way to do this in R, but I have not been %able to find it in the documentation or on the FAQ web site. something like> .First<-function () library(geoR) >then after quitting and invoking R again> search()[1] ".GlobalEnv" "package:geoR" "Autoloads" "package:base">JN % %Thanks, % %Chris Edge % *********************************************************************** Jens Nieschulze Institute for Forest Biometrics & Phone: ++49-551-39-12107 Applied Computer Science Fax : ++49-551-39-3465 Buesgenweg 4 37077 Goettingen E-mail: jniesch at uni-forst.gwdg.de GERMANY http://www.uni-forst.gwdg.de/~jniesch -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Dear Christopher: At 10:30 PM 2/18/2002 -0500, Christopher W. Edge wrote:>I'm a new R users (although I have a little experience with S+). I am >using the latest version (1.4.1) of R on a Windows 2000 system. > >I have obtained several of the additional R packages ("modules") and would >like to know how to permanently install them. What I am after is >something similar to the following in S+ > > > .First <- function() { module("module_name") } > >This loads a given module at the start of the S+ session so that it is >always available. I'm sure there must be a way to do this in R, but I >have not been able to find it in the documentation or on the FAQ web site. >There are several ways to load packages, or execute other commands, at startup. On a single-user Windows system, probably the easiest solution is to edit the Rprofile file in the etc subdirectory, adding library commands to the file. Because there's some overhead, it's only sensible to do this if you want the libraries to be available continuously. I hope that this helps, John -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._