You are on page 1of 31

Ahmad Nazim & W.M.

Asyraf 1 Introduction to SPSS hands-0n

Toolbar This toolbar is available in SPSS Data Editor, providing quick and easy access to frequently used features. The following are some of the frequent used tools in the Data Editor. Item Description File Open : allows data files to be opened for analysis. File Save : saves the file in the active window. File Print : prints the file in the active windows.

Insert Cases : inserts a case above the case containing the active cell.

Insert Variable : inserts a variable to the left of the variable containing the active cell. Value Labels : allows toggling between actual values and value labels in the Data Editor. Select Cases : provides methods for selecting a subgroup of cases based on criteria that include variables and complex expressions. Split Files : splits the data file into separate groups for analysis based on the values of one or more grouping variable.

Ahmad Nazim & W.M.Asyraf 2 Introduction to SPSS hands-0n

The box shown above is a dialogue box appears once PASW SPSS 18.0 opened. To open an existing file, choose a file under open an existing data source menu. Since we are not going to use this dialogue box, click on the Cancel button to close it.

If you want to open existing data, go to File > Open > Data.

Ahmad Nazim & W.M.Asyraf 3 Introduction to SPSS hands-0n

You can now open the location where you save the existing SPSS data file.

Data Editor Window

The window (shown above) is the Data Editor Window. It consists of 12 pull-down PASW STATISTICS menus available for user. The menus are: File, Edit, View, Data, Transform, Analyze, Direct Marketing, Graphs, Utilities, Add-ons, Window and Help. At

Ahmad Nazim & W.M.Asyraf 4 Introduction to SPSS hands-0n

the left-bottom of the window, there are options for Data View and Variable View windows.

The Data View window is where you will type in your data. However, you must first tell SPSS certain things about your data and you will do this in the Variable View window.

Variable View window has 10 columns and they tell the program different things about the measurement values such as whether or not the values are qualitative or quantitative.

Defining Variables To enable PASW SPSS 18.0 analysis works, variables of the research must be defined first in the Data Editor Window before entering any data. Click on the left bottom of the PASW STATISTICS Data Editor. We can see Define Variable Dialog box, as shown in the figure below. It consists of:

Name Type Width Decimals Label Values Missing Measure

Ahmad Nazim & W.M.Asyraf 5 Introduction to SPSS hands-0n

Nominal variable, is for mutual exclusive, but not ordered, categories. For example, your study might compare achievement between gender; male and female.

Ordinal variable, is one where the order matters but not the difference between values. For example, you might ask patients to express the amount of pain they are feeling on a scale of 1 to 10. Another example would be movie ratings, from * to *****.

Interval variable is a measurement where the difference between two values is meaningful. For example, you might ask the respondents salary in order to compare their salary and their expenses.

Ratio data is interval data with a natural zero point. For example, time is ratio since 0 time is meaningful. A weight of 4 grams is twice a weight of 2 grams, because weight is a ratio variable. A temperature of 100 degrees C is not twice

Ahmad Nazim & W.M.Asyraf 6 Introduction to SPSS hands-0n

as hot as 50 degrees C, because temperature C is not a ratio variable. A pH of 3 is not twice as acidic as a pH of 6, because pH is not a ratio variable. Variable Name Label Gender Qualification Respondents Sex Value Label 1 = Male, 2 = Female Measure Nominal

Respondents 1 = SPM, 2 = Diploma, 3 = Ordinal Highest Education Bachelor, 4 = Master, 5 = PhD Background Respondents Monthly Income 1 = RM999, 2 = RM1000 Interval RM1999, 3 = RM2000 RM2999, 4 = RM3000 RM3999, 5 = RM4000 Any value Ratio

Income

Weight

Respondents Weight

Value Labels Value labels is a label assigned to a particular value of variable. For example, for races label, we might use codes 1= Malay, 2= Chinese, 3= Indian, 4=others.

In our case, for gender labels we will use 1= Male and 2= Female. To enter the codes: Type 1 in value box and male in label box. Then click Add.

Ahmad Nazim & W.M.Asyraf 7 Introduction to SPSS hands-0n

Type 2 in value box and female in label box. Then click Add. End the process OK.

Missing Values

Select Discrete Missing Value button. Then, type 99 (example) or any other code s that will not be used in other variables code to replace the missing value. Repeat the step for labelling other variables. For age, the Measure column should be in scale since age is an interval measure. The same measure goes to visit, serv_prop, ser_friendly, serv_clean, serv_time, serv_overall variables. For employment and residence, we will use a Nominal measure.

Ahmad Nazim & W.M.Asyraf 8 Introduction to SPSS hands-0n

