Post on 04-Jan-2016
Data Analysis Using SPSSEDU5950
SEM1 2014-15Test of Differences Between Means
Assoc. Prof. Dr. Rohani Ahmad TarmiziInstitute for Mathematical Research/
Faculty of Educational StudiesUPM
OverviewFirst objective – learn what is important in choosing analyses, and information about some of the more common statistical analyses
Second objective – will get a data set and walk through how to conduct some analyses of differences between means
Statistical Tools For Inferential Statistics
• PARAMETRIC TESTS: – Test of hypothesis of differences between means - Z-test,
t-test, F-test, MANOVA– Test of hypothesis of relationship – Pearson r, Point-
biserial, Regression• NON-PARAMETRIC TESTS:
– Chi-square, – Mann-Whitney, – Kruskal Wallis, – Spearman rho, – Cramer’s V, Lambda, dll.
In most research projects, it is likely that you will use quite a variety of
different types of statistics, depending on the question you
are addressing and the nature (level of measurement) of the data that you
have.
It is therefore important that you have a basic understanding of the different
statistical tools, the type of objectives/research
questions/hypotheses to address and the
underlying assumptions and requirements.
Summary of Statistical Tools For Descriptive Analyses
• Frequency/percentage table, • Pie or bar Charts, • Histogram • Frequency Polygon, • Cross-tabulation• Scatter diagram• Mean, Median, Mode, Maximum, Minimum• Range, Variance, Standard Deviation,
Coefficient of variation, Standard Scores
ACTIVITY 1- COMPARISON OF MEANS OF TWO GROUPS
EXPLORING DIFFERENCES BETWEEN TWO GROUPS
1.t-test t-tests are used when you have two groups (e.g. males and females) or two sets of data (before
and after), and you wish to compare the mean score on some continuous variable.
There are two main types of t-tests.
Paired sample t-tests (also called repeated measures) are used when you are interested in
changes in scores for subject tested at Time 1, and then at Time 2 (often after some intervention
or event). The samples are ‘related’ because they are the same people tested each time.
Independent sample t-tests are used when you have two different (independent) groups of
people (males and females), and you are interested in comparing their scores. In this case, you
collect information on only one occasion, but from two different sets of people.
• TO MAKE COMPARISONS BETWEEN GROUPS ON ANY MEASURED VARIABLES AT INTERVAL AND RATIO LEVEL
• CLICK ANALYZE =>COMPARE MEANS• You will get the following Sub-menus
– MEANS– ONE-SAMPLE T-TEST– INDEPENDENT SAMPLES T-TEST– PAIRED SAMPLES T-TEST– ONE-WAY ANOVA
PURPOSE EXAMPLE OF RESEARCH QUESTION
PARAMETRIC STATISTIC INDEPENDENT VARIABLE
DEPENDENT VARIABLE
Comparing means of two groups
Is there a difference in instructors’ efficacy in teaching and learning mathematics as perceived by students of different gender?
Independent t-test
One categorical independent variable gender of two levels-males and females
One continuous dependent variablestudents’ perception on instructors’ efficacy in teaching and learning
To Compare Means of Two Groups•Click: Analyze>Compare means>Independent T-test•You will get a Independent T-test dialog box•Select your variables – Test variables & Group variables•Click OK
HYPOTHESIS ALPHA VALUE
SIGNIFICANT VALUE
(FROM THE SPSS OUTPUT)
EVALUATING DECISION CONCLUSION
There is no significant difference in variance of students’ perception on instructors’ efficacy in T&Lof by different gender
0.05 .351 SIG.V > α Fail to reject null hypothesis,
Accept null hypothesis
There is no significant difference in variance of beliefs on teacher’s role scores for students of different gender.
Choose t from the equal variances assumed row
There is a significant difference in variance of students’ perception on instructors’ efficacy in T&L by different gender
DECISION MATRIX
HYPOTHESIS ALPHA VALUE
SIGNIFICANT VALUE
(FROM THE SPSS OUTPUT)
EVALUATING DECISION CONCLUSION
There is no significant difference in students’ perception on instructors’ efficacy in T&L by different gender
0.05 .926 SIG.V > α Fail to reject null hypothesis,
Accept null hypothesis
There is no significant difference in students’ perception on instructors’ efficacy in T&L by gender, t (60) = -.094, p> .05. ( or p=.926)
There is a significant difference in students’ perception on instructors’ efficacy in T&L by different gender
DECISION MATRIX
Independent Samples Test
Levene's Test for Equality of
Variances t-test for Equality of Means
F Sig. t df
Sig. (2-
tailed)
Mean
Difference
Std. Error
Difference
95% Confidence
Interval of the
Difference
Lower Upper
INSTRUCTORS’ EFFICACY
Equal variances assumed
.883 .351 -.094 60 .926 -.02315 .24740 -.51803 .47173
Equal variances not assumed
-.095 42.237 .925 -.02315 .24347 -.51440 .46811
Group Statistics
GenderN Mean Std. Deviation Std. Error Mean
INSTRUCTORS’
EFFICACY
lelaki 21 3.9490 .89190 .19463
perempuan 41 3.9721 .93662 .14628
PURPOSE EXAMPLE OF RESEARCH QUESTION
PARAMETRIC STATISTIC
INDEPENDENT VARIABLE
DEPENDENT VARIABLE
Comparing means of two groups
Is there a difference in students’ perception of mathematics instructors’ role in making the students enjoy learning maths with making maths’ lessons interesting
Dependent t-test
- Two continuous dependent variable:students’ perception of mathematics inastructors’ role in making the students enjoy learning maths with making maths’ lessons interesting
Item1 vs Item 3
Paired Samples Correlations
N
Correlati
on Sig.
Pair
1
My instructor wants
us to enjoy learning
maths & My
teacher try to make
mathematics
lessons interesting
63 .708 .000 Paired Samples Test
Paired Differences
t df
Sig. (2-
tailed)Mean
Std.
Deviation
Std.
Error
Mean
95% Confidence
Interval of the
Difference
Lower Upper
Pair 1 My instructors
wants us to
enjoy learning
maths - My
teacher try to
make
mathematics
lessons
interesting
-.238 1.174 .148 -.534 .058 -1.610 62 .112
To Compare Means of Two Dependent Groups•Click: Analyze>Compare means>Paired Sample T-test•You will get a Paired Sample T-test dialog box•Select your variables – Paired variables •Click OK
HYPOTHESIS ALPHA VALUE SIGNIFICANT VALUE
(FROM THE SPSS OUTPUT)
EVALUATING DECISION CONCLUSION
There is no significant difference in students’ perception of mathematics instructors’ role in making the students enjoy learning maths with making maths’ lessons interesting
0.05 .112 SIG.V > α Fail to reject null hypothesis,
Accept null hypothesis
There is no significant difference in students’ perception of mathematics instructors’ role in making the students enjoy learning maths with making maths’ lessons interesting, t (62) = -1.160, p> .05. ( or p=.112)
There is a significant difference in students’ perception of mathematics instructors’ role in making the students enjoy learning maths with making maths’ lessons interesting
DECISION MATRIX
ACTIVITY 2 ANOVA
EXPLORING DIFFERENCES BETWEEN GROUPS
One-way analysis variance One-way analysis variance is similar to a t-test, but is used when you have two or more groups and you
wish to compare their mean scores on a continuous variable.
It is called one-way because you are looking at the impact of only one independent variable on your
dependent variable.
A one-way analysis of variance (ANOVA) will let you know whether your groups differ, but it won’t tell you
where the significant difference is (gp1/gp2, gp3/gp4 etc).
You can conduct post-hoc comparisons to find out which groups are significantly different from one
another.
You could also choose to test differences between specific groups, rather than comparing all the groups by
using planned comparisons. Similar to t-tests, there are two types of one-way ANOVAs: repeated measures
ANOVA (same people on more than two occasions), and between-groups (or independent samples)
ANOVA, where you are comparing the mean scores of two or more different groups of people.
PURPOSE EXAMPLE OF RESEARCH QUESTION
PARAMETRIC STATISTIC
INDEPENDENT VARIABLE
DEPENDENT VARIABLE
Comparing means of three groups
Is there a difference in students’ perception of instructors’ efficacy in T&L mathematics byrace?
One-way between groups ANOVA
One categorical independent variable (three levels of race)
One continuous dependent variable students’ perception of instructors’ efficacy in T&L mathematics
Descriptives
INSTRUCTORS’_EFFICACY
N MeanStd.
Deviation
Std.
Error
95% Confidence Interval
for Mean
Minimu
m
Maximu
m
Lower
Bound
Upper
Bound
MELAYU 14 4.2704 .73282 .19586 3.8473 4.6935 3.07 5.36
CINA 40 3.7339 .96118 .15198 3.4265 4.0413 2.21 5.71
INDIA 8 4.5804 .46673 .16501 4.1902 4.9706 3.86 5.07
Total 62 3.9643 .91443 .11613 3.7321 4.1965 2.21 5.71
ANOVA
INSTRUCTORS’ EFFICACY
Sum of Squares df Mean Square F Sig.
Between Groups 6.471 2 3.235 4.286 .018
Within Groups 44.537 59 .755
Total 51.008 61
To Compare Means of Three or More Groups•Click: Analyze>Compare means>One-Way ANOVA•You will get a One-Way ANOVA dialog box•Select your variables – Dependent variables & Factor or Group variables•Click: Options•Click OK
HYPOTHESIS ALPHA VALUE
SIGNIFICANT VALUE
(FROM THE SPSS OUTPUT)
EVALUATING DECISION CONCLUSION
There is no significant difference in students’ perception of instructors’ efficacy in T&L mathematics by race?
0.05 .018 SIG.V < α Reject null hypothesis,
Accept alternative hypothesis
There is significant difference in students’ perception of instructors’ efficacy in T&L mathematics by race, F(2,59) = 4.29, p<.05.
There is a significant difference in students’ perception of instructors’ efficacy in T&L mathematics by race?
DECISION MATRIX
Two-way analysis of variance• Two-way analysis of variance allows you to test the impact of two independent variables on one
dependent variable.
• The advantage of using the two-way ANOVA is that it allows you to test for an interaction effect
– that is, when the effect of one independent variable is influenced by another; for example,
when you suspect that optimism increases with age, but only for males.
• It also tests for ‘main effects’ – that is, the overall effect of each independent variable (e.g. sex,
age).
• There are two different two-way ANOVAs: between - groups ANOVA (when the groups are
different) and repeated measures ANOVA (when the same peoples are tested on more than one
occasion).
• Some research designs combine both between-group and repeated measures in the one study.
These are referred to as ‘Mixed Between-Within Designs’, or ‘Split Plot’.
PURPOSE EXAMPLE OF QUESTION
PARAMETRIC STATISTIC
NON-PARAMETRIC ALTERNATIV
E
INDEPENDENT VARIABLE
DEPENDENT VARIABLE
ESSENTIAL FEATURES
Comparing groups (cont.)
Is there a significant difference in job stress between instructors’ of different leadership style? Different gender? Is there a significant Interaction effect on job stress based on gender and leadership style?
Analysis if covariance (ANCOVA)
None One or more categorical independent variables (two or more levels) – leadership style, gender
One continuous dependent variable -job stress
1. Click Analyze => General Linear Model => Univariate…
2. At the Univariate dialog box, enter Y into Dependent variable box, and X1 and X2 into Fixed Factors box.
3. Click the option button and select the followings
Between-Subjects Factors
Value Label N
gender 1 male 30
2 female 30
leadership
style
1 autocratic 20
2 democratic 20
3 laisserfaire 20
Descriptive Statistics
Dependent Variable:job stress level
genderleadership style Mean
Std. Deviation N
male autocratic 75.8000 6.64664 10
democratic69.1000 7.72370 10
laisserfaire70.9000 9.33869 10
Total 71.9333 8.22080 30
female autocratic 86.5000 6.99603 10
democratic71.9000 8.26573 10
laisserfaire77.5000 4.71993 10
Total 78.6333 8.98460 30
Total autocratic 81.1500 8.61623 20
democratic70.5000 7.91734 20
laisserfaire74.2000 7.95778 20
Total 75.2833 9.18195 60
Levene's Test of Equality of Error Variancesa
Dependent Variable:job stress level
F df1 df2 Sig.
.874 5 54 .505
Tests the null hypothesis that the error variance of the dependent variable is equal across groups.
a. Design: Intercept + gender + leadershipstyle + gender * leadershipstyle
Tests of Between-Subjects Effects
Dependent Variable:job stress level
Source
Type III Sum of
Squares df Mean Square F Sig.
Partial Eta
Squared
Corrected Model 1998.883a 5 399.777 7.256 .000 .402
Intercept 340054.817 1 340054.817 6171.801 .000 .991
gender 673.350 1 673.350 12.221 .001 .185
leadershipstyle 1169.433 2 584.717 10.612 .000 .282
gender * leadershipstyle 156.100 2 78.050 1.417 .251 .050
Error 2975.300 54 55.098
Total 345029.000 60
Corrected Total 4974.183 59
a. R Squared = .402 (Adjusted R Squared = .346)
1. gender
Dependent Variable:job stress level
gender Mean Std. Error
95% Confidence Interval
Lower Bound Upper Bound
male 71.933 1.355 69.216 74.650
female 78.633 1.355 75.916 81.350
2. leadership style
Dependent Variable:job stress level
leadership style Mean Std. Error
95% Confidence Interval
Lower Bound Upper Bound
autocratic 81.150 1.660 77.822 84.478
democratic 70.500 1.660 67.172 73.828
laisserfaire 74.200 1.660 70.872 77.528
3. gender * leadership style
Dependent Variable:job stress level
gender
leadership
style Mean Std. Error
95% Confidence Interval
Lower Bound Upper Bound
male autocratic 75.800 2.347 71.094 80.506
democratic 69.100 2.347 64.394 73.806
laisserfaire 70.900 2.347 66.194 75.606
female autocratic 86.500 2.347 81.794 91.206
democratic 71.900 2.347 67.194 76.606
laisserfaire 77.500 2.347 72.794 82.206
Presenting the results of Factorial ANOVA• A factorial ANOVA was conducted to explore the impact of
gender and leadership style of principals on their teachers’ job stress level. Three leadership style was explored viz-a-viz autocratic, democratic and laisserfaire style. There was a statistically significant main effect for both gender and leadership style on teachers’ job stress level. Therefore gender of principals has an impact on teachers’ job stress level significantly, F (1,60) = 12.22, p = .001. In addition, there is also significant impact of principals’ leadership style on job stress of teachers significantly, F (2,60) = 10.61, p = .000. However the interaction effect between gender and leadership style was not statistically significant F ((2, 60) = 1.42, p = .25.
Post-hoc comparison using Tukey HSD test indicated that the mean job stress score for the female (M=78.63, SD=8.98) is significantlyhigher than the male teachers (M=71.93, SD=8.22). The mean job stress scores between the threegroups of leadership style indicated that theautocratic style impacted significantly higherstress level compared to democratic andlaisserfaire. However there is no significantdifference in stress level between the democratic and lasserfaire leadership style.
PURPOSE EXAMPLE OF QUESTION
PARAMETRIC STATISTIC
NON-PARAMETRIC ALTERNATIVE
INDEPENDENT VARIABLE
DEPENDENT VARIABLE
Comparing groups (cont.)
Is there a significant difference in fear of statistics at three different time?
Repeated measure analysis
None One or more categorical independent variables - time1, time2, time3
One continuous dependent variablefear of statistics at three different time?
REPEATED MEASURES ANOVA
FOLLOW THE PROCEDURES ON THE NEXT SLIDE
PURPOSE EXAMPLE OF QUESTION
PARAMETRIC STATISTIC
NON-PARAMETRIC ALTERNATIV
E
INDEPENDENT VARIABLE
DEPENDENT VARIABLE
ESSENTIAL FEATURES
Comparing groups (cont.)
Is there a significant difference in fear of statistics at three different time?
Repeated measure analysis
None One or more categorical independent variables - time1, time2, time3
One continuous dependent variablefear of statistics at three different time?
Descriptive Statistics
Mean Std. Deviation N
fear of stats time1 40.17 5.160 30
fear of stats time2 37.50 5.151 30
fear of stats time3 35.23 6.015 30
Multivariate Testsc
Effect
Value F
Hypothesis
df Error df Sig.
Partial Eta
Squared
Noncent.
Parameter
Observed
Powerb
fear_statistics Pillai's Trace .635 24.356a 2.000 28.000 .000 .635 48.712 1.000
Wilks' Lambda .365 24.356a 2.000 28.000 .000 .635 48.712 1.000
Hotelling's
Trace
1.740 24.356a 2.000 28.000 .000 .635 48.712 1.000
Roy's Largest
Root
1.740 24.356a 2.000 28.000 .000 .635 48.712 1.000
a. Exact statistic
b. Computed using alpha = .05
c. Design: Intercept
Within Subjects Design: fear_statistics
Mauchly's Test of Sphericityb
Measure:MEASURE_1
Within Subjects Effect
Mauchly's
W
Approx. Chi-
Square df Sig.
Epsilona
Greenhouse-
Geisser Huynh-Feldt Lower-bound
dimension1
fear_statistic
s
.342 30.071 2 .000 .603 .615 .500
Tests the null hypothesis that the error covariance matrix of the orthonormalized transformed dependent variables is
proportional to an identity matrix.
a. May be used to adjust the degrees of freedom for the averaged tests of significance. Corrected tests are displayed
in the Tests of Within-Subjects Effects table.
b. Design: Intercept
Within Subjects Design: fear_statistics
Tests of Within-Subjects Effects
Measure:MEASURE_1
Source Type III
Sum of
Squares df
Mean
Square F Sig.
Partial Eta
Squared
Noncent.
Parameter
Observed
Powera
fear_statistics Sphericity
Assumed
365.867 2 182.933 41.424 .000 .588 82.849 1.000
Greenhouse-
Geisser
365.867 1.206 303.368 41.424 .000 .588 49.958 1.000
Huynh-Feldt 365.867 1.230 297.506 41.424 .000 .588 50.943 1.000
Lower-bound 365.867 1.000 365.867 41.424 .000 .588 41.424 1.000
Error(fear_statisti
cs)
Sphericity
Assumed
256.133 58 4.416
Greenhouse-
Geisser
256.133 34.974 7.323
Huynh-Feldt 256.133 35.664 7.182
Lower-bound 256.133 29.000 8.832
a. Computed using alpha = .05
• A repeated measures ANOVA was carried out. Assumptions of normality, homogeneity of variance and sphericity were met. Results showed that differences between conditions were significant, F (2,35) = 41.424, p=.001. An overall effect size of .588 (partial eta-squared) showed that 60% of the variation in fear of statistics scores can be accounted by differing time.