Displaying 20 results from an estimated 2000 matches similar to: "Reading .sav (SPSS) files."
2010 May 18
1
Getting dates in an SPSS file in right format.
Dear all,
I am trying to read an SPSS file into a data frame in R using method
read.spss(),
sample <- read.spss(file.name,to.data.frame=TRUE)
But dates in the data.frame ''sample'' are coming as integers and not in the
actual date format given in the SPSS file.
Appreciate if anyone can help me to solve this problem.
Kind Regards,
Praveen Surendran
2G, Complex
2009 Oct 22
2
Replacing multiple elements in a vector !
Hi,
I have a vector with elements
rs.id=c(''rs100'',''rs101'',''rs102'',''rs103'')
And a dataframe ''snp.id''
1 SNP_100 rs100
2 SNP_101 rs101
3 SNP_102 rs102
4 SNP_103 rs103
Task is to replace
2007 Feb 16
1
SPSS and library(foreign)
Hi,
I have a valid SPSS .sav file (which I can open happily in SPSS v11 on
Windows XP).
Opening it in R2.41 on Linux we get this message :-
> HSE3023 <- read.spss("HSE.sav")
Error in read.spss("HSE.sav") :
error reading system-file header
In addition: Warning message: HSE.sav:
Variable X234 indicates variable label of invalid length 256
Now variable X234 has indeed a
2010 Jun 18
1
Read SPSS v 18 .sav file
Hi,
I repeatedly get an error when trying to read an SPSS v. 18 .sav file into R.
> require(foreign)
Loading required package: foreign
> femaleSPSS.dat <- read.spss("female-04-02-2010.sav")
Warning message:
In read.spss("female-04-02-2010.sav") :
female-04-02-2010.sav: Unrecognized record type 7, subtype 18 encountered in system file
>
However, read.spss works
2010 Jul 16
1
re ading SPSS .sav files (PR#13509)
Sir/Madam,
Installed in my computer is the Version 2.9.1(2009-06-26) of R. I have a
SPSS.sav file produced by SPSS Version 17.
>install.('foreign')
>library(foreign)
<- read.spss("f:/sme.sav",use.value.labels=FALSE)
Warning message:
In read.spss("f:/sme.sav", use.value.labels = FALSE) :
f:/sme.sav: Unrecognized record type 7, subtype 18
2009 Feb 07
2
reading SPSS .sav files (PR#13509)
Full_Name: Roger Newton
Version: 2.8.1
OS: windows 2000
Submission from: (NULL) (80.176.228.157)
I have an elderly version of SPSS (version 11) which I still use. R Version
2.6.1 would, and still will, read SPSS *.sav files produced by SPSS version 11.
R version 2.8.1 which I installed two days ago (05/02/09) reports an error and
shuts down when trying to read SPSS version 11 *.sav files using
2009 Oct 14
2
Getting indeices of intersecting elements.
Hi,
Is there a command to get the indices of intersecting elements of two
vectors as intersect() will give the elements and not its indices.
Thanks in advance.
Praveen Surendran
School of Medicine and Medical Sciences
University College Dublin
Belfield, Dublin 4
Ireland.
[[alternative HTML version deleted]]
2011 Jul 01
1
como levantar en r una base en .sav (spss).
Hola Estimadas y Estimados,
Alguno podrá enseñarme, en caso de que sea posible, como lvantar desde R una
base (o variables) que estén en formato .sav (SPSS).
Hay que aplicar una librería distinta library (RODBC)? ,que es la que llamo
para levantar bases de un servidor SQL.
Espero que esten bien.
Muchas gracias.
Saludos cordiales,
Juan Manuel.
Argentina - Ministero de Salud de la Nación.
2003 Dec 19
1
read.spss warning message with 12.0 sav files
useRs,
Don't know if this requires a bug report, but
using the read.spss function on files written by the
new SPSS 12.0 produces the following warning message:
Warning message:
C:\data\spss.sav: Unrecognized record type 7, subtype 13 encountered in
system file.
The data files appear to be read correctly. The warning likely results
from changes to the file format due to SPSS increasing
2006 Apr 16
3
Reading SPSS .sav files
Greetings,
How to I read in SPSS .sav files into R.
Thank you.
David
=====================================
David Kaplan, PhD
Professor of Education
School of Education
University of Delaware
Newark DE 19716
Voice: 302-831-8696
Fax: 302-831-4110
email: mailto:dkaplan at udel.edu
Homepage:
2004 Jul 26
3
Read SPSS data (*.sav) in R 1.8.0 (ok) and R1.9.1(error)
Hallo!
I read SPSS data in the following way:
library(Hmisc)
library(foreign)
dat<-spss.get("surv_abb.sav")
In R1.9.1 I got the message:
"Error in all(arg == choices) : Object "typeDate" not
found"
In R1.8.0 the same script works fine.
Does anybody know a possibilty to read a SPSS file
under R1.9.1?
Thanks!
Karl
2009 Mar 11
1
Is this a documentation bug? Spss dates import
Hello R-user
bug seekers are needed!
In order to perform these simple tasks you have to use a copy of SPSS
and obviously R.
The problem is that date conversion of data coming from SPSS
gives wrong results, if we follow ?as.POSIXct
## SPSS dates (R-help 2006-02-17)
z <- c(10485849600, 10477641600, 10561104000, 10562745600)
as.Date(as.POSIXct(z, origin="1582-10-14",
2011 Mar 30
1
sampling design runs with no errors but returns empty data set
Dear colleagues,
I'm working with the 2008 Canada Election Studies (http://www.queensu.ca/cora/_files/_CES/CES2008.sav.zip), trying to construct a weighted national sample using the survey package.
Three weights are included in the national survey (a household weight, a provincial weight and a national weight which is a product of the first two).
In the following code I removed variables with
2007 Feb 09
1
Using variable names in for loops - Generating plots semi-automatically from a series of variables Partly solved
Hi,
This code is trying to produce a series of graphics files, with plots
of male and female disease rates by age, one plot per disease. The
dataframe contains a variable 'Age' and a set of variables called
'Male_CVD, Female_CVD,Male_RTA,Female_RTA, and so on. For each
disease, I want to pull out the column of data containing the word
'Male' and plot this against age, and then
2010 Jul 28
1
Help with specifiying random effects in lmer - psychology experiment
<!-- /* Font Definitions */ @font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4; mso-font-charset:0; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:-1610611985 1107304683 0 0 159 0;} @font-face {font-family:Calibri; panose-1:2 15 5 2 2 2 4 3 2 4; mso-font-charset:0; mso-generic-font-family:swiss; mso-font-pitch:variable;
2008 Dec 14
1
re ad.spss (foreign) conflict with SPSS 17 files.
SPSS seems to have changed its default datafile format, resulting in issues
for read.spss(). In Windows this results in a warning, in Debian the import
completely fails:
Debian (R version 2.8.0 (2008-10-20) i486-pc-linux-gnu, foreign_0.8-29)
> read.spss("/home/jeroen/samples/Tomato.sav")
Error in iconv(names(rval), cp, "") :
unsupported conversion from 'CP65001'
2009 Jul 08
5
R regular expression to extract words with the query string.
Hi,
Is there a way in R to get the string which matches the expression, where
the expression is a substring of the parent string.
Lets say, I have $i <- "transcript:ENST0000112334 pid:ENSP000012345"
What I need is the string "pid:ENSP000012345" from $i using the query
"ENSP".
Appreciate your comments.
Praveen Surendran
School of Medicine and
2007 Apr 05
1
read.spss (package foreign) and SPSS 15.0 files
Hello,
does anyone have experience with reading SPSS Version 15.0 files into R (version 2.4.1, WinXP)?
I have long been sucessfully reading SPSS files with read.spss from the wonderful foreign package, but somehow after upgrading from SPSS14 to SPSS15 I seem to have problems.
Trying a simple example, where test.sav is a SPSS 15.0 data file consisting of x1=c(1,2,3) and
2009 Jan 07
1
Importing data from SPSS with Arabic encoding
Dear R-users,
I'm facing a problem with the import of data in R. I have a sav file that, I presume, uses some Arabic encoding (but I don't know which one) and I would like to read it with R. When I use the function read.spss (I also tried spss.get(Hmisc)), I get the following message:
> read.spss("Hhld.sav")
Erreur dans read.spss("Hhld.sav") :
erreur ? la lecture
2003 Aug 10
1
read.spss doesn't work anymore
A couple of months ago, probably using an older version of R, R used to
run the following code just fine:
library("foreign")
data.exp1 <- as.data.frame(read.spss("dataDef.sav"))
Issuing the same commands now (after starting R using --vanilla), gives
me the following behavior:
> library("foreign")
> x <- read.spss("dataDef.sav")
Error