Skip navigation
ICPSR Gateway | GovInfo Gateway | © SSRIC Glossary

UMBC Workshops - sponsored by CIRC (the Center for Interdisciplinary Research and Consulting)

Before you Begin

The first thing you should know about SPSS is that it is NOT a wordprocessing or spreadsheet program. It is a tool for interpreting rectangular data, and is based on command line programming. When data in files are arranged in rows and columns, it is called cases-by-variables, or rectangular data files.

Furthermore, while you don't need to understand statistical terms, tests, and equations to use SPSS, the results will mean little to you without that knowledge.

Types of files extensions you may encouter and what they mean (roughly):
  • SPSS portable (*.por): This format can be read by versions of SPSS on other operating systems (for example, Macintosh or UNIX);
  • SPSS (*.sav): SPSS format. If you can find one of these to use you are usually in good shape. When you create data sets of your own you'll be saving files in the .sav format;
  • Tab-delimited (*.dat): Most data files you download have some sort of delimination, e.g., tab, comma, space. Sometimes it's easier to import this sort of data into Microsoft Excel before importing into SPSS;
  • SPSS (*.sps): This file extension denotes a syntax file. Hint: you don't open a syntax file, you run it. Trust me, this bit of knowledge will keep you from tearing your hair out. You run syntax files to read raw data (*.dat files) into SPSS;
  • Other files: Such as Excel (*.xls) and dBase (*.dbf).
Creating & importing a new data file

For this exercise I have created a data file in Excel with thirty students' test scores (idea from Carol Walker at ISU). I have left out several steps that should be fairly obvious to anyone who uses Windows on a regular basis.
  1. Download the sample file (iqtests.xls) Excel Spreadsheet--I suggest saving it to the desktop
    • When you view the file in Excel you can see that it is composed of seven columns: id, gender, age, school, IQ, math, lang and opinion. You can also see that some variables, gender for instance, are represented by numbers. You'll be coding those variables once you import this file into SPSS
  • Close the Excel file
  • Open SPSS
    • a window will launch giving you several options. For now, close that window by clicking Cancel
  • File > Open > Data
  • Make sure you are in the folder to which you saved the Excel file. Choose File of type (*.xls) to view Excel files and select the file iqtests.xls
  • Click OK and the data opens in the Data Editor Before you begin manipulating data, take a look at the lower left corner of your screen. You'll see two file tabs, "Data View" and "Variable View." The Data View shows variable names and data values, and the Variable View shows variables and their definitions. The Variable View is fairly new to SPSS, and it's very handy.

    Making changes in the Variable View
      Editing Labels
    1. Click the Variable View tab
    2. Click the cell in which the math row intersects with the Label column
    3. Type "Math Exam" in that column
    4. Repeat to add other labels
      Editing Values
    1. Click the Variables View tab
    2. Click the cell in which the gender row intersects with the Value column
    3. Click the grey square with the elipse (...)
    4. Type "1" in the Value box and hit Tab
    5. Type "Female" in the Value Label box and click Add
    6. Repeat for school and Opinion of own IQ
      Editing Measure
    1. Click the Variables View tab
    2. Click the cell in which the opinion row intersects with the Measure column
    3. Choose Ordinal from the pull-down menu
      Note: Measure Values
    • Scale: represents discrete or continuous values along a range, e.g., age, iq, math, and lang are all scale values;
    • *Ordinal Variable: A measurement that allows a sample of individuals to be ranked with respect to some characteristic but where differences at different points of the scale are not necessarily equivalent, e.g., Opinion of own IQ
    • *Nominal Variable, aka Categorical variable: a variable that gives the appropriate label of an observation after allocation to one of several possible categories, e.g., gender (1 OR 2), school
    Analyzing Data & Creating Output

    Now here's the real power of SPSS. This also where you need to have some knowledge of statistics to understand what your results mean. Let's forge ahead and do some data analysis on the IQ file.

    *Descriptive Statistics:A general term for methods of summarizing and tabulating data that make their main features more transparent.
    1. Analyze > Descriptive Statistics > Descriptives
    2. A "Descriptives" box will open; move items from one side to the other by highlighting the values and clicking the arrow button. Note: Ordinal variables won't make sense as general descriptives
    3. Click OK and SPSS generates an output screen. You can save this as output (*.spo). You can also copy and past the tables (and graphs) into a wordprocessing document. For now, leave your results and move to the next topic.
    1. Analyze > Descriptive Statistics > Frequencies
    2. Choose variables that will represent meaningfully as frequencies
    3. Click the Statistics button
    4. Choose "Median" and click continue
    5. Click the Charts button
    6. Choose a chart and click continue
    7. Click Paste...You've created a sytax (*.sps) file! --for more information on syntax files see below
    8. Run > All
    Working with Syntax Files

    Below are step by-step-instructions for using syntax files
    1. Make sure you know where the the data file(s) and SPSS syntax file are located;
    2. Start SPSS for Windows;
    3. File > Open > Syntax
    4. Choose the SPSS syntax file (probably beginning with SP) and click OK. The *.sps file will open on your screen;
    5. You need to make ONE change to the syntax file. Scroll down in the syntax file past the introductory notes to a line that begins either FILE HANDLE or DATA LIST FILE=. Whichever one of these you see, you will see a FILE='filename' statement. This is what you need to change. Within the single quotes (or after the = if there are no quotes), you must have the correct location for your data file.
      • E.g., DATA LIST FILE='d:\9774\d9774p1.dat'
    6. In older versions of SPSS the last line of your syntax file must be EXECUTE. (period included). Version 10.0.5 seems to work fine without it, but if you're using an older version make sure to include this command.
    7. Run > All
    8. If the operation was successful, you should see the newly labelled and imported data in the Newdata window (which should be chooseable from the task bar). Also, your Output window will display error messages if you have any errors in your syntax file.
    Other SPSS Guides on the Web *The Cambridge Dictionary of Statistics, by B.S. Everitt. Cambridge University Press, 1999.
  • Have Questions?
    Ask a Librarian

    Research Help

    Subject Guides

    Research Guides & Tutorials

    Ask a Librarian

    Contact a Subject Librarian

    Information Literacy

    Glossary of Library Terms

    Database Webinars