Another option in Splus 5 is to have a text file
called .S.init in your home (login) directory.
For this example it would just contain the line:
library(MASS)
According to the "green book" (Chambers, 1998, pg121, point 6)
the initialization sequence of S will always run the commands
in this file. However in Splus 5.1 for HP-UX I find this only
works if I start Splus from my home direectory.
Has anyone else experienced this problem or is it specific to
my installation ? I thought that .S.init was a great idea
and will be sad if it does not work as I thought it should.
Regards, Andrew
-----Original Message-----
From: ROGER NGOUENET [mailto:r.f.ngouenet@usa.net]
Sent: Tuesday, November 28, 2000 5:34 PM
To: Martin H. H. Stevens; Mailing List S+
Subject: Re: [[S] loading libraries]
To automatically perform actions when you start S-PLUS, create a .First.
For example:
.First <- function(){
library(MASS) # I think mass is in upper case ...
}
You can view a complete help file by typing: ?.First or help(.First).
Cheers, Roger.
"Martin H. H. Stevens" <hstevens@rci.rutgers.edu> wrote:
I have recently discovered the joys of the extra libraries in S-plus
(e.g., mass, hmisc), and I have been liberated! I, and I am sure
COUNTLESS others, are deeply indebted to the authors of these fabulous
tools.
I would like to load some libraries every time I start s-plus. How do I
automate that?
Many thanks,
Henry
--
Dr. M. Henry H. Stevens
Postdoctoral Associate
Department of Ecology, Evolution, & Natural Resources
14 College Farm Road
Cook College, Rutgers University
New Brunswick, NJ 08901-8551
email: hstevens@rci.rutgers.edu
phone: 732-932-9631
fax: 732-932-8746
---------------------------------------------------------------------
This message was distributed by s-news@lists.biostat.wustl.edu. To
unsubscribe send e-mail to s-news-request@lists.biostat.wustl.edu with
the BODY of the message: unsubscribe s-news
____________________________________________________________________
Get free email and a permanent address at http://www.netaddress.com/?N=1
---------------------------------------------------------------------
This message was distributed by s-news@lists.biostat.wustl.edu. To
unsubscribe send e-mail to s-news-request@lists.biostat.wustl.edu with
the BODY of the message: unsubscribe s-news
**********************************************************************
Any information in this communication which is confidential must not
be disclosed to others without our consent. Such consent is not required
where the information is publicly available and intended for onward
distribution. If the information is confidential and if you are not the
intended recipient, you are not authorised to and must not disclose,
copy, distribute, or retain this message or any part of it. You are
requested to return this message to the sender immediately.
Due to the electronic nature of e-mail, there is a risk that the
information contained in this message has been modified.
Consequently E D & F Man can accept no responsibility or
liability as to the completeness or accuracy of the information.
**********************************************************************
|