Refactored the ANOVA function to use more conceptually clear bindings in the let block