introduction to spss 07jan2014 - arizona stateeagle/spss/spssintro.pdf · introduction to ibm spss...
Post on 06-Feb-2018
295 Views
Preview:
TRANSCRIPT
Revised January 7, 2014 Page 1 of 14
Arizona State University College of Health Solutions
College of Nursing and Health Innovation
Introduction to IBM SPSS Statistics
Edward A. Greenberg, PhD Director, Data Lab
CONTENTS PAGE
About This Document 2
What is SPSS? 2
SPSS Help and Other Resources 2
SPSS Availability 3
Downloading or Running SPSS via MyApps 4
Windows Used Within SPSS 4
Basic Steps in Data Analysis 5
Detailed Steps in Data Analysis 5
The SPSS Data Editor 6
Types of Variables in SPSS 7
Variable Attributes in SPSS 7
Missing Values 8
Opening and Saving Files 8
Running SPSS Procedures 9
Saving and Modifying Output 10
Pivot Tables 11
Exporting SPSS Output to Other Applications 11
Data Transformations 11
Restructuring Data 12
Working with Subsets of Your Data 13
SPSS File Types and Compatibility among Versions 13
Setting SPSS Options 14 USEFUL LINKS
ASU Online Applications (MyApps) https://myapps.asu.edu (ASURITE login required) IBM SPSS home page: http://www‐01.ibm.com/software/analytics/spss/ SPSS Online Workshop (CMU): http://calcnet.mth.cmich.edu/org/spss/toc.htm Raynald's SPSS Tools: http://www.spsstools.net/
NOTE: Screen captures and other content in this document are based upon IBM SPSS Statistics Version
22 for Microsoft Windows 7.
Revised January 7, 2014 Page 2 of 14
ABOUT THIS DOCUMENT
This write‐up is intended as a resource guide for users of this software at ASU. It is not a tutorial. For
some available learning resources, see the “SPSS Help and Other Resources” section below.
WHAT IS SPSS?
IBM SPSS Statistics is a software package used for statistical analysis. SPSS is among
the most widely used programs for statistical analysis in social science and other
disciplines. In addition to statistical analysis, data management (case selection, file
reshaping, creating derived data) and data documentation (a metadata dictionary is
stored in the data file) are features of the base software.
SPSS HELP AND OTHER RESOURCES
The SPSS Help menu includes an excellent tutorial and other reference material.
IBM SPSS web site: http://www‐01.ibm.com/software/analytics/spss/
Many excellent books are available on SPSS, including some published by SPSS, Inc. You can find some of these at online booksellers or ask your friendly neighborhood bookstore.
Tutorial videos (in Flash format) are available from Central Michigan University at
http://calcnet.mth.cmich.edu/org/spss/toc.htm .
Raynald Levesque maintains an excellent SPSS‐related web site with many helpful resources at http://www.spsstools.net/ .
The Data Lab can help you with SPSS: NHI1 461, CONHISTAT@ASU.EDU, (602) 496‐DATA
Revised January 7, 2014 Page 3 of 14
SPSS AVAILABILITY1
SPSS is available to ASU faculty, staff and students through a campus licensing plan. The rules regarding
how this software can be used have changed. Here is a summary of the current provisions.
SPSS Software Versions ASU is licensed to use SPSS 20, 21, and 22. SPSS 19 was listed as end‐
of‐life early in 2013 and is no longer available. Installed copies of SPSS
19 must be upgraded to one of the other 3 versions. Versions 21 and
22 will be made available on MyApps (for download and virtual
access). For those who need to download SPSS 20, please contact
software@asu.edu for access to the software.
ASU Owned Systems (used by
faculty and students for
teaching and research only)
An unlimited number of licenses are available to install onto ASU
owned systems. Software can be licensed using the main license
manager (if on a wired network) or by requesting a stand‐alone
authorization code for systems that will not be on the ASU network.
Computers in faculty offices and in the NHI1 299 computer lab include
SPSS software as part of their standard system image.
Personal Systems Owned by
Faculty
ASU faculty can download SPSS from MyApps and install it on their
Windows or Mac OS computer. The software needs to be activated
each year; a license code must be requested from software@asu.edu.
Personal Systems Owned by
Students
A limited number of SPSS licenses for students to install SPSS onto
their personal system are available. These licenses expire at the end
of the class. For faculty who are teaching classes that use SPSS, if you
would like to make available some licenses to your students to install
and use the software, please email software@asu.edu the class name,
line number, semester session (A, B, or C) and the number of licenses
you would need. A specific authorization code will be set up for you.
As an alternative to installing the software, students can run the
software via the web from the MyApps website using the Citrix client.
Administrative Installs (not
used for research or teaching)
For ASU staff (not faculty) that need to use SPSS for daily business, a
small subset of SPSS Base licenses is available. There are 15
concurrent licenses available to use at ASU. These are on a separate
license manager. There is a cost associated with using the software
for administrative staff. To request an admin license for SPSS and
cost information, please email software@asu.edu.
ASU UTO Computing Sites DPC Information Commons (UCENT lower level) and other ASU
computing sites have access to SPSS via MyApps (see below). See
http://help.asu.edu/ for site locations and schedules.
1 Source: University Technology Office, December, 2013
Revised January 7, 2014 Page 4 of 14
DOWNLOADING OR RUNNING SPSS VIA MYAPPS: MyApps provides access to applications and software to ASU students, faculty, and staff. Some software, including SPSS, can be downloaded and installed on your computer. (See the previous SPSS Availability section of this document for restrictions.) MyApps also enables ASURITE account holders to run "online applications." Using this method (known as Citrix), the applications look like they are running directly on your local computer but they are actually running on hardware at ASU. Citrix allows ASU to provide software to students, faculty and staff anywhere in the world without installing it on their local machines. In other words, you're able to run SPSS as an online application via MyApps. Thus, you can use SPSS from any computer that's connected to the Internet, without having a copy of the software installed on your computer. For more information, see the MyApps FAQ article at http://help.asu.edu/sims/selfhelp/SelfhelpKbView.seam?parature_id=8373‐8193‐4681.
WINDOWS USED WITHIN SPSS
WINDOW TYPE PURPOSE
SPSS Data Editor Enables viewing and editing of contents of an SPSS data file. Two tabs, Data View (displays data) and Variable View (displays variable attributes). Opens at SPSS start‐up.
SPSS Viewer Displays output from SPSS procedures. The contents of this window can be edited.
SPSS Syntax Editor Used to create and run SPSS command (“syntax”) files.
Revised January 7, 2014 Page 5 of 14
BASIC STEPS IN DATA ANALYSIS (PER THE SPSS HELP SYSTEM)
1. Get your data into IBM SPSS Statistics. You can open a previously saved IBM SPSS Statistics data file, you can read a spreadsheet, database, or text data file, or you can enter your data directly in the Data Editor.
2. Select a procedure. Select a procedure from the menus to calculate statistics or to create a chart. 3. Select the variables for the analysis. The variables in the data file are displayed in a dialog box for
the procedure. 4. Run the procedure and look at the results. Results are displayed in the Viewer.
DETAILED STEPS IN DATA ANALYSIS (IT’S NOT QUITE AS SIMPLE AS THEY SAY) 1. Design your study
a. Identify your research questions b. Formulate specific hypotheses c. Identify your target population d. Develop a sample plan e. Decide upon a data collection strategy f. Plan the data analyses to be performed
2. Choose or design instruments/questionnaires
3. Develop a codebook
4. Collect the data
a. Paper and pencil questionnaires b. Web‐based surveys c. Specialized data collection software
5. Enter the data into the computer
a. Enter data directly into the SPSS Data Editor b. Download data from a web survey and import into SPSS c. Import data entered with other software into SPSS
6. Clean the data
a. Perform value and range checks b. Check for consistency among related variables
7. Perform data transformations as needed a. Create composite variables (e.g. scale scores) from raw items b. Recode variables, e.g. reverse scales or group ranges of values
8. Run analysis procedures
9. Interpret the results
10. Report your findings
Revised January 7, 2014 Page 6 of 14
THE SPSS DATA EDITOR
There are two views, accessed via corresponding tabs:
Data View
Displays the data, one row per case and one column for each variable. Variable names are displayed at
the top of each column.
Variable View
Displays the metadata dictionary. In this view, one variable, along with its characteristics, is listed per
line.
Revised January 7, 2014 Page 7 of 14
TYPES OF VARIABLES IN SPSS
Numeric A variable whose values are numbers. Values are displayed in standard numeric format.
The Data Editor accepts numeric values in standard format or in scientific notation.
String A variable whose values are not numeric and therefore are not used in calculations. The
values can contain any characters up to the defined length. Uppercase and lowercase
letters are considered distinct. This type is also known as an alphanumeric variable.
Other Variations on numeric data: Comma, Dot, Scientific Notation, Date, Dollar, and Custom
Currency
VARIABLE ATTRIBUTES IN SPSS
ATTRIBUTE DESCRIPTION DETAILS
Name Variable name Variable names can be up to 64 characters long, and the first character must be a letter or one of the characters @, #, or $.
Type Data type See Types of Variables in SPSS, above
Width Number of digits or characters
For numeric variables, the width of the number that is displayed. String variables can be up to 32,767 characters long.
Decimals Number of decimal
places
Number of decimal places displayed for numeric variables
Label Descriptive variable
label
Labels otherwise‐cryptic variable names; up to 255 characters in length
Values Descriptive value labels Labels category values; up to 120 character in length
Missing User‐defined missing
values
Up to 3 distinct values (or a range of values plus a distinct value) can be declared to be treated as missing.
Columns Column width The display width of a variable in the Data Editor
Align Alignment Alignment of variables in the Data Editor; the default is right for numeric variables and left for string variables
Measure Measurement level Nominal Unordered categories
Ordinal Ordered categories
Scale Interval‐level values
Role Role assignment Some dialogs support predefined roles that can be used to pre‐select variables for analysis. Available roles include Input (e.g., predictor or independent variable), Target ((e.g., dependent variable), Both, None and several more.
Revised January 7, 2014 Page 8 of 14
MISSING VALUES
Missing values are ignored in calculations.
An empty cell for a numeric variable is assigned the SPSS “system missing value,” represented by a
dot, or period, (.) in the Data Editor.
Up to three “user missing values” can be declared for a variable or a range of values plus one
additional discrete value.
OPENING AND SAVING FILES
SPSS can read and write data in a variety of file types.
FILE TYPE FILENAME EXTENSION DETAILS
SPSS Statistics .SAV Data files saved in SPSS format
SPSS/PC+ .SYS SPSS/PC+ data files
SYSTAT .SYD, .SYS SYSTAT data files
Portable .POR Data files saved in SPSS portable format
Excel .XLS, .XSLX, .XLSM Excel files
Lotus 1‐2‐3 .W* Data files saved in 1‐2‐3 format for release 3.0, 2.0, or 1A of Lotus
SYLK .SLK Data files saved in SYLK (symbolic link) format, a format used by some spreadsheet applications
dBase .DBF dBASE‐format files for either dBASE IV, dBASE III or III PLUS, or dBASE II
SAS .SAS7BDAT, .SD7, .SD2, .SSD01, .SSD04,.XPT
SAS versions 6–9 and SAS transport files
Stata .DTA Stata versions 4–8
Text .TXT, .DAT Text files
Database files Various SPSS can read data from any database format for which you have a database driver.
Revised January 7, 2014 Page 9 of 14
RUNNING SPSS PROCEDURES
Most procedures are accessed via the Analyze menu. Procedures are grouped according to type, e.g.
Reports, Descriptive Statistics, Compare Means, Tables, General Linear Model, and so on.
Menu selections typically open dialog boxes. You use these dialog boxes to select variables and options
for analysis. Dialog boxes for statistical procedures and charts typically have two basic components:
Source variable list
A list of variables in the active dataset. Only variable types that are allowed by the selected
procedure are displayed in the source list. Use of short string and long string variables is
restricted in many procedures.
Target variable list(s)
One or more lists indicating the variables that you have chosen for the analysis, such as
dependent and independent variable lists.
In the following example of the FREQUENCIES procedure, the left pane contains a list of variables in the
data set (the “source variable list”) and the right pane (a “target variable list”) contains a list of the
variables to be analyzed by the procedure. In this case, two frequency tables will be produced, one for
the variable SEX and another for the variable EDUC.
Revised January 7, 2014 Page 10 of 14
SAVING AND MODIFYING OUTPUT
Results are displayed in the IBM SPSS Statistics Viewer:
You can use the Viewer to:
Browse results
Show or hide selected tables and charts
Change the display order of results by moving selected items
Export items from the Viewer to other applications
The Viewer is divided into two panes:
The left pane contains an outline view of the contents.
The right pane contains statistical tables, charts, and text output.
You can click an item in the outline to go directly to the corresponding table or chart. You can click and
drag the right border of the outline pane to change the width of the outline pane.
Revised January 7, 2014 Page 11 of 14
PIVOT TABLES
Most procedure output is displayed in pivot tables. When opened in the Pivot Table Editor, pivot tables
can be modified in the following ways:
• Transposing rows and columns
• Moving rows and columns
• Creating multidimensional layers
• Grouping and ungrouping rows and columns
• Showing and hiding rows, columns, and other information
• Rotating row and column labels
• Generating charts from selected table contents
EXPORTING SPSS OUTPUT TO OTHER APPLICATIONS
Via the Export selection in the File menu in the IBM SPSS Statistics Viewer, you can save output in HTML,
text, Word/RTF, Excel, PowerPoint and PDF formats. Charts can also be exported in a number of
different graphics formats.
You can export all objects in the Viewer, all visible objects, or only selected objects.
DATA TRANSFORMATIONS
The Transform menu includes routines which perform transformations on selected variables. These
include the following, among others:
COMPUTE Compute values for a variable based on numeric transformations of other variables
COUNT Creates a numeric variable that, for each case, counts the occurrences of the same value
(or list of values) across a list of variables
RECODE Allows you to reassign the values of existing variables or collapse ranges of existing
values into new values for a new or existing variable
A Date and Time Wizard simplifies a number of common tasks associated with date and time variables,
including creating a date/time variable from other variables containing parts of dates or times and
calculating with dates and times, such as computing the number of time periods between two dates.
Revised January 7, 2014 Page 12 of 14
RESTRUCTURING DATA
A Restructure Wizard helps you restructure your data from multiple variables (columns) in a single case
to groups of related cases (rows) or vice versa, or you can choose to transpose your data.
In this repeated‐measures example, three measures (X1, X2 and X3) are recorded twice for each subject.
(T1 represents Time 1 and T2 represents Time 2.) The data set is initially organized such that all
measurements for a subject appear on a single record. Variables X1T1 through X3T1 represent measures
X1, X2 and X3 measured at Time 1, and variables X1T2 through X3T2 represent the same measures
recorded at Time 2.
After using the Restructure Wizard to “Restructure selected variables into cases,” the data set appears
as below. There now is one record in the file for each combination of subject and time. That is, a record
for Subject #1 at Time 1, a record for Subject #1 at Time 2, a record for Subject #2 at Time 1, and so on.
A new variable, TIME, denotes which of the two measurement times is represented on the data record.
(This is the structure I generally prefer for recording repeated‐measures data.)
Revised January 7, 2014 Page 13 of 14
WORKING WITH SUBSETS OF YOUR DATA
SELECT CASES Allows you to run procedures on cases selected via a logical expression
SPLIT FILE Splits the active dataset into subgroups that can be analyzed separately
SPSS FILE TYPES AND COMPATIBILITY AMONG VERSIONS
FILE TYPE EXTENSION CONTENTS
SPSS Data File *.SAV Data values and variable attributes
SPSS Output File *.SPO (SPSS 15 and older), *.SPV) Output from SPSS procedures
SPSS Syntax File *.SPS SPSS commands (“syntax”)
SPSS Data Files are pretty much forward‐ and backward‐compatible (since Version 11).
SPSS Output Files are generally not backward‐compatible (you may not be able to open output files created in a later version of SPSS) but usually are forward‐compatible.
SPSS 16 and newer versions use file type *.SPV for Output Files and cannot open *.SPO files. Users of SPSS 16 and newer versions must use the SPSS Legacy Viewer, which can be downloaded from ftp://ftp.software.ibm.com/software/analytics/spss/support/Stats/Docs/Statistics/LegacyViewer/readme.html , to open *.SPO files.
SPSS Syntax Files are fully forward‐ and backward‐ compatible among versions, although the specific
commands may differ somewhat between versions.
Revised January 7, 2014 Page 14 of 14
SETTING SPSS OPTIONS
A number of features in SPSS can be customized according to your personal preferences.
From the Edit menu, select Options. The following screen will appear. Note that there are several tabs
under which specific options are grouped. The screen shown displays the General tab.
Here are some Options settings that I prefer:
TAB FEATURE SETTING
General Variable Lists Display names
“ “ File (order of variables in dialog windows)
“ Output No scientific notation for small numbers in tables
“ “ “Raise viewer window” unchecked; “Scroll to new output” and selected
Viewer Initial Output State Display commands in the log
Pivot Tables Default Editing Mode Open all tables in a separate window
top related