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

Matt Shotwell matt.shotwell at Vanderbilt.Edu
Tue Oct 30 15:11:19 CET 2012


Thanks for the helpful comments from others.

The KNOWNHOST variable lists the types of file that are known to work
with the read.sas7bdat function. It's likely that most files written on
Windows platforms will work, even if not listed in KNOWNHOST. If you're
feeling experimental, you might just comment the lines that test against
the KNOWNHOST list.

Unfortunately, it appears that the file formatting depends on the system
where is was originally written. The hypothesis is that sas7bdat files
were originally no more than a memory dump of a C structure, or similar.
Because C structures may be laid out differently by different compilers
(i.e., on different platforms), this may have led to the difficulty
apparent here.

Regards,
Matt




More information about the R-help mailing list