[R] Opening SAS file using read.sas7bdat() function in sas7bdat library.

Duncan Murdoch murdoch.duncan at gmail.com
Mon Oct 29 20:04:44 CET 2012


On 29/10/2012 2:54 PM, Marc Schwartz wrote:
> On Oct 29, 2012, at 1:28 PM, Praveen Surendran <praveen.surendran at ucd.ie> wrote:
>
> > Hi,
> >
> >
> >
> > I have a file in .sas7bdat format. I tried to open this file using
> > read.sas7bdat() function.
> >
> > This gave me an error - "Error in read.sas7bdat("bnp_genetic.sas7bdat") :
> >
> >  unknown host X64_7PRO".
> >
> > Could someone tell me what this error means?
> >
> > Thank you,
> >
> > Praveen.
>
>
> More than likely, a similar problem as in this recent thread, but for 64 bit, rather than 32 bit:
>
>    https://stat.ethz.ch/pipermail/r-help/2012-October/325257.html

If you look at the source for the function, it checks the "SAS_host" 
against a known list, containing

# Host systems known to work
KNOWNHOST <- c("WIN_PRO", "WIN_NT", "WIN_NTSV", "WIN_SRV",
                "WIN_ASRV", "XP_PRO", "XP_HOME", "NET_ASRV",
                "NET_DSRV", "NET_SRV", "WIN_98", "W32_VSPR",
                "WIN", "WIN_95", "X64_VSPR", "X64_ESRV")

Praveen's host is not in that list, so the package author has never 
tested it.   But nothing else in the code appears to depend on the host, 
so it's a good guess that adding another host string to that list (or 
changing the error to a warning) will make it work properly.

Duncan Murdoch




More information about the R-help mailing list