a simple guide to using spss ( statistical package for the social sciences) for windows

55
A Simple Guide to Using SPSS (Statistical Package for the Social Sciences) for Windows

Upload: piers-cox

Post on 04-Jan-2016

235 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

A Simple Guide toUsing SPSS

(Statistical Package for the Social Sciences) for

Windows

Page 2: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

2

Introduction

Page 3: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

3

Steps for Analyzing Data

• Enter the data

• Select the procedure and options

• Select the variables

• Run the procedure

• Examine the output

Page 4: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

4

Getting Started with SPSS for WindowsTo Start an SPSS session:

• Or launch the software from Start menu

Double-click on the short cut if you can see it

Page 5: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

5

Select Type in data

and click OK to open an empty SPSS Data Editor window.

Page 6: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

6

Data Editor will open

Page 7: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

7

The Data Editor window consists of two pages, indicated by the page tabs at the bottom-left of the Editor window.

The Data View is the ‘data page’ on which all the information will be entered.

Page 8: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

8

Define the Variable Names

Click the Variable View tab at the bottom of the Data Editor window.

Page 9: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

9

• The second page is the Variable View page on which we define the variables to be analyzed.

Page 10: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

10

• Define the variables Name that are going to be used. In this case, 13 variables are needed: ID, gender,…………...

• Rules for naming variables

– Must not contain spaces

– Must begin with a letter or @

– Certain characters such as !, ?, and * are not allowed

– Must not be one of the keywords such as AND, NOT, EQ, BY, or ALL

– Must be unique. No other variable in a data file can have the same name.

• In SPSS version 12 or later, a variable name can have a maximum of 64 characters made up of letters and/or numbers. In earlier versions, only eight characters are permitted.

Page 11: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

11

Click the Data View tab to continue entering the data.

Page 12: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

12

The names you entered in the Variable View are now the headings for the first 13 columns of the Data View

Page 13: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

13

Define the Variable

Click the Variable View tab at the bottom of the Data Editor window.

Page 14: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

14

Define the Variable - Type

By default all Data are Numeric

Change the Non-numeric Data by Click the button in the Type cell to open the Variable Type dialog box.

Page 15: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

15

• Comma format uses commas as thousands’ separators. 1,234.56

• Dot format uses a dot as thousands’ separator and a comma instead of a dot for the decimal point. 1.234,56

• Scientific notation is useful for displaying very small or very large numbers.

1.23E+08 represents 123,000,000. 1.23E-08 represents. 0.0000000123• Dollar format will display data as money, i.e. the values

are displayed with a $ sign in front. $1,234.56 • Custom Currency format needs to be defined before use.

In the two examples we have customised for pounds sterling and euros. £1,234.56 and €1,234.56

• Date formats SPSS has a variety of date and time formats available.

Variable Type

Page 16: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

16

Set the variable's type of ID, to String.Click OK to save your changes

A string is a sequence of characters (letters, symbols, digits) which is treated as a label by the system, i.e. Values of a string variable are not numeric, and hence not used in calculations.

A string variable is a qualitative variable

Page 17: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

17

Both Type and Measure will be changed

Page 18: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

18

Repeat Setting of the variable's type withGender to String.

Set the variable's type of Salary, to Dollar.Click OK to save your changes

Page 19: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

19

Define The maximum number of characters (digits or letters) appear in the data view window When you select String as variable Type, and in order to be viewed in the data view window, you have to increase the width to > 8 if you are intending to write more than 8 characters

Page 20: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

20

Display decimal points, even though their values are intended to be integers. To hide the decimal points in these variables type 0.

Page 21: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

21

Define the Variable – Labels

• Labels will be displayed in the output.

• Variable Label

– Providing useful descriptive information of variables. than variable name.

– Can be up to 255 character

• allows you to list a more extensive label for your variable. Eight character variable names are difficult to remember, and we recommend that you always exercise the option of listing a more descriptive label.

• Useful to include the unit of measurement in the label

Page 22: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

22

• In the Label column of the ID row, type Employee code.•  Type Education level as the label for the ed-lev

variable……..etc

Page 23: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

23

Page 24: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

24

• Value Labels

• allows you to provide labels for the various levels of a variable.

• For example, value labels can be used to specify that M stands for Male and F stands for Female.

Page 25: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

25

• To Define Variable label,

Select the Values cell in the gender row and click the button to display the Value Labels dialog box.

Page 26: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

26

