Multivariate Outcome — Distribution Diagnostics & Hypothesis Testing
Table of Contents
Open-source skill.
Scope Boundary
Use this skill when:
- There are multiple continuous outcomes that should be tested jointly before decomposing into separate univariate models.
- A baseline Hotelling / MANOVA analysis is appropriate before dimension reduction or multivariate modeling.
Do not use this skill when:
- There is only one dependent variable.
- The data are repeated / longitudinal, SEM-based, or primarily exploratory dimension-reduction from the outset.
Workflow
Read each step file in workflow/ before executing that step.
| Step |
Responsibility |
Executor |
Document |
Input |
Output |
| Collect |
Collect Inputs |
Main Agent |
workflow/step01-collect-inputs.md |
User input |
Structured input summary |
| Diagnose |
Check Distribution |
Main Agent |
workflow/step02-check-distribution.md |
Prior step output |
PART 1 code block |
| Test |
Run Primary Test |
Main Agent |
workflow/step03-run-primary-test.md |
Prior step output |
PART 2-3 code blocks |
Decision Tree
1. CHECK MULTIVARIATE DISTRIBUTION
├── Mardia skewness p >= .05 AND Mardia kurtosis p >= .05 → multivariate normal
└── Either p < .05 → note violation, Pillai's Trace is robust
2. CHECK COVARIANCE EQUALITY
├── Box's M p >= .001 (strict alpha) → covariance matrices equal
└── Box's M p < .001 → note violation, Pillai's Trace is robust
3. GROUP COMPARISON
├── 2 groups → Hotelling's T² + F approximation + individual ANOVAs
└── 3+ groups → One-way MANOVA (all 4 statistics) + discriminant follow-up
Required Inputs
| Role |
What to collect |
| Outcomes (Y₁..Yₖ) |
2+ continuous variable names, what they measure |
| Group variable |
What defines groups, how many levels |
| Predictors |
For recommendation block (not executed) |
| Covariates |
For recommendation block (not executed) |
Code Structure
PART 0: Setup & Data Loading
PART 1: Multivariate Distribution Diagnostics → plot_01_scattermatrix.png
PART 2: Primary Multivariate Test → plot_02_groupmeans.png
PART 3: Recommendation Block → text listing additional analyses available
Reporting Standards
- p-values: "< .001" not "0.000"; exact to 3 decimals otherwise
- Effect sizes: partial eta-squared per DV in follow-up ANOVAs
- 95% CIs: always for mean differences in univariate follow-ups
- Degrees of freedom: always with F statistics
- Sample size: final analytic N
- Decimal places: 2 for M/SD, 3 for p and effect sizes
- Non-significance: "not statistically significant at alpha = .05" — never "no effect"
- MANOVA statistics: report all four (Pillai's V, Wilks' Lambda, Hotelling-Lawley T, Roy's theta) with F approximation and p
- Box's M: report with F approximation and p, use strict alpha (.001). Caveat: Box's M is notoriously sensitive to deviations from multivariate normality — a significant result may reflect non-normality rather than true covariance heterogeneity. When Box's M rejects AND Mardia/Henze–Zirkler also indicate non-normality, do NOT conclude covariance heterogeneity on Box's M alone. Instead: (a) report Pillai's Trace as the primary MANOVA statistic (most robust to assumption violations), and (b) consider log/Box–Cox transformation or a robust MANOVA variant before interpreting Box's M as a substantive result.
Hypothesis Tests
| Scenario |
Test |
Follow-Up |
| 2 independent groups |
Hotelling's T² |
Individual Welch's t per DV |
| 3+ independent groups |
One-way MANOVA |
Individual ANOVAs per DV |
Paired/repeated multivariate → vera-data-repeated-reviewing.
Single DV → vera-data-continuous-reviewing.
Example Dataset
R built-in iris: outcomes = Sepal.Length, Sepal.Width, Petal.Length, Petal.Width; group = Species.
Python: from sklearn.datasets import load_iris.
Method Status
| Status |
Methods |
| Implemented in this skill |
Multivariate normality / covariance checks, Hotelling's T-squared, one-way MANOVA, and univariate follow-up triggers |
Implemented downstream in vera-data-multivariate-generating |
MANCOVA, DFA, profile analysis, canonical correlation, PCA, multivariate regression, and exploratory trees |
| Out of scope in this open-source baseline |
Repeated multivariate models and latent-variable multivariate frameworks |
Minimal Smoke Test
- Smoke-test prompt: "Run
vera-data-multivariate-reviewing on iris, using the four measurement columns as outcomes and Species as the grouping variable. Produce the standard baseline artifacts."
Cross-Skill Interface
Output:
├── code_r → .R script
├── code_python → .py script
├── figures/ → 2 PNGs (scattermatrix + group means)
└── recommendations → text block (additional analyses available)
Next step: Invoke vera-data-multivariate-generating from this skillset to run the full pipeline (additional tests, subgroup analysis, modeling, manuscript generation). See ../../CROSS-SKILL-INTERFACE.md for the shared handoff contract.
1---2name: vera-data-multivariate-reviewing3description: Multivariate diagnostics and primary hypothesis tests for multiple continuous outcomes analyzed simultaneously. Produces multivariate normality (Mardia, Henze-Zirkler), Box's M test, scatterplot matrix, correlation matrix, and one multivariate group comparison (Hotelling's T-squared for 2 groups or one-way MANOVA with all four test statistics for 3+ groups) with partial eta-squared per DV and univariate follow-up ANOVAs. Ends with a recommendation block. Outputs .R and .py scripts with publication-quality plots. Handles group- difference tests on 2+ continuous dependent variables (Hotelling's T², MANOVA, one-way MANOVA). Dimensionality-reduction methods (PCA, factor analysis) and canonical correlation are delegated to vera-data-multivariate-generating.4---56# Multivariate Outcome — Distribution Diagnostics & Hypothesis Testing78## Table of Contents910- [Scope Boundary](#scope-boundary)11- [Workflow](#workflow)12- [Decision Tree](#decision-tree)13- [Required Inputs](#required-inputs)14- [Code Structure](#code-structure)15- [Reporting Standards](#reporting-standards)16- [Hypothesis Tests](#hypothesis-tests)17- [Example Dataset](#example-dataset)18- [Method Status](#method-status)19- [Minimal Smoke Test](#minimal-smoke-test)20- [Cross-Skill Interface](#cross-skill-interface)212223Open-source skill.2425## Scope Boundary2627Use this skill when:28- There are multiple continuous outcomes that should be tested jointly before decomposing into separate univariate models.29- A baseline Hotelling / MANOVA analysis is appropriate before dimension reduction or multivariate modeling.3031Do not use this skill when:32- There is only one dependent variable.33- The data are repeated / longitudinal, SEM-based, or primarily exploratory dimension-reduction from the outset.3435## Workflow3637Read each step file in `workflow/` before executing that step.3839| Step | Responsibility | Executor | Document | Input | Output |40|---|---|---|---|---|---|41| Collect | Collect Inputs | Main Agent | `workflow/step01-collect-inputs.md` | User input | Structured input summary |42| Diagnose | Check Distribution | Main Agent | `workflow/step02-check-distribution.md` | Prior step output | PART 1 code block |43| Test | Run Primary Test | Main Agent | `workflow/step03-run-primary-test.md` | Prior step output | PART 2-3 code blocks |4445## Decision Tree4647```481. CHECK MULTIVARIATE DISTRIBUTION49 ├── Mardia skewness p >= .05 AND Mardia kurtosis p >= .05 → multivariate normal50 └── Either p < .05 → note violation, Pillai's Trace is robust51522. CHECK COVARIANCE EQUALITY53 ├── Box's M p >= .001 (strict alpha) → covariance matrices equal54 └── Box's M p < .001 → note violation, Pillai's Trace is robust55563. GROUP COMPARISON57 ├── 2 groups → Hotelling's T² + F approximation + individual ANOVAs58 └── 3+ groups → One-way MANOVA (all 4 statistics) + discriminant follow-up59```6061## Required Inputs6263| Role | What to collect |64|---|---|65| **Outcomes (Y₁..Yₖ)** | 2+ continuous variable names, what they measure |66| **Group variable** | What defines groups, how many levels |67| **Predictors** | For recommendation block (not executed) |68| **Covariates** | For recommendation block (not executed) |6970## Code Structure7172```73PART 0: Setup & Data Loading74PART 1: Multivariate Distribution Diagnostics → plot_01_scattermatrix.png75PART 2: Primary Multivariate Test → plot_02_groupmeans.png76PART 3: Recommendation Block → text listing additional analyses available77```7879## Reporting Standards80811. p-values: "< .001" not "0.000"; exact to 3 decimals otherwise822. Effect sizes: partial eta-squared per DV in follow-up ANOVAs833. 95% CIs: always for mean differences in univariate follow-ups844. Degrees of freedom: always with F statistics855. Sample size: final analytic N866. Decimal places: 2 for M/SD, 3 for p and effect sizes877. Non-significance: "not statistically significant at alpha = .05" — never "no effect"888. MANOVA statistics: report all four (Pillai's V, Wilks' Lambda, Hotelling-Lawley T, Roy's theta) with F approximation and p899. Box's M: report with F approximation and p, use strict alpha (.001). **Caveat:** Box's M is notoriously sensitive to deviations from multivariate normality — a significant result may reflect non-normality rather than true covariance heterogeneity. When Box's M rejects AND Mardia/Henze–Zirkler also indicate non-normality, do NOT conclude covariance heterogeneity on Box's M alone. Instead: (a) report Pillai's Trace as the primary MANOVA statistic (most robust to assumption violations), and (b) consider log/Box–Cox transformation or a robust MANOVA variant before interpreting Box's M as a substantive result.9091## Hypothesis Tests9293| Scenario | Test | Follow-Up |94|---|---|---|95| 2 independent groups | Hotelling's T² | Individual Welch's t per DV |96| 3+ independent groups | One-way MANOVA | Individual ANOVAs per DV |9798Paired/repeated multivariate → `vera-data-repeated-reviewing`.99Single DV → `vera-data-continuous-reviewing`.100101## Example Dataset102103R built-in `iris`: outcomes = Sepal.Length, Sepal.Width, Petal.Length, Petal.Width; group = Species.104Python: `from sklearn.datasets import load_iris`.105106## Method Status107108| Status | Methods |109|---|---|110| Implemented in this skill | Multivariate normality / covariance checks, Hotelling's T-squared, one-way MANOVA, and univariate follow-up triggers |111| Implemented downstream in `vera-data-multivariate-generating` | MANCOVA, DFA, profile analysis, canonical correlation, PCA, multivariate regression, and exploratory trees |112| Out of scope in this open-source baseline | Repeated multivariate models and latent-variable multivariate frameworks |113114## Minimal Smoke Test115116- Smoke-test prompt: "Run `vera-data-multivariate-reviewing` on `iris`, using the four measurement columns as outcomes and `Species` as the grouping variable. Produce the standard baseline artifacts."117118## Cross-Skill Interface119120```121Output:122├── code_r → .R script123├── code_python → .py script124├── figures/ → 2 PNGs (scattermatrix + group means)125└── recommendations → text block (additional analyses available)126```127128Next step: Invoke `vera-data-multivariate-generating` from this skillset to run the full pipeline (additional tests, subgroup analysis, modeling, manuscript generation). See `../../CROSS-SKILL-INTERFACE.md` for the shared handoff contract.