文档介绍:实验七方差分析
第1页,共32页,编辑于2022年,星期六
目的与要求:
(一)掌握内容
1. anova和glm过程的格式;
方差分析,能对SAhe SAS System
The UNIVARIATE Procedure
Variable: x
Tests for Normality
g = 1
Test --Statistic--- -----p Value------
Shapiro-Wilk W Pr < W
g = 2
Test --Statistic--- -----p Value------
Shapiro-Wilk W Pr < W
g = 3
Test --Statistic--- -----p Value------
Shapiro-Wilk W Pr < W
第16页,共32页,编辑于2022年,星期六
结果解释:
资料满足正态分布情况:三个样本的资料正态性检验得:
W1=,P1=,
W2=,P2=,
W3=,P3=,
按α=,可认为三组资料均服从正态分布。
第17页,共32页,编辑于2022年,星期六
proc anova; / *调用anova过程*/
class g; / *指定分组变量*/
model x=g; / *指定方差分析模型:“=”左边为分析变量,右边为分组变量*/
means g/ hovtest ;
/ *homogeneity of variance test 方差齐性检验*/
run;
第18页,共32页,编辑于2022年,星期六
The SAS System
The ANOVA Procedure
Levene's Test for Homogeneity of x Variance
ANOVA of Squared Deviations from Group Means
Sum of Mean
Source DF Squares Square F Value Pr > F
g 2
Error 15
经方差齐性检验得,F=,P=>,故暂不拒绝H0,可认为三组总体的方差齐。
离均差平方和
均方
第19页,共32页,编辑于2022年,星期六
The SAS System
The ANOVA Procedure
Dependent Variable: x
变异来源 离均差平方和 均方
Sum of
Source DF Squares Mean Square F Value Pr > F
Model 2 <.0001
Error 15
Corrected
Total 17
R-Square Coeff Var Root MSE x Mean
Source DF Anova SS Mean Sq