2.3 Importing SPSS Files

SPSS files can be loaded using the foreign package. All SPSS files for this course are available for download here.

# Install the package, run this only once
install.packages("foreign")

# Load the `foreign` library
library(foreign)

# Read the SPSS data
df <- read.spss("sesam2.sav",
                     to.data.frame = TRUE)