[R] change in read.spss, package foreing?

Thomas Lumley tlumley at u.washington.edu
Fri Sep 9 17:36:22 CEST 2005


On Fri, 9 Sep 2005, Heinz Tuechler wrote:

> Dear All,
>
> it seems to me that the function read.spss of package foreign changed its
> behaviour regarding factors. I noted that in version 0.8-8 variables with
> value labels in SPSS were transformed in factors with the labels in
> alphabetic order.

No, they were in the order they were stored in the file

> In version 0.8-10 they seem to be ordered preserving the order
> corresponding to their numerical codes in SPSS.

They are now in the opposite order to their order in the file, which 
appears to be numerical order in SPSS (we can't be sure that this is 
always true since the file format is undocumented).

> However I could not find a description of this supposed change.

It's in the ChangeLog file in the foreign package.


 	-thomas

Thomas Lumley			Assoc. Professor, Biostatistics
tlumley at u.washington.edu	University of Washington, Seattle




More information about the R-help mailing list