Helpdesk IBM SPSS Statistics 20For students from Arnhem Business School | ||||||||

Home | Codebook | Data | Data editing | Analysis | Graphs | Settings | Links | Methods |

## Analysis Independent Samples t-testBy means of an independent samples t-test for samples from two populations you test whether
the population means of a certain variable for the two populations are equal or
different. The presentation takes the following steps: - Hypotheses
- An interesting observation
- Asking for the test using SPSS
- The SPSS output for age by gender
- Checking for the equality of variances conditions
- Interpreting the rest of the output for age by gender
- The SPSS output for age by born where
- Interpreting the output for age by born where
- Graphical display of the results
- Download the sample data file
## Hypotheses:For a number of years we have asked foundation year students to fill in a simple questionnaire with some questions about who they are. We use this data in class in our introductory statistics course. For this example we use the following data:
The original data have been slightly edited. Some people are outliers when
age is concerned. They have been filtered out. H Note: Since we have no indication about a direction for any difference in age, when comparing females and males, we perform a two-tailed test here. The second difference to investigate is between people who were born in
Europe and people not born in Europe. H ## An interesting observationOne of the questions of our little survey is: Were you born in Europe? Yes / No. This sounds simple enough. What could possibly go wrong
with it? Do you see any flaws in this question? ## Asking for the test using SPSS
## The SPSS output for age by gender
## Checking the equality of variances conditionThe original t-test assumed that the variable had equal variances for the two
populations you wanted to compare. Later an extention has been deviced where
this equality no longer was necessary. But to achieve this the formulas for the
test statistic and the degrees of freedom of its t-distribution under H H The Levene significance = 0.526 in our case, so we will
stick with H Note: Looking at the Group Statistics in the output we see the standard deviations 2.063 (for females) and 1.965 (for males). There are almost equal, but we all know that small differences can nevertheless be statistically significant. So we need the test as well. ## Interpreting the rest of the output for age by genderWe now know we can use the part labeled "Equal variances assumed". It gives us a two-tailed significance for the t-test of 0.877. Our conclusion is clear. There are no indications that the average ages for female and male foundation year students at ABS are different. The 95% confidence interval for the difference tells us that it is between -0.39 and +0.33 years. ## The SPSS output for age by "born where?"We now come to the output for our second t-test. This one is formulated as one-tailed. We hypothesized that students coming from far away (from outside Europe) will be on average older than the students from Europe. Let's see what the data tells us.
## Interpreting the output for age by "born where?"Since we are dealing with a one-tailed test first of
all we have to check whether or not the sample data is
consistent with H Looking at the Levene test, we find a significance of 0.050. This is quite small; we play it save and reject the equality of variances. We will use the output from the line "Equal variances not assumed". The two-tailed significance = 0.045. Hence the one-tailed
significance = ½·0.045 = 0.0225. This is small
enough to reject H Conclusion: There is considerable evidence that the average age for students not born in Europe is indeed higher than for the Europeans. We can add to this the 95% confidence interval for the difference: On average the foundation year students from ABS not born in Europe are between 0.01 and 0.74 years older than the European born ones. The mean difference in age is 0.37 years. ## Graphical display of the resultsWe are interested in differences in average age. And we have seen above that the variance of the dependent variable plays a role as well. To depict this situation an error bar chart is well suited. We choose it from the Legacy Dialogs:
These pictures speak for themselves and nicely visualize our findings from the t-tests. |

Last modified
30-10-2012
© Jos Seegers, 2009; English version by Gé Groenewegen. |