A two-way ANOVA analyzes the influence of two independent variables on a single dependent variable. It tests for main effects of each independent variable as well as interactions between the variables. The independent variables are categorical and the dependent variable is measured on an ordinal or ratio scale. It compares sums of squares and mean squares to determine if the means of observations grouped by each factor differ significantly. An example tests the effect of gender and age on test scores, with gender, age as independent variables and test score as the dependent variable.