Hello,
at the moment i am using spss as my favorite statistics
package, but R seems an atractive alternative. Thanks to
the R-Team for their great work! (I use R on my windows98
laptop,P II and 64MB Ram).
I have a big(?) data set, containing more than 470
variables and 3200 cases (size: 2.5MB). Whenever I use the
command 'read.spss' (foreign-library), I got the the
following warning massages:
------------------
Warning messages:
1: d:/s3000.sav: File contains duplicate label for value
0.5 for variable V50.
2: d:/s3000.sav: File contains duplicate label for value 1
for variable V50.
3: d:/s3000.sav: File contains duplicate label for value
0.5 for variable V63.
4: d:/s3000.sav: File contains duplicate label for value 1
for variable V63.
[...]
------------------
How do I interpret these warnings?
My next step was trying to save the spss-data as an ascii-
file (separated by tabs) and using the R command
'read.table' -- R crashes.
My third step was saving the spss-data as an ascii-file (in
fixed format) and using again 'read.table'. I got:
------------------
Error in read.table("d:/fixed.dat", header = T) :
all rows must have the same length.
------------------
What went wrong?
TIA
Bernd
--
Bernd Wei? (bernd.weiss at epost.de)
PGP Key ID: 0x4117206F
PGP FP: 08B2 09CD 7192 526D 93FD 2070 53DB 7C4F 4117 206F
www.pgpi.org
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
spss-data import
2 messages · Bernd Weiss, Peter Malewski
On Sat, Jun 09, 2001 at 03:57:29PM +0200, Bernd Weiss wrote:
Error in read.table("d:/fixed.dat", header = T) :
all rows must have the same length.
Look at your exported data-file an you'll see how you have to read
it. My standard way to read excel csv files is:
Akten1998.1 <- read.csv("File.csv",sep=";",as.is=T,dec=",")
But this depends on several cirumstances. E.g. on some windows
platforms the "dec" is set to "." (I think you can set this with spss).
Spss often uses tabs as seperators (depends how you export your file
in spss) so
sep="\t"
should work.
My experience with read.spss:
1. Works often with spss version 6-9...
2. ...mut sometimes crash with these files (I have at least one file
that is not readable).
3. Don't work with spss version 10 files. Even spss 6 cannot read
them.
So:
while (!success)
exoport from spss with other options
look at the file
specify read.xxx parameter
Peter
P.Malewski, Limmerstr.47, 30451 Hannover, 0511-2135008 At work: http://www.MH-Hannover.de 0511 532 3194 / Fax: 0511 532 3190, P.Malewski at tu-bs.de, peter.malewski at gmx.de, malewski.peter at mh-hannover.de. -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._