• Type “f” for the Value and “female” for the Value Label.

•  Click Add to have this label added to your data file.

• Repeat the process, but this time type “m” for the Value and “male” for the Value Label.

•  Click OK to implement your changes.

Page 27: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

27

Page 28: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

28

• Because string values are case sensitive, you should make sure you are consistent with your cases. A lower case “m” is not the same as a capital “M”.

Page 29: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

29

Repeat the process for education level

Page 30: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

30

Repeat the process for Smoking status

Page 31: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

31

Repeat the process for Physical activity

Page 32: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

32

Define the Missing Values

In SPSS, there are no empty cells within the data file

If you don't take steps to filter or identify this data, your analysis may not provide accurate results.

Page 33: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

33

For numeric data, blank data fields or those containing invalid entries are handled by converting those fields to system missing.

• The reason a value is missing may be

– Failure to understand the question

– Refused to answer– Data entry mistakes– Don’t know the answer– The question is not

applicable to the respondent– answer in a format not

expected

Page 34: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

34

We need to be careful to select a value for the missing value that is one that the variable cannot possibly take. Example if we were measuring the age of pre-school children, 3 would not be an appropriate choice for the missing value; 99 might be better because such a score could not actually represent a real case.

Page 35: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

35

• Select the Missing cell in the Age row and click the button to open the Missing Values dialog box.

Page 36: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

36

• In this dialog, you can specify up to three distinct missing values, or a range of values plus one additional discrete value.

• Select Discrete Missing Values.•  Type 0 as the missing value and leave the other two boxes

blank.• Click OK to implement your changes.

Page 37: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

37

Now that the missing data value has been added, a label can be applied to that value.

Select the Values cell in the age row and click the button to open the Value Labels dialog box.

Page 38: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

38

Type 0 for the Value.

Type No Response for the Value Label.

Page 39: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

39

Click Add to have this label added to your data file.

Click OK to implement your changes.

Page 40: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

40

Page 41: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

41

• Click the Missing Values cell for the sex variable.

•  Click the button in this cell to open the Missing Values dialog box.

Missing values for string variables

• Missing values for string variables are handled similarily to those for numeric values.

Page 42: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

42

• Select Discrete Missing Values.• Type NR for the missing value.• Click OK to save your changes

• Missing values for string variables are case sensitive. So, a value of nr is not treated as a missing value.

Page 43: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

43

• Now you can add a label for the missing value.•  Select the Values cell in the sex row and click the button to

open the Value Labels dialog box.

Page 44: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

44

• Type NR for the Value.• Type No Response for the Value Label.

• Click Add to have this label added to your project.• Click OK to implement your changes

Page 45: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

45

Define the Variable -Column FormatDefine the Variable -Column Format

Column Format is used to define column width for the variable in the Data View .

If the defined and actual width of a value are wider than the column, asterisks (*) are displayed in the Data View.

Page 46: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

46

Used to define column alignment in the Data Editor window

Page 47: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

47

•Used to Specifying the level of measurement for the variable..

• SPSS defines variables as measured in one of three ways.

• Scale is for interval/ratio data.. • Ordinal is for variables whose values represent

categories with some inherent order between them, such as social class, attitudinal scales (e.g. agree, neutral, disagree).

• Nominal is for categorical variables with values which are not sequentially ordered, they are just names.

• By default, new numeric variables are set to Scale and variables with text (or string) values are set to Nominal.

Page 48: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

48

Page 49: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

49

Entering Data DirectlyEntering Data Directly

Page 50: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

50

Begin entering data in the first row, starting at the first column.

• Enter the value for each variable.

• Move the cursor or Press <Tab> key or right arrow key to move to next variable.

Page 51: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

51

• Leave blank or use user-defined missing value if no answer.

• Press <Enter> key to move to next row.

Page 52: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

52

Each row represents a single case (observation)

Each column is a single variable

Page 53: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

53

Change the View - Value LabelsChange the View - Value Labels

Data entered as numeric codes can be displayed as value labels.

which can help to make your data more readable.

Page 54: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

54

From the menus choose:• View • Value Labels• Or alternatively press this button

Change the View - Value LabelsChange the View - Value Labels

Page 55: A Simple Guide to Using SPSS ( Statistical Package for the Social Sciences) for Windows

55

Change the View - Value LabelsChange the View - Value Labels

The labels are now displayed in a listbox, which has the benefit of suggesting a valid response and providing a more descriptive answer.