A two-way anova without replication and only two values for the interesting nominal variable may be analyzed using a The results of a paired t–test are mathematically identical to those of a two-way anova, but the paired t–test is easier to do and is familiar to more people. Data sets with one measurement variable and two nominal variables, with one nominal variable nested under the other, are analyzed with a
Some people plot the results of a two-way anova on a 3-D graph, with the measurement variable on the Y axis, one nominal variable on the X-axis, and the other nominal variable on the Z axis (going into the paper). This makes it difficult to visually compare the heights of the bars in the front and back rows, so I don't recommend this. Instead, I suggest you plot a bar graph with the bars clustered by one nominal variable, with the other nominal variable identified using the color or pattern of the bars.
Two-Way ANOVA with ReplicationReferring to the student assistant and the work study hourly wages here at the university of Baltimore the following data shows the hourly wages for the two categories in three different departments: Factor A: Student job category (in here two different job categories exists) Factor B: Departments (in here we have three departments) Replication: The number of students in each experimental condition.
The Two-way ANOVA Without ReplicationIn this section, the study involves six students who were offered different hourly wages in three different department services here at the University of Baltimore.
We can also choose Anova: two way factor with or without replication option and see whether there is significant difference between means when different factors are involved.
If you are using SAS to do a two-way anova without replication, do not put an interaction term in the model statement (sex*genotype is the interaction term in the example above).
Use PROC GLM for a two-way anova. The CLASS statement lists the two nominal variables. The MODEL statement has the measurement variable, then the two nominal variables and their interaction after the equals sign. Here is an example using the MPI activity data described above:
Three-way and higher order anovas are possible, as are anovas combining aspects of a nested and a two-way or higher order anova. The number of interaction terms increases rapidly as designs get more complicated, and the interpretation of any significant interactions can be quite difficult. It is better, when possible, to design your experiments so that as many factors as possible are controlled, rather than collecting a hodgepodge of data and hoping that a sophisticated statistical analysis can make some sense of it.
The measurement variable is trials to habituation, and the two nominal variables are day (1 to 4) and snake ID. This is a repeated measures design, as the measurement variable is measured repeatedly on each snake. It is analyzed using a two-way anova without replication. The effect of snake is not significant (F5, 15=1.24, P=0.34), while the effect of day is significant (F3, 15=3.32, P=0.049).
Two-way anova, like all anovas, assumes that the observations within each cell are and have. I don't know how sensitive it is to violations of these assumptions.
When there is only a single observation for each combination of the nominal variables, there are only two null hypotheses: that the means of observations grouped by one factor are the same, and that the means of observations grouped by the other factor are the same. It is impossible to test the null hypothesis of no interaction; instead, you have to assume that there is no interaction in order to test the two main effects.
When the sample sizes for the subgroups are not equal (an "unbalanced design"), the analysis is much more complicated, and there are several different techniques for testing the main and interaction effects that I'm not going to cover here. If you're doing a two-way anova, your statistical life will be a lot easier if you make it a balanced design.
When the sample sizes in each subgroup are equal (a "balanced design"), you calculate the mean square for each of the two factors (the "main effects"), for the interaction, and for the variation within each combination of factors. You then calculate each F-statistic by dividing a mean square by the within-subgroup mean square.
When you do a two-way anova without replication, you can still test the two main effects, but you can't test the interaction. This means that your tests of the main effects have to assume that there's no interaction. If you find a significant difference in the means for one of the main effects, you wouldn't know whether that difference was consistent for different values of the other main effect.