FAQ/polybs - CBU statistics Wiki

Revision 10 as of 2011-11-23 12:40:10

Clear message
location: FAQ / polybs

How do I test for a trend between group means representing different subjects?

Let us suppose we wish to test for a linear trend between between subjects group means. This can be done using polynomial coefficients

ONEWAY
  OUTCOME BY GROUP
  /POLYNOMIAL= 1
  /MISSING ANALYSIS .

In the case of unequal group sizes SPSS produces two outputs called weighted and unweighted sums of squares. The weighted sums of squares assumes group sizes are important for example to reflect relative sizes of each group in the general population. Unweighted sums of squares ignore differences in group sizes and compares group means using the same average group size for each group so each group contributes equally to the trend analysis.

To illustrate the use of unweighted means suppose we have three group means 2.333, 2.00 and 2.50 with respective group sizes 3, 4 and 4 and we wish to see if there is a linear trend. Using the polynomial coefficients this is akin to using a contrast to test if there is a difference between the first and third group means. From Boniface (1995)

SS(linear contrast) = Harmonic mean x (difference in first and third group means $$\text^2$$)/ (sum of the squares of the contrast coefficients) where

$$ \mbox{Harmonic mean} = \frac{3}{\frac{1}{3} + \frac{1}{4} + \frac{1}{4}} = 3.6.$$

Unweighted SS(linear contrast) = 3.6 (2.333-2.5)(2.333-2.5)/(1 + 1) = 0.050.

The SS(error) which is divided into SS(contrast) to give a F ratio is equal to SQRT[ SUM OF SQUARES OF CONTRAST COEFFS X MSE/N PER GROUP] = SQRT [ (32 + 12 + 12 + 12) 2.139/10 = 1.60.

Alternatively a t-test on N-k degrees of freedom of the contrast divides 0.5(mean1 - mean3) by its standard error. The standard error of the contrast is given by MSE $$\sqrt{\sum_text{i}\frac{c^text{2}_text{i}}{n_text{i}}}$$ where $$c_{i}$$ is the i-th contrast coefficient for the i-th mean based on a sample size of $$n_{i}$$ for each of k groups. In the above example t on (40-4) df = 0.5(2.333-2.5) / sqrt(MSE (1/3 + 1/4) ) = sqrt(2.139 [0.583]) = 1.335 giving a t(36) = -0.084/1.335 = -0.063.

For further discussion on the differences between weighted and unweighted analyses see the first half of Amy Shelton's excellent on-line tutorial given in a pdf file located [http://www.psy.jhu.edu/~ashelton/courses/stats315/week9.pdf here.] If the link is broken the file containing the tutorial can be accessed from [attachment:weights.pdf here.]

Note that linear and higher order trend tests are performed by SPSS in repeated measures ANOVA by default using the GLM procedure (see Post-hoc Grad talk for further details [http://imaging.mrc-cbu.cam.ac.uk/statswiki/StatsCourse2010 here]). Trend tests may be carried out without a significant overall F as it looks at a specific relationship between group means which is not tested by the overall F test in the ANOVA. Trend tests are usually planned (apriori) comparisons. A further explanation about the difference between a group trend and an overall group comparison is given [:FAQ/ltrend: here.]

Reference

Boniface DR (1995) Experiment design and statistical methods for behavioural and social research. Chapman and Hall:London. This book is available in the CBU library.