In SPSS, we usually work from 3 windows. These are
- the data editor window ;
- the syntax editor window ;
- the output viewer window .
SPSS’ main window is the data editor. This is the only window that's always open when we run SPSS. Although it's called “data editor”, we use it only for inspecting our data. We strongly recommend you
never edit data in the data editor.
The right way to edit data -and way faster too- is by using syntax, which we'll discuss in the next tutorial.
Right, let's now download and open bank.sav. We'll use it for walking you through the main parts of the data editor.
SPSS Data View & Variable View
An SPSS data file always has two tabs in the left bottom corner:
- Data View is where we inspect our actual data and
- Variable View is where we see additional information about our data.
You can switch between Data View and Variable View by
- clicking the tabs in the left bottom corner;
- using the Ctrl + t shortkey;
- double-clicking a variable name in Data View;
- double-clicking an outline number in Variable View.
Let's first take a close look at the main parts of the Data View tab. We'll then proceed with variable view.
SPSS Data View
The data editor has tabs for switching between Data View and Variable View. For now, make sure you're in Data View.
Columns of cells are called variables. Each variable has a unique name (“gender”) which is shown in the column header.
Rows of cells are called cases. Oftentimes, each respondent in a study is represented as a single case.
In SPSS, values refer to cell contents.
The status bar may give useful information on the data, for instance whether a WEIGHT, FILTER, SPLIT FILE or Unicode mode is in effect.
These are the main elements in Data View. Let's now switch to Variable View.
SPSS Variable View
In the left bottom corner we find tabs for switching between Variable View and Data View. For now, select Variable View.
In Variable View, variables are shown as rows of cells.
The first column shows the variable name for each variable.
The fifth column may or may not contain a variable label. This describes the exact meaning of each variable.
The sixth column shows value labels: descriptions of the meaning of one, many or all values that a variable may contain.
In short, Variable View does not show the data itself but, rather, information about the data. This is sometimes called “metadata” or “the codebook”. In SPSS, however, it's called the dictionary.
This is important to know because you may find commands like DISPLAY DICTIONARY or APPLY DICTIONARY in manuals. If you're familiar with syntax, running
DISPLAY DICTIONARY.
creates the output shown below: dictionary information as seen in variable view.
Variable View - Value Labels
For some variables, it's immediately clear what their values mean: a value of € 2500,- in a variable “gross monthly income” represents a gross monthly income of € 2500,-.
This is not always the case, however: answer categories for categorical variables are often represented by numbers -usually 1 through x. What these values represent is then stored in their value labels. Clicking the open value labels icon for education_type displays all value labels for this variable.
These value labels tell us that a person with a value of 1 on education_type indicates somebody who studied “Law”. In a similar vein, “Economy” is represented by a value of 2, and so on.
Dictionary Information in Data View
Thus far, we explained that SPSS’ Data Editor always has 2 tabs:
- Data View in which we inspect our actual data values and
- Variable View in which we find information about our data -dictionary information.
Little known by many SPSS users is that we can see some dictionary information in Data View too. Let's start off with value labels. Initially, we just see data values in Data View as shown below.
Now, if we click the value labels icon we'll see value labels instead of data values in data view.
So this allows you to look up what your data mean without having to switch between Data View and Variable View. Perhaps even more useful: place your mouse pointer on a variable name in Data View without clicking it. Now a yellow box with a lot of dictionary information pops up for a few seconds.
Starting from SPSS version 22, icons next to variable names tell us something about our variable types, formats and measurement levels -if correctly set, that is.
Final Notes
So basically, “data” consist of 2 components:
- data values which we see in Data View and
- dictionary information about our data in Variable View.
We can save the contents of the Data Editor as an SPSS data file or .sav file. If we do so, the resulting file always contains everything in both Data View and Variable view.
Let's reemphasize that you should never -under no circumstances- edit anything manually in either Data View or Variable View. This is perhaps the single worst SPSS practice. And yes, I know. Many SPSS users do this anyway. But most will sooner or later wish they hadn't.
The only sound way to edit your data or dictionary information is by syntax. So let's move on to our next tutorial: SPSS Syntax Introduction.
Thanks for reading.
THIS TUTORIAL HAS 91 COMMENTS:
By Lazarus Nweke on April 25th, 2023
Just very explanatory