Functional ANOVA for evaluating cognitive abilities and school performance