Part II Re: [R] read.ssd {foreign} (Reading a permanent SAS d ataset into an R data frame)

Stephen Arthur sarthur67 at yahoo.com
Fri Dec 20 21:28:02 CET 2002


Thomas,

The SAS data set I PROC CPORTed is [9] the result is
[10].  I PROC CIMPORTed  [10] back to its orginal
state [9], and it worked. 

So the SAS people think that the error is not with the
SAS XPORT file, but with R trying to load a text SAS
XPORT file, when it should be loading the SAS XPORT
file in binary format?  Is this a problem?

Here is a list of my commands to R:

>
list.files("J:\\QM\\Reports\\Sarthur\\SAS_Application\\SAS_Data_Sets")

[1]...
[9] "comm_acq_inj.sas7bdat"
[10] "cport.xpt"       
...[66]

> library(foreign)

>
read.xport("J:\\QM\\Reports\\Sarthur\\SAS_Application\\SAS_Data_Sets\\cport.xpt")
Error in lookup.xport(file) : File not in SAS transfer
format

--- Thomas Lumley <tlumley at u.washington.edu> wrote:
> 
> That means R can't find the file.  Are you sure it's
> there?
> 
> 	-thomas
> 

I am sure that the "cport.xpt" file is in the correct
directory.

Thanks for your assistance in this matter,

Stephen




More information about the R-help mailing list