Reading: SPSS Advanced Models 9.0: 2. Repeated
Measures
Download: glm_w2b1.sav (Download Tips)
![]()
In the earlier notes on repeated measures designs we looked at a design with a single within subject factor and at a design with one within- and one between-subjects factors. In this set of notes we look a design with two within-subjects factors and 1 between-subjects factor.
The data for this set of notes comes from a study of the therapeutic effects of verbally disclosing thoughts and feelings about the loss of a spouse (Segal, Bogaards, Becker, and Chatman, in press). The participants were 30 (7 males and 23 females) older adults (M age = 67.0, range = 51 to 85). The research design was a delayed treatment design. Participants randomly assigned to the treatment condition participated in four 20-minute sessions within a 2-week period. In each session the participant was asked to talk about the loss of their spouse and to express their deepest thoughts and feelings for the entire 20 minutes. The experimental sessions were conducted in the participants home. The participants completed an array of psychological measures prior to treatment (T1), immediately post treatment (T2) and at 1-month following treatment (T3). Participants randomly assigned to the delayed treatment completed the same array of measures, however treatment occurred for the delayed treatment group between T2 and T3 and they were again tested (T4) at 1-month following T3.
The analysis we will be looking at are a set of "process" measures that looked at the mood of the participant at the beginning and end of each of the four disclosure sessions. The process measures included the Positive and Negative Affect Schedule (PANAS, Watson, Clark, & Tellegen, 1988), and a self-report scale that asked, "How painful is it for you to think about the death of your spouse right now?" We will be looking at the Negative Affect scale of the PANAS. The design for the process measures is shown in Table 1. The design of the study is a 2 x 4 x 2 ANOVA with gender (male vs. female) as a between subjects factor and session number (1 vs. 2 vs. 3 vs. 4) and prepost (beginning of the session vs. end of the session) as within subject factors.
| Session 1 | Session 2 | Session 3 | Session 4 | |||||
|---|---|---|---|---|---|---|---|---|
| Gender: | Beginning | End | Beginning | End | Beginning | End | Beginning | End |
| Male | ||||||||
| Female | ||||||||
The data are stored in the file glm_w2b1.sav. Both the negative and positive affect PANAS scores are included in the data file. The eight negative affect scores of the PANAS are shown in Table 2 along with the age and gender variables. Note that the order of the variables in the datafile do not match the order of the variables in Table 2.
Note the structure used to name the dependent variables. The first three letters, PAN, indicate the PANAS scale. The next three letters, PRE or POS, indicate whether this is a presession or a postsession score. The next to the last letter, N or P, indicates whether the score is the negative or positive subscore of the PANAS. The last digit, 1, 2, 3, or 4, indicates the session number.
| Variable Name | Variable Label / Value Label |
|---|---|
| age | Age of the participant in years |
| gender | Gender of the participant / 1 = male, 2 = female |
| PANPREN1 | negative PANAS, presession at session 1 |
| PANPSTN1 | negative PANAS, postsession at session 1 |
| PANPREN2 | negative PANAS, presession at session 2 |
| PANPSTN2 | negative PANAS, postsession at session 2 |
| PANPREN3 | negative PANAS, presession at session 3 |
| PANPSTN3 | negative PANAS, postsession at session 3 |
| PANPREN4 | negative PANAS, presession at session 4 |
| PANPSTN4 | negative PANAS, postsession at session 4 |
The GLM Repeated Measures dialog box is opened by clicking
Analysis
General Linear Model
Repeated
Measures...
In this design there are two within-subjects factors, sessions with four levels and prepost with 2 levels. The 2 within-subject factors make up a 4 x 2 within-subjects design. There are eight within-subjects cells. The eight scores are the measures for each of the eight-within subjects cells. You need to tell SPSS how the eight measures are related to the eight cells in the 4 x 2 within-subjects design.
The within-subject factors are defined in the opening window. Enter the first factor, session, in the Within-Subjects Factor Name: window, enter 4 in the Number of Levels: window and then Add the factor to the window that lists the within-subject factors.. Do the same for the prepost factor : enter the factor name, prepost, and then enter 2 for the number of levels.
| The factor window should look like this: |
|
|
| You could also define the measure as, for example, PANAS_ng |
Press Define to go to the next dialog box. The Within-Subjects Variables (session, prepost): window has spaces for eight variables. They correspond to the eight cells in the 4 x 2 within subjects design. The numbers after each variable identify the specific combinations of the session*prepost design. As indicated in the heading "(session, prepost)" the first index is the counter for the session factor and the second index is the counter for the prepost variable. Hence the first variable, __?__(1,1,panas_ng), is the session = 1, prepost = 1 variable, PANPREN1. The second variable, __?__(1,2,panas_ng) is the session = 1, prepost = 2 variable, PANPOSN1. The third variable, __?__(2,1,panas_ng) is the session = 2, prepost = 1 variable, PANPREN2, and so forth. The variables in the variable list are not ordered in the same way as they need to be entered into the within-subjects window. You will have to pay careful attention to how you enter those variables. |
|
| After moving the variables to their appropriate places the Within-Subjects Variables (session,prepost): window should look like this: |
|
Move the gender factor to the Between-Subjects Factors(s): window.
Lets look at the effect sizes: Options... Display, Estimates of effect size.
And the descriptive statistics: Options... Display, Descriptive Statistics.
It is unlikely that the orthogonal polynomial contrasts will be useful in interpreting any significant effects so lets selects the "Repeated" contrasts for the session within subject effect: Contrasts... then highlight session[polynomial], then change contrast to Repeated, press Change and then press Continue to exit the contrast dialog box.
| The output displays the within- and between subject factors, as shown in Tables 3 and 4, respectively. | Table 3. Within-Subjects Factors Measure: PANAS_NG
|
Table 4. Between-Subjects Factors
|
The tests of sphericity for each of the within subject effects are shown in Table 5.
| Table 5. Mauchly's Test of Sphericity Measure: PANAS_NG
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 layers (by default) of the Tests of Within Subjects Effects table. b Design: Intercept+GENDER Within Subjects Design: SESSION+PREPOST+SESSION*PREPOST |
There is no sphericity problem for the session main effect, Mauchly's W (5) = 5.378, p = .372. We will look at the "sphericity assumed" row the of the output for any effects tested by the "session" error term.
The prepost effect has only 1 degree of freedom so the sphericity test is not relevant. SPSS recognizes that is not relevant by providing a Mauchly's test value of 1.00 with 0 df, and all epsilon values equal to 1.00. We will look at the "sphericity assumed" row of the output for any effects tested by the "prepost" error term.
There is a small sphericity problem for the session by prepost interaction, Mauchly's W (5) = 12.724, p = .026. We will use the Huynh-Feldt epsilon correction when looking at the values for any effect tested by the "session by prepost" error term.
The univariate ANOVA table for the within-subjects effects are shown in Table 6.
Table 6. Tests of Within-Subjects Effects
Measure: PANAS_NG
Source |
Type III Sum of Squares |
df |
Mean Square |
F |
Sig. |
Eta Squared |
|
SESSION |
Sphericity Assumed |
60.366 |
3 |
20.122 |
1.095 |
.356 |
.039 |
Greenhouse-Geisser |
60.366 |
2.704 |
22.326 |
1.095 |
.353 |
.039 |
|
Huynh-Feldt |
60.366 |
3.000 |
20.122 |
1.095 |
.356 |
.039 |
|
Lower-bound |
60.366 |
1.000 |
60.366 |
1.095 |
.305 |
.039 |
|
SESSION * GENDER |
Sphericity Assumed |
419.142 |
3 |
139.714 |
7.600 |
.000 |
.220 |
Greenhouse-Geisser |
419.142 |
2.704 |
155.016 |
7.600 |
.000 |
.220 |
|
Huynh-Feldt |
419.142 |
3.000 |
139.714 |
7.600 |
.000 |
.220 |
|
Lower-bound |
419.142 |
1.000 |
419.142 |
7.600 |
.010 |
.220 |
|
Error(SESSION) |
Sphericity Assumed |
1489.108 |
81 |
18.384 |
|||
Greenhouse-Geisser |
1489.108 |
73.005 |
20.397 |
||||
Huynh-Feldt |
1489.108 |
81.000 |
18.384 |
||||
Lower-bound |
1489.108 |
27.000 |
55.152 |
||||
PREPOST |
Sphericity Assumed |
479.493 |
1 |
479.493 |
16.698 |
.000 |
.382 |
Greenhouse-Geisser |
479.493 |
1.000 |
479.493 |
16.698 |
.000 |
.382 |
|
Huynh-Feldt |
479.493 |
1.000 |
479.493 |
16.698 |
.000 |
.382 |
|
Lower-bound |
479.493 |
1.000 |
479.493 |
16.698 |
.000 |
.382 |
|
PREPOST * GENDER |
Sphericity Assumed |
163.510 |
1 |
163.510 |
5.694 |
.024 |
.174 |
Greenhouse-Geisser |
163.510 |
1.000 |
163.510 |
5.694 |
.024 |
.174 |
|
Huynh-Feldt |
163.510 |
1.000 |
163.510 |
5.694 |
.024 |
.174 |
|
Lower-bound |
163.510 |
1.000 |
163.510 |
5.694 |
.024 |
.174 |
|
Error(PREPOST) |
Sphericity Assumed |
775.343 |
27 |
28.716 |
|||
Greenhouse-Geisser |
775.343 |
27.000 |
28.716 |
||||
Huynh-Feldt |
775.343 |
27.000 |
28.716 |
||||
Lower-bound |
775.343 |
27.000 |
28.716 |
||||
SESSION * PREPOST |
Sphericity Assumed |
66.846 |
3 |
22.282 |
2.143 |
.101 |
.074 |
Greenhouse-Geisser |
66.846 |
2.339 |
28.577 |
2.143 |
.118 |
.074 |
|
Huynh-Feldt |
66.846 |
2.670 |
25.039 |
2.143 |
.109 |
.074 |
|
Lower-bound |
66.846 |
1.000 |
66.846 |
2.143 |
.155 |
.074 |
|
SESSION * PREPOST * GENDER |
Sphericity Assumed |
113.519 |
3 |
37.840 |
3.639 |
.016 |
.119 |
Greenhouse-Geisser |
113.519 |
2.339 |
48.530 |
3.639 |
.026 |
.119 |
|
Huynh-Feldt |
113.519 |
2.670 |
42.522 |
3.639 |
.020 |
.119 |
|
Lower-bound |
113.519 |
1.000 |
113.519 |
3.639 |
.067 |
.119 |
|
Error(SESSION*PREPOST) |
Sphericity Assumed |
842.179 |
81 |
10.397 |
|||
Greenhouse-Geisser |
842.179 |
63.157 |
13.335 |
||||
Huynh-Feldt |
842.179 |
72.081 |
11.684 |
||||
Lower-bound |
842.179 |
27.000 |
31.192 |
There are several significant within-subjects effects: the session by gender interaction, F(3, 81) = 7.60, p < .0005, h 2 = .22; the prepost main effect, F(1, 27) = 16.70, p < .0005, h 2 = .38; the prepost by gender interaction, F(1, 27) = 5.69, p = .024, h 2 = .17; and the session by prepost by gender interaction, F(2.670, 72.081) = 3.64, p = .020, h 2 = .22. Note that the Huynh-Feldt corrected degrees of freedom were used when describing the 3-way interaction because the 3-way interaction includes the session by prepost effect, which was deemed to have a sphericity problem.
The ANOVA table for the between-subjects effects are shown in Table 7.
Table 7. Tests of Between-Subjects Effects
Measure: PANAS_NG
Transformed Variable: Average
Source |
Type III Sum of Squares |
df |
Mean Square |
F |
Sig. |
Eta Squared |
Intercept |
21806.641 |
1 |
21806.641 |
171.735 |
.000 |
.864 |
GENDER |
63.102 |
1 |
63.102 |
.497 |
.487 |
.018 |
Error |
3428.422 |
27 |
126.979 |
There are no significant between-subject effects of interest.
The general approach to interpreting ANOVA effects are to begin with the highest order interaction. In our case it is the 3-way interaction. The descriptive statistics are shown in Table 8. The estimated marginal means for the 3-way interaction are shown in Table 9. And the profile plots are shown in Figure 1.
Table 8. Descriptive Statistics
gender of participant |
Mean |
Std. Deviation |
N |
|
panas negative pre score at vocal session 1 |
male |
22.43 |
5.32 |
7 |
female |
23.00 |
10.12 |
22 |
|
Total |
22.86 |
9.11 |
29 |
|
panas negative post score at vocal session 1 |
male |
23.29 |
6.07 |
7 |
female |
24.73 |
10.78 |
22 |
|
Total |
24.38 |
9.77 |
29 |
|
panas negative pre score at vocal session 2 |
male |
20.57 |
4.79 |
7 |
female |
20.86 |
9.24 |
22 |
|
Total |
20.79 |
8.30 |
29 |
|
panas negative post score at vocal session 2 |
male |
26.29 |
11.25 |
7 |
female |
22.64 |
8.76 |
22 |
|
Total |
23.52 |
9.34 |
29 |
|
panas negative pre score at vocal session 3 |
male |
19.57 |
7.00 |
7 |
female |
20.18 |
7.58 |
22 |
|
Total |
20.03 |
7.33 |
29 |
|
panas negative post score at vocal session 3 |
male |
25.43 |
11.66 |
7 |
female |
21.77 |
9.06 |
22 |
|
Total |
22.66 |
9.65 |
29 |
|
panas negative pre score at vocal session 4 |
male |
22.29 |
8.06 |
7 |
female |
18.91 |
6.97 |
22 |
|
Total |
19.72 |
7.25 |
29 |
|
panas negative post score at vocal session 4 |
male |
31.14 |
13.01 |
7 |
female |
19.41 |
7.16 |
22 |
|
Total |
22.24 |
10.04 |
29 |
Table 9. Estimated Marginal Means for Gender of participant * SESSION * PREPOST
Measure: PANAS_NG
Mean |
Std. Error |
95% Confidence Interval |
||||
gender of participant |
SESSION |
PREPOST |
Lower Bound |
Upper Bound |
||
male |
1 |
1 |
22.429 |
3.505 |
15.237 |
29.620 |
2 |
23.286 |
3.751 |
15.588 |
30.983 |
||
2 |
1 |
20.571 |
3.196 |
14.014 |
27.129 |
|
2 |
26.286 |
3.542 |
19.019 |
33.552 |
||
3 |
1 |
19.571 |
2.818 |
13.789 |
25.354 |
|
2 |
25.429 |
3.664 |
17.910 |
32.947 |
||
4 |
1 |
22.286 |
2.731 |
16.683 |
27.889 |
|
2 |
31.143 |
3.326 |
24.319 |
37.966 |
||
female |
1 |
1 |
23.000 |
1.977 |
18.943 |
27.057 |
2 |
24.727 |
2.116 |
20.385 |
29.069 |
||
2 |
1 |
20.864 |
1.803 |
17.165 |
24.562 |
|
2 |
22.636 |
1.998 |
18.537 |
26.735 |
||
3 |
1 |
20.182 |
1.590 |
16.920 |
23.443 |
|
2 |
21.773 |
2.067 |
17.532 |
26.014 |
||
4 |
1 |
18.909 |
1.540 |
15.749 |
22.069 |
|
2 |
19.409 |
1.876 |
15.560 |
23.258 |
I don't know about you, but I find it difficult to see what is happening in the 3-way interaction by just looking at the table of means. Back in the old days, prior to running SPSS for windows, my first instinct was to get out a piece of graph paper and plot the means. Fortunately, the profile plots procedure will that for us.
If you have an apriori hypothesis that involves an interaction, then the interpretation of the interaction should be informed by that hypothesis. If the interaction was not predicted, as in this instance, then you should look about your data from multiple perspectives. You may find that one perspective is better than the others at capturing the meaning of the interaction.
The essence of a three-way interaction is that the two-way interaction is not the same under each level of the third factor. There are several possibilities here, you could look at the A x B interaction at each level of C, A x C interaction at each level of B, or the B x C interaction at each level of A. In addition, for each of the two-way interactions, you could place one factor on either the horizontal or vertical axis. Thus, for a three-way interaction there are 6 different ways to construct the profile plots.
In addition to looking at the various plots, you should think about the simple, simple main effects, and how they might be used to explain the interaction. For this three-way interaction there are three simple, simple main effects, the simple simple main effects of session, of prepost and of gender.
The profile plots in Figure 1 were created by selecting session as the horizontal axis variable, prepost as the separate lines variable, and gender as the separate plots variable (i.e., A x B within C).
| /PLOT = PROFILE(session*prepost*gender ) |
Plotting gender as separate plots focuses the readers attention on the session by prepost interaction within each gender. The relevant simple, simple main effects are session and prepost, the 2-way interaction factors.
| /EMMEANS = TABLES(gender*session*prepost)
COMPARE(session) ADJ(Sidak) /EMMEANS = TABLES(gender*session*prepost) COMPARE(prepost) ADJ(Sidak) |
For males, negative affect at the beginning of the session tended to decrease across the first three sessions and then increased at the fourth session. Negative affect at the end of the session tended to increase across all four sessions. This interpretation could be statistically tested by looking at the simple main effects of session and the relevant pairwise comparisons.. The change in affect from the beginning to the end of the session tended to increase across the four sessions. This interpretation could be statistically tested by looking at the simple main effects of prepost.
For females, negative affect decreased across sessions. This decrease occurred both at the beginning of the session and at the end of the session. This observation could be statistically tested by looking at the simple main effects of session and the relevant pairwise comparisons. At the first session, there may have been a small increase in negative affect from the beginning to the end of the session. By the fourth session there was very little increase in negative affect from the beginning to the end of the session. This interpretation could be statistically tested by looking at the simple, simple main effects of prepost.
Figure 1. Profile plots of the session by prepost by gender interaction means.
![]() |
![]() |
The profile plots in Figure 2 use session as the horizontal axis, gender as the separate lines variable, prepost as the separate plots variable (i.e., A x C within B).
| /PLOT = PROFILE(session*gender*prepost ) |
Plotting the pre- and postsession scores as separate plots focuses the readers attention on the gender by session interaction. The relevant simple, simple main effects are session and gender, the 2-way interaction factors.
| /EMMEANS = TABLES(gender*session*prepost)
COMPARE(session) ADJ(Sidak)) /EMMEANS = TABLES(gender*session*prepost) COMPARE(gender) ADJ(Sidak) |
Negative affect scores at the beginning of each session tended to decrease for both males and females across the first three sessions. At the fourth session the negative affect scores for females continued to decrease, but for males there was an increase in negative affect at the beginning of the fourth session. These observations could be statistically tested by looking at the simple main effects of session and the relevant pairwise comparisons. There were no gender differences at the beginning of each of the first three sessions. At the fourth session males reported more negative affect at the beginning of the session than did the females. These observations could be tested by the simple, simple main effects of gender.
Negative affect scores at the end of each session tended to increase for males across the four sessions and to decrease for females across the four sessions. These observations could be statistically tested by looking at the simple main effects of session and the relevant pairwise comparisons. There were little or no gender differences at the end of session 1. Negative affect scores at the end of the session tended to be higher for males than females at sessions 2, 3 and 4, with the largest difference occurring at session 4. These observations could be tested by the simple, simple main effects of gender.
Figure 2. Profile plots of the session by gender by prepost interaction means.
![]() |
![]() |
The profile plots in Figure 3 use prepost as the horizontal axis variable, gender as the separate lines variable and session as the separate plots variable (i.e., B x C within A).
| /PLOT = PROFILE(prepost*gender*session ) |
Plotting the session as separate plots focuses the readers attention on the prepost by gender interaction. The relevant simple, simple main effects are prepost and gender, the 2-way interaction factors.
| /EMMEANS = TABLES(gender*session*prepost)
COMPARE(prepost) ADJ(Sidak) /EMMEANS = TABLES(gender*session*prepost) COMPARE(gender) ADJ(Sidak) |
The interpretation of these four prepost by gender interactions within sessions is possible. But, I don't even want to write up the possibilities for these notes. Either of the previous two ways seem like better options to me. What do you think?
Figure 3. Profile plots of the prepost by gender by session interaction means.
![]() |
![]() |
![]() |
![]() |
The syntax commands that were to create the three sets of plots (see the /PLOT syntax) and the simple, simple main effects for session, prepost, and gender (see the /EMMEANS syntax) are shown below --
| GLM panpren1 panpstn1 panpren2 panpstn2 panpren3 panpstn3 panpren4 panpstn4 BY gender /WSFACTOR = session 4 Repeated prepost 2 Polynomial /MEASURE = panas_ng /METHOD = SSTYPE(3) /PLOT = PROFILE(session*prepost*gender session*gender*prepost prepost*gender*session) /EMMEANS = TABLES(gender*session*prepost) COMPARE(session) ADJ(Sidak) /EMMEANS = TABLES(gender*session*prepost) COMPARE(prepost) ADJ(Sidak) /EMMEANS = TABLES(gender*session*prepost) COMPARE(gender) ADJ(Sidak) /PRINT = DESCRIPTIVE ETASQ /CRITERIA = ALPHA(.05) /WSDESIGN = session prepost session*prepost /DESIGN = gender . |
The multivariate tests of the simple, simple main effects of session within each combination of prepost and gender are shown in Table 10. The table has been modified to present only the F test (the redundant multivariate tests have been omitted).
Table 10. Multivariate Tests
for the Simple, Simple Main Effects of Session
Each F tests the multivariate simple effects of SESSION within each level combination of the other effects shown. These tests are based on the linearly independent pairwise comparisons among the estimated marginal means. a Exact statistic |
The pairwise comparisons for the simple, simple main effects of session are shown in Table 11.
| Table 11. Pairwise Comparisons
for the Simple, Simple Main Effects of Session. Measure: PANAS_NG
|