University of British Columbia**We aren't endorsed by this school
Course
STAT 300
Subject
Statistics
Date
Jan 13, 2025
Pages
7
Uploaded by lulu_lemon
Summary: Two-Way ANOVAIn ANOVA, if there is onlyone factor(with several levels), it iscalled aone-way ANOVA.If there aretwo factors(each factor has several levels), theANOVA is called atwo-way ANOVA.For example, in previous class, the main factor is drug. If weconsider gender as another factor, then we have a two-way ANOVA.As another example, if there are two (or more) professors, eachmay decide to use clicker or not, then Professor and Clicker usagemay be viewed as two factors.
Summary: Two-Way ANOVAIn a two-way ANOVA, we should consider possibleinteractionbetween the two factors, i.e., the effect of one factor may dependon levels of the other factor.The significance of the interaction can be tested.The basic idea of a two-way ANOVA method is similar: Wedecompose the total variation (sum of squares) into four sources:variations between levels of factor A, variations betweenlevels of factor B, variation due to interaction, and errorvariation (variation of data within each level).
Summary: Two-Way ANOVASuppose that factor A (say, row factor) hasrlevels, factor B(say, column factor) hasclevels. LetμA1,···,μArbe the populationmeans of factor A at therlevels respectively. LetμB1,···,μBcbe thepopulation means of factor B at theclevels respectively.The main hypotheses to be tested areH0A:μA1=···=μArvsH1A:notH0A.H0B:μB1=···=μBcvsH1B:notH0B.We may also testH0AB: there is interaction versusH1AB: nointeraction.
Summary: Two-Way ANOVALetSStotaldenote total sum of squares,SSAdenote sum ofsquares between levels of factor A,SSBdenote sum of squaresbetween levels of factor B,SSABdenote sum of squares due tointeraction, andSSerrordenote error variation (random variationwithin each level).We haveSStotal=SSA+SSB+SSAB+SSerror.Then, we can compareSSA(orSSBorSSAB) withSSerrorto see iffactor A (or B or AB) are statistically significant.
Two-Way ANOVA TableTwo-way ANOVA tableSourced.f.SSMSF valueFactor Ar-1SSAMSA=SSAr-1FA=MSAMSEFactor Bc-1SSBMSB=SSBc-1FB=MSBMSEInteraction(r-1)(c-1)SSABMSAB=SSAB(r-1)(c-1)FAB=MSABMSEErrorn-rcSSerrorMSE=SSerrorn-rcTotaln-1SStotalHerenis the total sample size.
Two-Way ANOVA TableUnder the null hypotheses, the distributions of the test statisticsare as followsFA∼Fr-1,n-rc,FB∼Fc-1,n-rc,FAB∼F(r-1)(c-1),n-rc.These null distributions can be used to compute p-values or makedecisions.If the interaction is not significant, we should remove itfrom the model/table.
ANOVA ModelsIn general, a one-way ANOVA model can be written asyij=μ+αi+εij,i=1,2,···,k;j=1,2,···,ni,whereαiis the effect ofi-th level of the factor, andεijis random error.In general, a two-way ANOVA model can be written asyijk=μ+αi+βj+(αβ)ij+εijk,i=1,2,···,p;j=1,2,···,q;k=1,2,···,nij,whereαiis the effectofi-th level of factor A,βjis the effect ofj-th level of factor B,(αβ)ijis the interaction between factors A and B, andεijkis random error.