Skip to main content
Glama

Stat Anova

stat_anova

Run one-way ANOVA to compare means across three or more independent groups with a continuous outcome, then use pairwise tests to identify which groups differ.

Instructions

One-way ANOVA — three or more independent groups, continuous outcome.

WHEN TO USE

  • 3+ independent groups; normality and homogeneity plausible.

  • Instead of running multiple t-tests, which inflates the Type I error rate.

WHEN NOT TO USE

  • Variances unequal → stat_welch_anova.

  • Same participants in every condition → stat_rm_anova.

  • Both a between and a within factor → stat_mixed_anova.

  • Badly non-normal → stat_nonparametric_k.

A significant omnibus F says only that some groups differ, not which. Always follow with stat_pairwise_tests and a multiple-comparison correction.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>",
      "dv": "<dv>",
      "between": "<between>"
    },
    "name": "stat_anova"
  }
}

Input Schema

NameRequiredDescriptionDefault
dvYes
nameYes
betweenYes
effsizeNonp2 (partial eta-squared) | n2 (eta-squared).np2
ss_typeNoSums-of-squares type; 2 (default, recommended for unbalanced designs) | 1 | 3.

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden, and it does substantial work: it declares the distributional assumptions the test relies on, warns that a significant omnibus F says only that some groups differ, and mandates follow-up with stat_pairwise_tests plus a correction. That interpretation guidance is exactly the kind of behavioral context an agent cannot infer. It stops short of saying what the returned object contains or whether the tool requires pre-loaded data, which keeps it off a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The leading sentence states the test and its precondition, then labeled WHEN TO USE / WHEN NOT TO USE blocks let an agent scan for its situation. Every line carries decision-relevant content — no restatement of the name, no filler. The closing sentence about post-hoc follow-up is short but changes how the result should be acted on.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values needn't be described, and the description instead supplies the assumptions, the misuse cases, and the required downstream step — a good allocation of effort for an analysis tool. The remaining gap is procedural: it never explains what name identifies or whether the data must first be loaded via a sibling tool, leaving an agent to infer the call sequence from the schema alone.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 40%, so the description must compensate and only partly does: 'continuous outcome' maps to dv and 'independent groups' maps to between, which clarifies the two most important inputs. However, it never mentions name at all, and effsize/ss_type are only covered by the schema's own descriptions. The three required parameters are named nowhere in the prose, so an agent still relies on the schema for basic binding.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific test name plus the defining conditions — 'three or more independent groups, continuous outcome' — which is exactly the discriminating signature of a one-way ANOVA. An agent can distinguish this from every sibling listed (Welch, repeated-measures, mixed, nonparametric) without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It provides explicit WHEN TO USE criteria (3+ independent groups, plausible normality/homogeneity) and a WHEN NOT TO USE block that names the specific alternative for each violation: unequal variances to stat_welch_anova, repeated participants to stat_rm_anova, mixed designs to stat_mixed_anova, non-normal data to stat_nonparametric_k. It also states the rationale (Type I error inflation from multiple t-tests), so the agent understands the decision rule rather than just a lookup table.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.