Ahmad Nazim & W.M.Asyraf 9 Introduction to SPSS hands-0n

Ahmad Nazim & W.M.Asyraf 10 Introduction to SPSS hands-0n

Assumption on Parametric Test 1. Data must be normal 2. Data have equal variance 3. Data must be more than 30 cases

Ahmad Nazim & W.M.Asyraf 11 Introduction to SPSS hands-0n

Testing Normality Testing normality of our data is prerequisite for inferential statistical technique. The normality test also needed in order to use parametric test on our data. Only normal data can use parametric tests. To check normality for single variable, follow the following steps:

Analyze > Descriptive Statistics > Explore

Select the variable of interest, for example : age. Then, click on Plots button.

Ahmad Nazim & W.M.Asyraf 12 Introduction to SPSS hands-0n

Ansure that the Factor levels together button is selected in the Boxplot display. Tick on Stem and Leaf, Histogram and Normality plots with tests buttons Click Continue for the results.

Ahmad Nazim & W.M.Asyraf 13 Introduction to SPSS hands-0n

Normality Test (Single Variable) Output

In the above diagram, the Histogram shows a perfect bell-shaped distribution without skewness to either left or right. Therefore, the age variable can be concluded as normal.

Ahmad Nazim & W.M.Asyraf 14 Introduction to SPSS hands-0n

Another way to look at the distribution of our data is by using Normal Q-Q plot. In our case, the points lie along the straight line and show no pattern, therefore the age data distribution can be concluded as normal.

To check normality for multiple variables, follow the following steps:

Analyze > Regression > Linear

Ahmad Nazim & W.M.Asyraf 15 Introduction to SPSS hands-0n

Click overall quality and insert it to the Dependent box. Click other observed variable (demographic profile excluded) to the independent variables. Then, click on Plots button.

Normality Test (Multiple Variables) Output

In the above diagram, the Histogram shows a perfect bell-shaped distribution without skewness to either left or right. Therefore, variables in this case study can be concluded as normal.

Ahmad Nazim & W.M.Asyraf 16 Introduction to SPSS hands-0n

Another way to look at the distribution of our data is by using Normal Q-Q plot. In our case, the points lie along the straight line and show no pattern, therefore the age data distribution can be concluded as normal.

Recode Into Different Variable Recode assigns discrete values to a variable, based solely on the present values of the variable being recoded. You may want to recode variable for easier interpretation or decision making.

Transform > Recode Into Different Variables

Ahmad Nazim & W.M.Asyraf 17 Introduction to SPSS hands-0n

Step 2: Type overall in the Name box. Then, click on Old and New Values button.

Step 3 : Let us recode the overall perception variable 1 thru 2 = 1 (low / disagree) 3 = 2 (medium / undecided) 4 thru 5 = 3 (high / agree) Then, click on Continue button.

Ahmad Nazim & W.M.Asyraf 18 Introduction to SPSS hands-0n

Now, new recoded value will appear to the left side of the Data View window.

Independent Sample T-Test The Independent Sample T-test procedure tests the null hypothesis that the population mean o a variable is the same for the two groups of cases. It also displays confidence interval for the different between the population means of the groups Step 1: Click analyze > Compare Means > Independent- Sample T- test

Ahmad Nazim & W.M.Asyraf 19 Introduction to SPSS hands-0n

Step 2: Transfer the variable into Test Variable(s) box, following gender variable into the Grouping Variable: box (below)

Step 3: Click on the Define Groups button and you will need to define which two categories for gender variable. In this case, there are only two categories which are male for Group 1 and female in Group 2. These categories referred as the values 1 and 2. Hence, type the value 1 in the Group 1 and 2 in the Group 2.

Ahmad Nazim & W.M.Asyraf 20 Introduction to SPSS hands-0n

Step 4: Click on Continue. Then OK. The following output is appeared:


Group Statistics respondent's sex infrastructure male female service quality cleanliness quality queue time male female male female male female overall quality male female N 7 16 7 16 7 16 7 16 7 16 Mean 3.5714 3.6250 3.4286 3.8125 4.2857 3.8125 3.1429 2.8750 4.0000 4.0000 Std. Deviation .53452 .95743 .53452 1.04682 .75593 .75000 .89974 .88506 .81650 .73030 Std. Error Mean .20203 .23936 .20203 .26171 .28571 .18750 .34007 .22127 .30861 .18257

The table above shows the means of infrastructure, service quality, cleanliness quality, queue time and overall quality between male and female. By referring on that table, the mean to cleanliness quality for male is the highest following to the overall quality between male and female. The least mean is queue time for female.

