Understand the idea
Imagine you're comparing groups on FOUR related measurements at once, not just one. You could run four separate ANOVAs, but that runs into two problems: first, running four tests inflates your chance of a false alarm somewhere; second, separate ANOVAs completely ignore how the four outcomes CORRELATE with each other, which can hide a real, joint difference that shows up in the combination of measurements even when no single measurement alone looks different. MANOVA solves both problems by testing all the outcomes TOGETHER, as one combined vector, in a single omnibus test.
There are actually four different mathematical ways to boil this multivariate comparison down into one test statistic (Wilks' Lambda, Pillai's trace, Hotelling-Lawley trace, Roy's greatest root), and with exactly two groups they all agree perfectly. With three or more groups they can disagree slightly. Wilks' Lambda is the conventional headline number most people report, but Pillai's trace is the safer, more robust choice specifically when you're worried the underlying assumptions (like similar spread across groups) might not hold.
A significant MANOVA tells you the groups differ SOMEWHERE in the combined multivariate space: it does not tell you which specific outcome is driving that difference. The standard follow-up is to run separate ANOVAs on each individual outcome (ideally with a correction for running several tests), to pin down exactly which measurement or measurements are responsible for the overall significant result.
MANOVA stands for multivariate analysis of variance.
Practitioner explanation
KernelStats fits via statsmodels' MANOVA.from_formula, computing all four multivariate statistics (Wilks' Lambda = product of 1/(1+lambda_i), Pillai's trace = sum of lambda_i/(1+lambda_i), Hotelling-Lawley trace = sum of lambda_i, Roy's greatest root = max lambda_i, all functions of the eigenvalues of E^-1*H) converted to an approximate F, and multivariate eta-squared = 1 - Lambda^(1/s) with s = min(p, hypothesis df) as the effect size. The product states directly that for exactly two groups all four statistics agree EXACTLY (reducing to Hotelling's T-squared); with three or more groups they can genuinely disagree, and Pillai's trace is named as the safest default specifically when assumptions look shaky.
A specific, deliberate guard runs BEFORE fitting rather than after: each individual GROUP must have strictly MORE rows than there are response variables, checked per-group (not just on the total sample size), because a group failing this can make its contribution to the pooled within-group covariance matrix singular, producing mathematically impossible numbers (Wilks' Lambda outside [0,1], a negative F) even when the OVERALL sample size comfortably passed the total-n check. The product catches this per-group condition explicitly, naming the offending group(s) and their sizes, rather than presenting nonsense output from a technically-fitted-but-degenerate model.
The card runs Box's M test of equal covariance matrices, judged at alpha = .001 because the test is very sensitive in large samples, and Mardia's tests of multivariate skewness and kurtosis on the within-group residuals; when either fails, it recommends Pillai's trace, the most robust of the four statistics. Perfectly (or near-perfectly) collinear response variables are caught explicitly and refused with a clear message naming the redundancy, since two response variables that are exact linear functions of each other leave no independent multivariate information to test jointly.
When to use it
Consider it when
You have two or more correlated continuous outcomes and one categorical grouping factor, and want a single omnibus test of whether the groups differ jointly across the outcomes, controlling the family-wise error rate running several separate ANOVAs would incur.
Use caution when
You only have one continuous outcome (use one-way ANOVA instead), any group has fewer rows than the number of response variables (MANOVA's within-group covariance estimate for that group becomes singular), or two or more response variables are perfectly or near-perfectly collinear (there is no independent multivariate information left to test).
Formulas and symbols
Wilks' Lambda
lambda_i the eigenvalues of E^-1*H (E the within-group, H the between-group covariation matrices). Smaller Lambda means a stronger effect. The conventional headline statistic.
Pillai's trace
The most robust of the four statistics to assumption violations; the recommended default when equal-covariance or normality is doubtful.
Multivariate eta-squared
p the number of response (dependent) variables. Cohen's rough marks: 0.01 small, 0.06 medium, 0.14 large.
Assumptions and checks
- Homogeneity of variance (homoscedasticity). MANOVA assumes the within-group covariance matrices of the response variables are equal across groups; when they differ substantially, the standard MANOVA test statistics can have inflated or deflated Type I error, especially with unbalanced group sizes.
In KernelStats: Box's M test, reported directly on the card and judged at alpha = .001 because it is very sensitive; when it fails, the card recommends Pillai's trace, the most robust of the four MANOVA statistics, and when a group's covariance matrix is singular it reports that Box's M could not be computed.
- Normality (of residuals, not of the raw data). MANOVA assumes the response vector is multivariate normal within each group; with small or unbalanced groups, non-normality can distort the test's true Type I error rate.
In KernelStats: Mardia's tests of multivariate skewness and kurtosis on the within-group residuals, reported directly on the card; the MANOVA tests are fairly robust with moderate-to-large, balanced groups, and the card suggests checking for multivariate outliers and preferring Pillai's trace when the check fails.
Alternatives
- One-Way ANOVA. Only a single continuous outcome is of interest, or as the recommended per-DV follow-up after a significant MANOVA to identify which specific outcome drives the joint effect.
- Linear Discriminant Analysis. You want to find the linear combination of the outcomes that best SEPARATES the groups (descriptive discriminant analysis), as a natural follow-up to a significant MANOVA.
Worked example
Scenario
Testing whether the three penguin species differ jointly on four body measurements (bill length, bill depth, flipper length, body mass).
Result
Wilks' Lambda = 0.019, approximate F(8, 672) = 528.9, p < .001; Pillai's trace = 1.64, F(8, 674) = 379.5, p < .001; multivariate eta-squared = 0.86.
Interpretation
The species differ enormously on the joint combination of the four measurements, with a very large multivariate effect size, and all four statistics agree on the conclusion. Box's M on the same card rejects equal covariance matrices (p < .001), so Pillai's trace is the safer statistic to headline in the write-up. Follow-up univariate ANOVAs on each measurement would be the natural next step to see which specific measurements drive this joint effect most strongly.
Dataset: penguins.csv
Common misconceptions
Misconception
A significant MANOVA result tells you which specific outcome variable is driving the group differences.
Correction
A significant MANOVA only establishes that the groups differ SOMEWHERE in the joint multivariate space of the combined outcomes: it does not identify which individual outcome (or combination) is responsible. Standard follow-ups are per-outcome univariate ANOVAs (ideally with a Bonferroni-type correction) or descriptive discriminant analysis to see which linear combination of outcomes best separates the groups.
Read more: Misconception: statistical significance means practical importance
Misconception
Running several separate ANOVAs, one per outcome, gives the same overall statistical protection as a single MANOVA.
Correction
Running one ANOVA per outcome inflates the family-wise error rate (the chance of at least one false positive across all the separate tests) and completely ignores the CORRELATIONS among the outcomes, which can hide a real joint difference that MANOVA's combined test is specifically able to detect even when no single outcome alone shows a significant difference.
References
- Applied Multivariate Statistical Analysis, Johnson, R. A. and Wichern, D. W. (2007).
- Using Multivariate Statistics, Tabachnick, B. G. and Fidell, L. S. (2013).
