[R] sas.get problem

Marc Schwartz MSchwartz at medanalytics.com
Wed Oct 1 21:59:24 CEST 2003


On Wed, 2003-10-01 at 13:43, Marc Schwartz wrote:
> On Wed, 2003-10-01 at 13:23, Duncan Murdoch wrote:
> > On Wed, 01 Oct 2003 14:02:15 -0400, "Peter Flom" <flom at ndri.org> wrote
> > :
> > 
> > >When I try
> > >
> > > citypro <- sas.get('c:/ndri/cvar/data', member = 'citypro2')
> > >
> > >
> > >I get the following errors and warnings:
> > >
> > >
> > >'sas' is not recognized as an internal or external command,
> > >operable program or batch file.
> > 
> > That's an S-PLUS function rather than an R function, isn't it?  Does
> > some R package supply sas.get?
> > 
> > I believe the S-PLUS implementation requires that you have SAS
> > installed, and it looks like the error message is saying that you
> > don't.  But if you're using S-PLUS, you'd be better asking on the
> > s-news mailing list.
> > 
> > Duncan Murdoch
> 
> 
> Duncan,
> 
> sas.get() is in Frank Harrell's Hmisc package on CRAN (recently
> available there) for R.
> 
> I would defer to Frank's comments here, but reading the .PDF file that
> is on CRAN, it does confirm that one must be able to run SAS in order to
> use sas.get():
> 
> "Note
> 
> You must be able to run SAS (by typing sas) on your system. If the S
> command !sas does not start SAS, then this function cannot work."
> 
> HTH,
> 
> Marc Schwartz


A quick follow up. I installed Frank's Hmisc under R 1.8.0 beta. If
Hmisc is not attached (ie. library(Hmisc)), you get:

> citypro <- sas.get('c:/ndri/cvar/data', member = 'citypro2')
Error: couldn't find function "sas.get"

which you would reasonably expect.

Thus, it seems more likely that Dr. Flom either does not have SAS on his
system or perhaps the SAS executable file (sas.exe? IIRC) is not in Dr.
Flom's 'PATH' on his system if SAS is installed.

HTH,

Marc




More information about the R-help mailing list