Independent Samples Test Levene's Test for Equality of Variances t-test for Equality of Means Std. Sig. (2F infrastructure Equal variances assumed Equal variances not assumed service quality Equal variances assumed Equal variances not assumed cleanliness Equal variances assumed .000 .987 1.389 21 .179 .47321 .34064 -.23519 1.18162 3.000 .098 -.911 21 .372 .259 -.38393 .42131 -1.26010 -.38393 .33061 -1.07306 .49224 .30520 1.447 Sig. .242 t -.138 df 21 tailed) .892 .866 Mean Differen ce Error Differe nce 95% Confidence Interval of the Difference Lower -.86228 -.70827 Upper .75514 .60113

-.05357 .38888 -.05357 .31322

-.171 19.387

-1.161 20.237

Ahmad Nazim & W.M.Asyraf 21 Introduction to SPSS hands-0n


quality Equal variances not assumed queue time Equal variances assumed Equal variances not assumed overall quality Equal variances assumed Equal variances not assumed .091 .765 .000 21 1.000 1.000 .00000 .34256 .00000 .35857 -.71239 -.79456 .71239 .79456 .106 .748 .665 21 .513 .522 .26786 .40299 .26786 .40571 -.57020 1.10592 -.62184 1.15755 1.385 11.433 .193 .47321 .34174 -.27550 1.22193

.660 11.342

.000 10.424

The table above encompasses the result of Levenes Test for equality of variances and t- test for equality of means. However, most of researchers just focus on the value of significant in t- test for equality of means to determine whether differences exist between male and female students. In this case, all of the variables indicates that p> 0.05 and therefore is not significant. Hence, the null hypothesis is accepted that there is no significant difference between male and female pertaining to all variable included. One-Way Anova

Step 1: Click analyze > compare means > One- way ANOVA

Ahmad Nazim & W.M.Asyraf 22 Introduction to SPSS hands-0n

Step 2: Transfer the infrastructure (serv_prop) from the list variable into Dependent List following the work place (employment) into the factor.

Step 3: Click Post Hoc > Tick LSD

Step 4: Click Option > Tick Descriptive, Fixed and Homogeneity of Variance Test

Ahmad Nazim & W.M.Asyraf 23 Introduction to SPSS hands-0n

Step 5: Click on Continue, followed by OK. The following result is produced:


Descriptives Infrastructure 95% Confidence Interval for Mean Std. N Government Private Sector GLC Sector Self Employed Total M Fixed Effects o Random Effects d e l Mean Deviation 1.32916 .40825 .54772 .54772 .83878 .80677 Std. Error .54263 .16667 .24495 .22361 .17490 Lower Bound 2.7718 2.7382 2.9199 2.9252 3.2460 Upper Bound 5.5615 3.5951 4.2801 4.0748 3.9714 3.9608 4.2855 .06731 Minimum 2.00 3.00 3.00 3.00 2.00 Maximum 6.00 4.00 4.00 4.00 6.00 BetweenComponent Variance

6 4.1667 6 3.1667 5 3.6000 6 3.5000 23 3.6087

.16822 3.2566 .21266 2.9319

Ahmad Nazim & W.M.Asyraf 24 Introduction to SPSS hands-0n

The descriptive table shows mean of infrastructure for each categories of work place. The result obtained shows the respondents among government sector are the highest interest on infrastructure towards customers satisfaction. Instead, the respondents among private sector are the lowest interest on infrastructure towards customer satisfaction.
Test of Homogeneity of Variances infrastructure Levene Statistic 1.643 df1 3 df2 19 Sig. .213

The test of homogeneity shows insignificant since 0.213> 0.05. So, the null hypothesis is accepted and proved that the population variances for each group are approximately equal. This test is required to ensure the probability of the test value is homogeneity or heterogeneity.
ANOVA Infrastructure Sum of Squares Between Groups Within Groups Total 3.112 12.367 15.478 df 3 19 22 Mean Square 1.037 .651 F 1.594 Sig. .224

The significant value of the ANOVA table is 0.224 which is greater than 0.05. Hence, the null hypothesis is accepted which defines that the infrastructure towards customer satisfaction is not different at work place. However, the ANOVA result does not enough to identify which work place differed with each other. Thus, the LSD is required to determine where the significant lies. The result is shown as below:
Multiple Comparisons Infrastructure LSD (I) work place (J) work place Mean Difference (I-J) Government Sector Private Sector GLC Sector 1.00000
*

95% Confidence Interval Std. Error .46579 .48852 Sig. .045 .260 Lower Bound .0251 -.4558 Upper Bound 1.9749 1.5892

.56667

Ahmad Nazim & W.M.Asyraf 25 Introduction to SPSS hands-0n


