Skip to content
Prev 173389 / 398506 Next

Is this a documentation bug? Spss dates import

Luca,
I ran your code using SPSS 17.0 and R 2.8.1.
I found that the correct date was returned in R using this code:

test.df$newdate <- as.Date(as.POSIXct(test.df$mydate , origin="1582-10-14"))  

Also note that SPSS 17.0 is case sensitive in storing variable names, so the
R code in your post needs to be changed from "test.df$MYDATE" to
"test.df$mydate" to match your use of lowercase in the SPSS syntax. 

Harold
Luca Braglia wrote: