Skip to main content
Glama

stats.mann_whitney_u

Read-onlyIdempotent

Compares two independent samples for distribution-location differences with a rank-based test, returning U statistic, p-value, and sample sizes.

Instructions

독립 두 표본의 분포 위치 차이를 순위 기반 Mann-Whitney U 검정으로 판정해 u_stat, p_value, n_a, n_b를 돌려준다. a, b는 Decimal 문자열 각 1개 이상, tail은 two(기본), less, greater이며 u_stat은 a 표본 기준이다. 정규성 가정이 필요 없고 u는 유효숫자 6자리, p값은 10자리 문자열이다. 같은 대상의 전후 측정에는 wilcoxon 을 쓴다.

Input Schema

NameRequiredDescriptionDefault
aYes
bYes
tailNotwo

Output Schema

NameRequiredDescriptionDefault
n_aYes
n_bYes
_metaNo서버가 붙이는 영수증(integrity), 엔진, 힌트
traceYes계산 근거(tool, formula, inputs, steps, output)
u_statYes
p_valueYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/closed-world, so safety needs no restating; the description instead adds substantive behavior: no normality assumption, u_stat oriented to sample a, and output precision (u to 6 significant digits, p a 10-digit string). It leaves tie handling, continuity correction, and minimum sample size unstated.

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?

Front-loaded with the purpose and return values, and every sentence carries distinct information (parameters, tail options, statistical assumption, precision, alternative tool). It is a dense single block with no paragraph breaks, which slightly hinders scanning.

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

Completeness5/5

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

Output schema exists, so return values need no elaboration, yet the description still clarifies result precision. Required vs optional params, tail semantics, output orientation, and the sibling alternative are all covered — nothing an agent needs to invoke it correctly is missing.

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

Parameters5/5

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

Schema coverage is 0% and the schema has no enum for tail, so the description must carry the load — and it does: a and b are Decimal string arrays with at least one element each, and tail accepts two (default), less, greater. It also explains how u_stat relates to the a/b ordering, which the schema never could.

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?

Names a specific verb and resource ('rank-based Mann-Whitney U test for location difference between two independent samples') and enumerates the four outputs returned. It also disambiguates from the nearest sibling by naming wilcoxon for paired before/after data.

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

Usage Guidelines4/5

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

Explicitly routes the paired/same-subject case to wilcoxon, which is the main sibling confusion risk. It also implies when it is appropriate ('no normality assumption required'), but does not compare against the parametric alternative stats.ttest_two_sample.

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

Deploy Server

Other Tools