[R] Importing XPORT datasets into R

From: Michael Greene <mfgreene79_at_yahoo.com>
Date: Wed 24 Jan 2007 - 21:00:52 GMT


I'm experiencing a strange issue while attempting to import some XPORT formatted datasets created using SAS 9.3. I 'm using R 2.2.1 with a recently downloaded version of the "foreign" package, although I don't have the version for that handy.

I have been able to load some of the XPORT datasets, however when I increase to the entire dataset, I get the following error:

"Error in lookup.xport(file) : file not in SAS transfer format"

I am trying to import a dataset of roughly 1000 observations with about 600 variables. If I restrict the dataset somewhat and allow only 300 variables, the import appears to succeed without error. I have not seen a note in the documentation anywhere about the maximum number of variables for a dataset in R or for importing with read.xport, but I suspect this is the issue. For completeness, here is the start of the .xport file (it's all on one line):

HEADER RECORD*******LIBRARY HEADER RECORD!!!!!!!000000000000000000000000000000  SAS     SAS     SASLIB  9.1     SunOS

If anyone has any insights into this, I would greatly appreciate it. Thanks!

Mike Greene

        [[alternative HTML version deleted]]

R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu Jan 25 16:04:09 2007

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Thu 25 Jan 2007 - 05:30:29 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.