User Guide

114
Appendix A
Difference
Difference or reverse Helmert contrasts. Compares categories of an independent variable
with the mean of the previous categories of the variable. The general matrix form is
where k is the number of categories for the independent variable. For example, the
difference contrasts for an independent variable with four categories are as follows:
Polynomial
Orthogonal polynomial contrasts. The first degree of freedom contains the linear effect
across all categories; the second degree of freedom, the quadratic effect; the third
degree of freedom, the cubic; and so on for the higher-order effects.
You can specify the spacing between levels of the treatment measured by the given
categorical variable. Equal spacing, which is the default if you omit the metric, can be
specified as consecutive integers from 1 to k, where k is the number of categories. If
the variable drug has three categories, the subcommand
/CONTRAST(DRUG)=POLYNOMIAL
is the same as
/CONTRAST(DRUG)=POLYNOMIAL(1,2,3)
Equal spacing is not always necessary, however. For example, suppose that drug
represents different dosages of a drug given to three groups. If the dosage administered
to the second group is twice that to the first group and the dosage administered to the
mean ( 1/k 1/k 1/k ... 1/k )
df(1) ( –1 1 0 ... 0 )
df(2) ( –1/2 –1/2 1 ... 0 )
..
..
df(k–1) ( –1/
(k–1) –1/(k–1) –1/(k–1) ... 1 )
( 1/4 1/4 1/4 1/4 )
(1100 )
(–1/2 –1/2 1 0 )
(–1/3 –1/3 –1/3 1 )