Skip to Main Content

Data entry and preparation

Defining variables

Before you enter your data, you need to define your variable names and types, i.e. you need to define what variables you will be using. You will do this in the Data Editor window, within the Variable View.

Name

  • Should not exceed 64 characters.
  • Start with a letter.
  • No symbols or spaces.

Type

  • Numeric is the default option.

Width

  • 8 is the default option.

Decimals

  • 2 is the default option.

Label

  • Used to provide a longer description of your variable.
  • This will be used in the output window.

Values

  • For naming categories of a nominal variable.
  • Click in the cell under the heading values.
  • In the boxes marked as Value, type in 1, 2, 3,…
  • In the boxes marked as Label type the relevant names of each value.

Missing

  • You can assign specific values to indicate missing values.

Columns

  • 8 is the default option.

Align

  • Right alignment is the default option.

Measure

  • Scale: for continuous data measured at interval or ratio level of measurement.
  • Nominal: for variables that consist of categories.
  • Ordinal: for data that involves rankings or ordered values.

Role

  • Input is the default option.

 

Shortcuts

Copying variable definition attributes

  1. In Variable View, click on the cell that has the attribute you want to copy.
  2. From the menu, click on Edit\Copy.
  3. Click on the same attribute cell for the variable you wish to apply it to.
  4. Click on Edit\Paste.

 

Setting up new variables all with the same attributes 

  1. Define the attributes of the first variable.
  2. Highlight the variable row.
  3. From the menu, select Edit\Copy.
  4. Click on the row number of the next empty row.
  5. Select Edit\Paste variables.
  6. Enter the number additional variables you want to add, including the prefix you want to use and the number the new variables will start on.

Data entry using Excel

Data files can be prepared in Excel and them imported into SPSS for analysis. This can be particularly helpful if you have employed survey software (e.g. Qualtrics) to collect your data.

  1. Set up variable names in Excel, using the first row.
  2. Enter data for each case. When you have finished, close the Excel document.
  3. In SPSS, click on File\Open\Data and choose Excel as File type. Click Open.
  4. Make sure there is a tick in the box ‘Read variable names from the first row of data’.
  5. Choose File\Save as. Make sure that the Save as Type is set at SPSS statistics (.sav).
  6. You’ll need to define each of the Labels, Values and Measure information for your variables.