Solved
New Contributor
Posts: 3

Testing homogeneity for Two-way ANOVA

Hi,

I am trying to test homogeneity for a two way ANOVA, (linearity assumption was alreay verified), but It doesn't work, I read that Levene's test is only for one way ANOVA

PROC GLM DATA=clus_ConHR;
CLASS Cluster agegroup;
MODEL vitesse_trt = Cluster agegroup Cluster*agegroup;
means Cluster*agegroup/ HOVTEST=levene(type=ABS);
run;
quit;

How should I test homogeneity using SAS in this model? Should I construct a plot with the residuals?

Accepted Solutions
Solution
‎04-26-2017 02:03 PM
New Contributor
Posts: 3

Re: Testing homogeneity for Two-way ANOVA

I was trying to test homogeneity of variance by looking at the distributions. I found this solution:

PROC glm DATA=clus_ConHR;
CLASS Cluster agegroup;
MODEL fct_executive = Cluster agegroup Cluster*agegroup;
output out = residus p=predit rstudent=rstudent;
run;
quit;

Proc gplot data = residus;
plot rstudent* (predit);
run;

Thank you

All Replies
Super User
Posts: 10,214

Re: Testing homogeneity for Two-way ANOVA

Can you try LSMEANS statement ?

And your design is balanced or not balanced ?

New Contributor
Posts: 3

Re: Testing homogeneity for Two-way ANOVA

Lsmeans didn't gave me the results that I need to test homogeneity. Thank you anyway.

SAS Super FREQ
Posts: 3,839

Re: Testing homogeneity for Two-way ANOVA

[ Edited ]

Not clear if you want a statistical test or a graph that enables you to visually check distributions.  For a graph, try using the EFFECTPLOT statement:

``````proc genmod DATA=clus_ConHR;
CLASS Cluster agegroup;
MODEL vitesse_trt = Cluster agegroup Cluster*agegroup
effectplot box / cluster;
run;
``````

For details and a discussion, see "Visualize an ANOVA with two-way interactions."

Solution
‎04-26-2017 02:03 PM
New Contributor
Posts: 3

Re: Testing homogeneity for Two-way ANOVA

I was trying to test homogeneity of variance by looking at the distributions. I found this solution:

PROC glm DATA=clus_ConHR;
CLASS Cluster agegroup;
MODEL fct_executive = Cluster agegroup Cluster*agegroup;
output out = residus p=predit rstudent=rstudent;
run;
quit;

Proc gplot data = residus;
plot rstudent* (predit);
run;

Thank you

New Contributor
Posts: 4

Re: Testing homogeneity for Two-way ANOVA

Although the graphics (expecially boxplots) are useful in assessing homogeniety of variance across groups in a 2-way ANOVA, I am looking for a statistical test that can be applied ?  Most of what I have seen only applies to 1-way ANOVA ?

SAS Super FREQ
Posts: 3,839

Re: Testing homogeneity for Two-way ANOVA

For a discussion of two-way tests of homogeneity of variance, see the examples  and discussion at

http://www.stat.wmich.edu/wang/664/egs/SASsoybean.html

☑ This topic is solved.