A t-test compares the difference between two means of different groups to determine whether that difference is statistically significant. There are three types of t-tests: one-sample, independent-samples, and paired-samples.
A one sample t-test compares the mean of one sample to a fixed estimate, usually 0. A significant result indicates that the group's mean differs from the fixed value.
1) Normality: Assumes that the population distribution is normal. The t-test is quite robust over moderate violations of this assumption. Check for normality by creating a histogram.
2) Independent observations: The observations within the treatment must be independent.
1) Click "Compare Means" in the "Analyze" menu.
2) Select "One-Sample T-test..." from this menu.
3) As seen in Figure 4.1, select the variable you wish to test. Make sure you have set the test value to the appropriate number for your analysis. For instance, below we are comparing the mean for Question 1 with the midpoint on that question (5). Often, the test value will simply be zero.
Figure 4.1 One-Sample T-Test
4) Click "OK."
This test will give you the mean and standard deviation of the sample in its first table. The second table, shown in Figure 4.2, gives you the information about the t-test.

Figure 4.2 Output from One-Sample T-Test
Be sure to include: The difference you are observing, the values of that difference, the t-value and its degrees of freedom, and the p-value.
An independent sample t-test compares the means of two independent groups. e.g. data from two different groups of participants. The null hypothesis would be that the means are the same. A low p-value (indicating a sufficiently large difference between groups) would suggest that you reject the null hypothesis and conclude that the two groups are significantly different.
1) Normality: Assumes that the population distributions are normal. The t-test is quite robust over moderate violations of this assumption. It is especially robust if a two-tailed test is used and if the sample sizes are not especially small. Check for normality by creating a histogram.
2) Independent Observations: The observations within each treatment condition must be independent.
3) Equal Variances: Assume that the population distributions have the same variances. This assumption is quite important (if it is violated, it makes the test's averaging of the 2 variances meaningless). If it is violated, then use a modification of the t-test procedure as needed. See "Understanding the output" in this section for how to check this with Levene's Test for Equality of Variances.
1) Click "Compare Means" in the "Analyze" menu.
2) Select "Independent Samples T-test..." from this menu.
3) As seen in Figure 4.3, select the variable you wish to test and place in the "test variable" box. In our example, we are testing a mean difference in hours of work done per night between first year students and seniors.

Figure 4.3 Independent-Samples T-Test
4) Next, select the grouping variable and place it in the "grouping variable" box. Notice the question marks next to the grouping variable in Figure 3.12. This indicates that we still need to assign the specific groups to be compared.
5) Click on "Define Groups", which will open this window (Figure 4.4).

Figure 4.4 Define Groups Window for Independent-Samples T-test
Assign the appropriate group labels, based on what you entered in the variable view. Here, first year students were entered as "1" and seniors as "4." Click "Continue."
6) Now that your groups are defined, the question marks should be gone and you are able to click "OK".
This test will give you the mean and standard deviation of each of the two samples in its first table. The second table (Figure 4.5) gives you the information about the t-test. Use the "equal variances assumed" row.

Figure 4.5 Output from Independent-Samples T-test
The Levene's Test for Equality of Variances tests whether the variances from your two samples are different - a p-value of less than .05 means that they are probably different and you should use another test or modify this one. A value of greater than .05, such as in this example, means you've met your assumption of equal variances - good work!
Be sure to include: The difference you are observing, the values of that difference, the t-value and its degrees of freedom, and the p-value.
This t-test evaluates two groups that are related to each other. For example, data from a group of participants who are tested before and after a procedure would be analyzed using a paired sample t-test.
1) Normality: Assumes that the population distribution is normal. The t-test is quite robust over moderate violations of this assumption. Check for normality by creating a histogram.
2) Independent observations: The observations within each treatment must be independent.
This t-test evaluates two groups that are related to each other. For example, data from a group of participants who are tested before and after a procedure would be analyzed using a paired sample t-test.
1) Click "Compare Means" in the "Analyze" menu.
2) Select "Paired Samples T-test..." from this menu.
3) As seen in Figure 4.6, select the two variables you wish to pair (usually a T1 and a T2) and place then in the "paired variables" box. In our example, lets assume that Question 1 was asked before the experimental procedure and Question 10 was asked afterwards. Therefore, we are testing a mean difference between the answers to Question 1 and Question 10.

Figure 4.6 Paired-Samples T-test
4) Click "OK" and your test will appear in the SPSS viewer.
This test will give you the mean and standard deviation of each of the two samples in its first table. In its second table, it runs a correlation between the two variables to see how much they are related to each other; the "correlation" value is the r-value, and "sig." is the p-value. The third table, shown in Figure 4.7, gives you the information about the t-test.

Figure 4.7 Output from Paired-Samples T-test
Be sure to include: The difference you are observing, the values of that difference, the t-value and its degrees of freedom, and the p-value