Two Way ANOVA (Analysis of Variance) With Replication
Two Factor ANOVA for Non-Statisticians
When to Use Two Way Anova
Two Way Anova (Analysis of variance) , also known as two factor Anova, can help you determine if two or more samples have the same "mean" or average. This is a form of "hypothesis testing."
The null hypothesis is that the means are equal. The alternate hypothesis is that the means are not equal.
- H0: Mean1 = Mean2 = Mean3
- Ha: Mean1 <> Mean2 <> Mean3
The goal is to accept or reject the null hypothesis (i.e., the samples have different means) at a certain confidence level (95% or 99%).
Two-Way ANOVA Analysis With Replication Example
What if you have two populations of patients (male/female) and three different kinds of medications, and you want to evaluate their effectiveness? You might run a study with three "replications", three men and three women.
Here is how to perform Two Way Anova With Replication using the QI Macros
- Click and drag over your Excel Data to select it
- Click on the QI Macros Menu, Statistical Tools and then Anova Two Factor with Replication.
- The QI Macros will prompt you for how many rows are in each sample (three) and for a significance level. Default is alpha=0.05 for a 95% confidence.
- The QI Macros will perform all of the calculations and interpret the results for you.
What's Cool about QI Macros ANOVA Calculations?
Unlike other statistical software, the QI Macros is the only SPC software that compares the p-values (0.179) to the signficance (0.05) and tells you to "Cannot Reject the Null Hypothesis because p>0.05" and that the "Means are the same ".
Watch This Video to See the QI Macros in Action
Interpreting the Two Factor Anova Results Yourself
In case you want to know how to do this manually, use these instructions.
|test statistic > critical value
(i.e. F> Fcrit)
|Reject the null hypothesis|
|test statistic < critical value
(i.e. F< Fcrit)
|Cannot Reject the null hypothesis|
|p value < a||Reject the null hypothesis|
|p value > a||Cannot Reject the null hypothesis|
Here, the P-value for Male/Female is greater than alpha (.179> .05), so we cannot reject the null hypothesis that the means are the same. The P-Value for Drugs is greater than alpha (.106 > .05), so the null hypothesis holds as well (means are the same).
The P-value for the interaction of the drugs and patients is less than alpha (.006< .05), so we reject the null hypotheis and can say that the effectiveness of the drugs is not the same for the two categories of patients.
Tips on Setting Up Your Data in Excel
To analyze data, Excel requires you to set the data up in a way that can be analyzed.
The example below shows how to set up the data for two categories of patients treated with three different drugs.
Then, if you're just interested in the single factor DRUGS, select and run a Anova single factor on the three drug columns.
If you're interested in a Anova two-factor analysis (patients vs drugs), select and run a two-factor analysis with repetition (more than one patient in the category receives the same drug).
- QI Macros Statistics Wizard - Selects the right statistical test for you
- One Way Anova in Excel
- Two Way Anova in Excel
- Hypothesis Testing