Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Choose Statistical Test

ASecurity

Pick the right hypothesis test for a described scenario by traversing the test-selection decision tree (data type → #groups → paired? → assumption gate → test), then return the recommended test, its assumption checks, its nonparametric fallback, and a ≤10-line runnable snippet. Reach for this when the user asks "which test do I use?" or hands over two-or-more groups/variables to compare. Used by `applied-statistician` (primary).

7 stars
0 votes
0 copies
0 views
Added 9/23/2026
ai-agentspythongorails

Security Analysis

A100/100

Scanned 9/23/2026

$npx -y skills add mcorbett51090/RavenClaude --skill choose-statistical-test --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Choose Statistical Test?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Choose Statistical Test
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/mcorbett51090-choose-statistical-test/badge)](https://www.skillsdirectory.com/skills/mcorbett51090-choose-statistical-test)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: choose-statistical-test
description: 'Pick the right hypothesis test for a described scenario by traversing the test-selection decision tree (data type → #groups → paired? → assumption gate → test), then return the recommended test, its assumption checks, its nonparametric fallback, and a ≤10-line runnable snippet. Reach for this when the user asks "which test do I use?" or hands over two-or-more groups/variables to compare. Used by `applied-statistician` (primary).'
---

# Skill: choose-statistical-test

> **Invoked by:** `applied-statistician` (primary). Also consulted by `experiment-analysis` and `statistical-qa-of-metrics` when they need to name the underlying test.
>
> **When to invoke:** "which test should I use?"; "is the difference between these groups significant?"; any comparison of 2+ groups or relationship between 2 variables.
>
> **Output:** the recommended test + the assumption checks that gate it + the nonparametric fallback + a short runnable snippet (method-before-library) + the effect-size/CI to report alongside.

## Procedure

1. **Restate the question** in the tree's terms: is it a *group difference*, a *relationship*, or a *prediction*?
2. **Traverse the decision tree** in [`../../knowledge/test-selection-decision-tree.md`](../../knowledge/test-selection-decision-tree.md) against:
   - outcome **data type** (continuous / categorical / ordinal / count / time-to-event),
   - **number of groups** (1 / 2 / 3+),
   - **paired vs independent**,
   - the **assumption gate** (normality, equal variance, independence).
3. **Name the method first, the library second.** Resolve to the parametric leaf only if the assumption gate passes; otherwise take the nonparametric fallback.
4. **Emit a ≤10-line snippet** (Tier-1 tooling — `scipy.stats` / `pingouin` / `statsmodels`; see [`../../knowledge/statistics-tooling-2026.md`](../../knowledge/statistics-tooling-2026.md)) that (a) checks the assumption, (b) runs the test, (c) reports **effect size + CI**, not just p.
5. **State the fallback explicitly:** "if normality fails, switch to <nonparametric test>."

## Worked example

> User: "I have conversion counts for two landing pages. Which test?"

- Question type: group difference. Outcome: the per-user binary "converted?" → **two independent groups, categorical outcome** → **chi-square test of independence** (Fisher's exact if any expected cell < 5).
- If instead the outcome were a continuous per-user value (e.g., revenue) and roughly normal → independent t-test (Welch if variances differ); non-normal → Mann-Whitney U.
- Report: the effect (e.g., difference in conversion rate or odds ratio) **with a confidence interval**, not just the p-value.

```python
# two landing pages, conversion counts — chi-square of independence
import numpy as np
from scipy.stats import chi2_contingency
# rows = page A / page B; cols = converted / not
table = np.array([[120, 1880], [150, 1850]])
chi2, p, dof, expected = chi2_contingency(table)
if (expected < 5).any():
    from scipy.stats import fisher_exact          # small expected cells → exact test
    _, p = fisher_exact(table)
# report the effect (rate difference + CI), not just p — see experiment-analysis skill
```

## Guardrails
- Never return a parametric test without naming its assumption check **and** its fallback.
- 3+ groups → ANOVA/Kruskal-Wallis + a multiplicity-correcting post-hoc, **never** a stack of pairwise t-tests (pitfall #2).
- Always pair the result with an effect size + CI (pitfall #6). See [`../../knowledge/statistical-pitfalls.md`](../../knowledge/statistical-pitfalls.md).

Attribution

mcorbett51090mcorbett51090
View sourceSee grades on GitHubMore from mcorbett51090 →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Caveman

Terse caveman voice: answer first, fluff gone, every technical fact kept. Use for /caveman, "caveman mode", "talk like caveman", "be brief", "less tokens". Stays on until "stop caveman" or "normal mode".

1100021 votes

Hyperplan

Adversarial multi-agent planning skill. Self-orchestrates 5 hostile category members (unspecified-low, unspecified-high, deep, ultrabrain, artistry) via team-mode for ruthless cross-critique debate, distills only the defensible insights, then MANDATORILY hands the distilled insight bundle to the `plan` agent for executable plan formalization. Use when planning needs maximum rigor and surfacing of weak assumptions, blind spots, and over-engineering. Triggers: 'hyperplan', 'hpp', '/hyperplan', ...

698461 votes

Writing Skills

Create and manage Claude Code skills in HASH repository following Anthropic best practices. Use when creating new skills, modifying skill-rules.json, understanding trigger patterns, working with hooks, debugging skill activation, or implementing progressive disclosure. Covers skill structure, YAML frontmatter, trigger types (keywords, intent patterns), UserPromptSubmit hook, and the 500-line rule. Includes validation and debugging with SKILL_DEBUG. Examples include rust-error-stack, cargo-dep...

3931 votes

Mcp Code Execution

Routes multi-tool workflows through MCP servers for large datasets and pipelines. Use when Bash tool overhead is limiting throughput on data-heavy tasks.

3421 votes

catchup

Recovers the conversation and failed tool calls of a previous Codex, Amp, Claude Code, Antigravity, Cline, Copilot CLI, Cursor, DeepSeek Harness, Grok Build, Kimi, OpenCode, Pi Agent, or ZCode session. Use when the user says "catch up", "what did the last session do", "get me up to speed", "I switched agents", asks to recover/summarize a previous session before continuing, or asks to diagnose or report a catchup failure. Do NOT use for the current conversation, git history, or any non-agent log.

741 votes
View all in ai-agents →