Self Employed Private Sector Government Sector GLC Sector Self Employed GLC Sector Government Sector Private Sector Self Employed Self Employed Government Sector Private Sector GLC Sector .66667 -1.00000
*

.46579 .46579 .48852 .46579 .48852 .48852 .48852 .46579 .46579 .48852

.169 .045 .386 .483 .260 .386 .840 .169 .483 .840

-.3082 -1.9749 -1.4558 -1.3082 -1.5892 -.5892 -.9225 -1.6416 -.6416 -1.1225

1.6416 -.0251 .5892 .6416 .4558 1.4558 1.1225 .3082 1.3082 .9225

-.43333 -.33333 -.56667 .43333 .10000 -.66667 .33333 -.10000

*. The mean difference is significant at the 0.05 level.

The outcome illustrates that government sector and private sector have significantly different mean on infrastructure towards customers satisfaction.

Association Analysis Association Analysis is the weakest measurement of relationship. It is usually used for categorical types of data with nominal and ordinal measurement. Measurement of association is obtained together with cross tabulation between qualitative variables (Nominal and Ordinal). For example, we want to measure the relationship between the gender (male and female) with their attitude towards Mathematics whether high, medium or low. Step 1: Click analyze > Descriptive Statistics > Crosstabs

Ahmad Nazim & W.M.Asyraf 26 Introduction to SPSS hands-0n

Step 2: Transfer the cleanliness quality into the Row(s) following the respondents sex into the Column(s).

Step 3: Click Statistics > Tick Chi-square

Ahmad Nazim & W.M.Asyraf 27 Introduction to SPSS hands-0n

Step 4: Click Cell Display > Tick Observed and Unstandardized Residual

Step 5: Click on Continue and then press OK.

Ahmad Nazim & W.M.Asyraf 28 Introduction to SPSS hands-0n

Crosstab respondent's sex male overall quality neither agree nor disagree agree Count Residual Count Residual strongly agree Count Residual Total Count 2 .2 3 -.3 2 .2 7 female 4 -.2 8 .3 4 -.2 16 23 6 11 Total 6

Chi-Square Tests Asymp. Sig. Value Pearson Chi-Square Likelihood Ratio Linear-by-Linear Association N of Valid Cases .100
a

df 2 2 1

(2-sided) .951 .951 1.000

.100 .000 23

a. 5 cells (83.3%) have expected count less than 5. The minimum expected count is 1.83.

First, look at the Pearson Chi- Square value. Based on the result, the Chi-Square test value is not significant since p-value is greater than 0.05. This result indicates that there is no association exist between gender and the perception towards overall quality.

Ahmad Nazim & W.M.Asyraf 29 Introduction to SPSS hands-0n

Correlation Analysis Correlation Analysis is used to measure the relationship between variables. To measure the relationship using correlation analysis, there are two types of correlation coefficient which are the Spearman rank coefficient of correlation and the Pearson product moment coefficient of correlation. The Spearman is appropriate for abnormal data and it is also known as the non parametric version of correlation analysis. The Pearson is appropriate for normal distributed data and it is calculated using the actual data values while Spearman replaces the actual data with ranks.

Step 1: Click Analyze > Correlate > Bivariate

Step 2: Transfer the five variables from the list variables into the Variables.

Ahmad Nazim & W.M.Asyraf 30 Introduction to SPSS hands-0n

Step 3: Click OK.


Correlations service infrastructure infrastructure Pearson Correlation Sig. (2-tailed) N service quality Pearson Correlation Sig. (2-tailed) N cleanliness quality Pearson Correlation Sig. (2-tailed) N queue time Pearson Correlation Sig. (2-tailed) N overall quality Pearson Correlation Sig. (2-tailed) N 23 -.408 .054 23 .046 .835 23 .111 .613 23 -.592 .003 23 23 -.147 .502 23 -.408 .053 23 -.066 .763 23 23 -.604 .002 23 .401 .058 23 23 .210 .335 23 23 1 quality -.408 .054 23 1 cleanliness quality .046 .835 23 -.147 .502 23 1 queue time .111 .613 23 -.408 .053 23 -.604 .002 23 1 overall quality -.592 .003 23 -.066 .763 23 .401 .058 23 .210 .335 23 1

**. Correlation is significant at the 0.01 level (2-tailed).

Ahmad Nazim & W.M.Asyraf 31 Introduction to SPSS hands-0n

The table above shows that there is only two significant relationships exist among the variables which are relationship between infrastructure with overall quality and cleanliness with queue time with p-value of 0.03 and 0.02 respectively (<0.05). Both relationships are considered as negative moderate relationship.

You might also like