Skip to main content
Glama

Stat Ancova

stat_ancova

Compare group means while controlling for a continuous covariate such as age or baseline score, and automatically test homogeneity of regression slopes to confirm ANCOVA is appropriate.

Instructions

ANCOVA — compare groups while statistically controlling a continuous covariate.

WHEN TO USE: a continuous variable is expected to influence the outcome and differs between groups (e.g. age, baseline score).

WHEN NOT TO USE — two conditions that are frequently violated:

  • The covariate was affected by the manipulation. Controlling a variable the treatment changed removes part of the effect you are measuring.

  • The covariate was measured after the outcome, or with substantial error.

The tool tests homogeneity of regression slopes automatically and tells you if ANCOVA is inappropriate.

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>",
      "covar": "<covar>"
    },
    "name": "stat_ancova"
  }
}

Input Schema

NameRequiredDescriptionDefault
dvYes
nameYes
covarYes
betweenYes
effsizeNonp2

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral load. It usefully discloses that homogeneity of regression slopes is tested automatically and that the tool reports when ANCOVA is inappropriate, which is genuine behavior beyond the schema. However, it says nothing about how the tool handles missing data, what happens when the slope test fails (error versus warning), or what the sample-size requirements are for a 4-required-parameter statistical procedure.

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

Conciseness4/5

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

The WHEN TO USE / WHEN NOT TO USE structure is front-loaded and scannable, and the rationale about a covariate affected by manipulation earns its place. There is mild redundancy between the opening definition and the first usage condition, but no filler sentences.

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

Completeness3/5

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

Selection guidance is excellent for a complex statistical procedure, and an output schema exists so return values need not be described. The gaps are the five undocumented parameters against 0% schema coverage: an agent knows when to run ANCOVA but not exactly which strings to supply for dv, between, covar, name, or effsize.

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

Parameters2/5

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

Schema coverage is 0%, so the description must define dv, name, between, covar, and effsize. It conveys the conceptual variable roles (outcome, grouping variable, continuous covariate) but never maps them to parameter names or gives formats. Nothing explains what 'name' means (an analysis label?) or what the effsize default 'np2' (partial eta squared) entails or what other values are accepted.

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 names the specific technique (ANCOVA) and states its verb and resource precisely: compare groups while statistically controlling a continuous covariate. That definition implicitly separates it from stat_anova (no covariate) and stat_linear_regression, so an agent can pick it 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 gives an explicit WHEN TO USE condition (the covariate is expected to influence the outcome and differs between groups) and two enumerated WHEN NOT TO USE conditions that agents routinely get wrong. The tradeoff between using and avoiding the tool is spelled out rather than left to inference.

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