[R] Code Book from SPSS Data

Peter Maclean pmaclean2011 at yahoo.com
Sat Oct 26 22:37:00 CEST 2013


I do not have SPSS and I would like to create a code book in a data frame format using R. I am reading the SPSS file using "memisc package". The script is:
#Data for 2012 available at http://www.ark.ac.uk/nilt/datasets/
#Also attached
ibrary(memisc)
## change the working directory
getwd()
setwd('')
data <- spss.portable.file("NILT12w2.por")
Get names
names(data) 
#Get Variable Lebels
des <- as.data.frame(description(data))
#Descriptive Statistics & Code Book
#Results are very long for printing
codebook(data)
#How could I extract a codebook (without Summary statistics for printing)?



Peter Maclean
Department of Economics
UDSM
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: NILT12w2.por
URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20131026/ff4aac4c/attachment-0001.pl>


More information about the R-help mailing list