Ismail Aby Jamal

Ismail Aby Jamal
I say man, am I leader...

Thursday, January 28, 2010

One-Way Independent Samples ANOVA with SPSS

One-Way Independent Samples ANOVA with SPSSã
Download the data file ANOVA1.sav from my SPSS data page. These are contrived data (I created them with a normal random number generator in the SAS statistical package). We shall imagine that we are evaluating the effectiveness of a new drug (Athenopram HBr) for the treatment of persons with depressive and anxiety disorders. Our independent variable is the daily dose of the drug given to such persons, and our dependent variable is a measure of these persons' psychological illness after two months of pharmacotherapy. We have 20 scores in each of five treatment groups.
Bring the data file, ANOVA1.SAV, into SPSS. To do the analysis click Analyze, Compare Means, One-Way ANOVA. Scoot Illness into the Dependent List box and Dose into the Factor box. Click Contrasts, check Polynomial, and select Degree = 4th. Click Continue. Click Post Hoc, check Bonferroni and REGWQ. There are many other pairwise procedures available here too. Click Continue. Click Options and select Descriptive Statistics and Means Plot. Click Continue, OK.
At the bottom of the output is a plot of the means. Take a look at the plot. It appears that the drug is quite effective with 10 and 20 mg doses, but that increasing the dosage beyond that reduces its effectiveness (perhaps by creating problems opposite to those it was intended to alleviate). With data like these, a “trend analysis” would be advised. In such an analysis one attempts to describe the relationship between the independent and dependent variables in terms of a polynomial function. If you remember polynomials from your algebra course, you will recognize that a quadratic function (one with one bend in the curve) would fit our data well. By selecting polynomial contrasts we get, along with the one-way ANOVA, a test of how well a polynomial model fits the data. I selected degree = 4th to get a test not only of a quadratic model but also of more complex (cubic and quartic) polynomial models. The highest degree one can select is k-1, where k is the number of levels of the independent variable.
The descriptive statistics at the top of the output reveal considerable differences among the group standard deviations, but Fmax (ratio of largest group variance to smallest group variance) remains below 4, so we are OK with the homogeneity of variance assumption.
The ANOVA clearly shows that dose is significantly related to illness (between groups p < .001). The trend analysis shows that there is no significant linear relationship between dose and illness (p = .147), but that higher order polynomial trends (quadratic, cubic, and quartic) would account for a significant proportion of the variance in illness (deviation p < .001). The quadratic trend is large (h2 = 6100.889/14554.24 = 42%) and significant (p < .001). The "deviation" test shows us that cubic (which would allow two bends in the curve relating dose to illness) and quartic (three bends) trends (combined) would account for a significant additional proportion of the variance in illness (deviation p = .047). The cubic trend is significant (p = .032), but accounts for so little of the variance in illness (h2 = 389.205/14554.24 = 3%) that it is not of great importance. The quartic (4th order) trend is trivial and not significant. Please do note that if my independent variable were qualitative rather than continuous, then a trend analysis would not be appropriate and I would not have asked for one – I would still get the standard analysis.
Under the title of Post Hoc Tests, SPSS reports first the results of the Bonferroni tests. Each row in this table represents the difference between the mean illness at one dosage and the mean illness at another dosage. The Sig. column tells you whether the difference is significant or not and then you are given a confidence interval for the difference. All of the differences are significant with the exception of 0 mg vs 40 mg, 10 mg vs 20 mg, and 10 mg vs 30 mg.
The results of the REGWQ test are presented in a different format. The table under the title Homogeneous Subsets shows that the mean for 20 mg does not differ significantly from that for 10 mg and the mean for 0 mg does not differ significantly from that for 40 mg. Although not covered in Howell's Fundamentals textbook, the REGWQ is my recommendation for the pairwise comparison procedure to employ in almost all cases where you have more than three groups – but you cannot really do it by hand, you have to use a computer. If you have only three groups, your best choice is to use Fisher's LSD procedure. With four or more groups I strongly recommend the REGWQ.
The overall h2 is computed by hand by taking the among groups sums of squares and dividing by the total sums of squares. This estimates the proportion of the variance in the criterion variable which is “explained” by the grouping variable. You should report both the point estimate of that proportion and also put a 95% confidence interval about it.
Below is an example of how to write up these results. While the underlining means method of presenting pairwise comparisons is dandy when you are writing by hand, it is cumbersome when you are using a word processor, and you never see it in published manuscripts. Instead, I present such results in a table, using superscripts to indicate which means differ significantly from which other means. I chose to present the results of the Bonferroni test rather than the REGWQ test, because the pattern of results from the Bonferroni test are more complex and I wanted to show you how to present such complex results.
An analysis of variance indicated that dose of Athenopram significantly affected psychological illness of our patients, F(4, 95) = 20.78, MSE = 81.71, p < .001, h2 = .47, CI.95 = .30, .56. As shown in Table 1, Bonferroni tests indicated that low doses of the drug were associated with significantly better mental health than were high doses or placebo treatment. A trend analysis indicated that the data were well fit by a cubic model with the quadratic component accounting for a large and significant proportion of the variance in illness (h2 = .42, p < .001) and the cubic trend accounting for small but significant proportion of the variance (h2 = .03, p = .032).

Table 1
Psychological Illness of Patients
As a Function of Dose of Athenopram
Dose (mg)
M
SD
40
101.8A
10.66
0
100.8A
8.82
30
92.5B
7.24
10
85.0BC
11.01
20
81.1C
6.60
Note. Means with the same letter in their superscripts do not differ significantly from one another according to a Bonferroni test with a .05 limit on familywise error rate.
Please see my document Using SPSS to Obtain a Confidence Interval for R2 From Regression. Here are screen shots showing how I got the confidence interval for eta-squared.
Copyright 2006, Karl L. Wuensch - All rights reserved.
ã Copyright 2006, Karl L. Wuensch - All rights reserved.

No comments: