Analysis of Variance for Fixed Effect Models


PROC GLM for General Linear Models

The GLM procedure is the flagship tool for analysis of variance in SAS/STAT software. It performs analysis of variance by using least squares regression to fitgeneral linear models, as described in the section 'General Linear Models' on page 62. Among the statistical methods available in PROC GLM are regression, analysis of variance, analysis of covariance, multivariate analysis of variance, and partial correlation.

While PROC GLM can handle most common analysis of variance problems, other procedures are more efficient or have more features than PROC GLM for certain specialized analyses, or they can handle specialized models that PROC GLM cannot. Much of the rest of this chapter is concerned with comparing PROC GLM to other procedures.

PROC ANOVA for Balanced Designs

When you design an experiment, you choose how many experimental units to assign to each combination of levels (or cells ) in the classification. In order to achieve good statistical properties and simplify the computations , you typically attempt to assign the same number of units to every cell in the design. Such designs are called balanced designs .

In SAS/STAT software, you can use the ANOVA procedure to perform analysis of variance for balanced data. The ANOVA procedure performs computations for analysis of variance that assume the balanced nature of the data. These computations are simpler and more efficient than the corresponding general computations performed by PROC GLM. Note that PROC ANOVA can be applied to certain designs that are not balanced in the strict sense of equal numbers of observations for all cells. These additional designs include all one-way models, regardless of how unbalanced the cell counts are, as well as Latin squares, which do not have data in all cells. In general, however, the ANOVA procedure is recommended only for balanced data. If you use ANOVA to analyze a design that is not balanced, you must assume responsibility for the validity of the output. You are responsible for recognizing incorrect results, which may include negative values reported for the sums of squares. If you are not certain that your data fit into a balanced design, then you probably need the framework of general linear models in the GLM procedure.

Comparing Group Means with PROC ANOVA and PROC GLM

When you have more than two means to compare, an F test in PROC ANOVA or PROC GLM tells you whether the means are significantly different from each other, but it does not tell you which means differ from which other means.

If you have specific comparisons in mind, you can use the CONTRAST statement in PROC GLM to make these comparisons. However, if you make many comparisons using some given significance level (0 . 05, for example), you are more likely to make a type 1 error (incorrectly rejecting a hypothesis that the means are equal) simply because you have more chances to make the error.

Multiple comparison methods give you more detailed information about the differences among the means and enable you to control error rates for a multitude of comparisons. A variety of multiple comparison methods are available with the MEANS statement in both the ANOVA and GLM procedures, as well as the LSMEANS statement in the GLM and MIXED procedures. These are described in detail in 'Multiple Comparisons' in Chapter 32, 'The GLM Procedure.'

PROC TTEST for Comparing Two Groups

If you want to perform an analysis of variance and have only one classification variable with two levels, you can use PROC TTEST. In this special case, the results generated by PROC TTEST are equivalent to the results generated by PROC ANOVA or PROC GLM.

In addition to testing for differences between two groups, PROC TTEST performs a test for unequal variances. You can use PROC TTEST with balanced or unbalanced groups. The PROC NPAR1WAY procedure performs nonparametric analogues to t tests. See Chapter 12, 'Introduction to Nonparametric Analysis,' for an overview and Chapter 52 for details on PROC NPAR1WAY.




SAS.STAT 9.1 Users Guide (Vol. 1)
SAS/STAT 9.1 Users Guide, Volumes 1-7
ISBN: 1590472438
EAN: 2147483647
Year: 2004
Pages: 156

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net