← LeaderboardThe Skill Leaderboard

data-analysis-discipline

Analytical judgment SSOT — load before analyzing CSVs, exports, funnels, or diagnosing spikes/drops ("分析数据/排查异常/复盘数据"). Enforces North-Star anchoring, raw archival, full baselines, right-censoring/scale controls, unknown-aware rates, and primary-source checks. Not for charts (data-visualization-discipline), HTML reports (report-with-html), or growth audits (product-growth).

Published by daymade ↗daymade/claude-code-skills

Try your first task

A source-grounded starter task has not been verified for this skill yet.

SKILL.md

name: data-analysis-disciplinedescription: >-  Analytical judgment SSOT — load before analyzing CSVs, exports, funnels, or  diagnosing spikes/drops ("分析数据/排查异常/复盘数据"). Enforces North-Star anchoring,  raw archival, full baselines, right-censoring/scale controls, unknown-aware  rates, and primary-source checks. Not for charts (data-visualization-discipline),  HTML reports (report-with-html), or growth audits (product-growth).

Data Analysis Discipline

This Skill is the canonical analytical judgment layer that runs before you draw charts or write recommendations. Polished visuals cannot rescue a biased sample, a right-censored comparison, an unverified title guess, or a proxy metric masquerading as a business outcome.

Boundaries and mixed-task routing

Question or taskOwner and execution order
Business-outcome anchoring, raw-input hygiene, baseline scope, age/scale/denominator rigor, primary-source falsification, causal boundariesThis Skill (data-analysis-discipline)
Chart form, visual encoding, dual axes, color semantics, visual 9-gate check (on already-verified numbers)data-visualization-discipline
Standalone HTML report layout, decision-card UI component, browser QA, blind reader reviewreport-with-html
Customer-feedback discovery, retention/activation loops, SaaS growth auditsproduct-growth
External public claims, vendor pricing, or official specsfact-checker

Mixed-task order:

  • Chart critique with already-verified numbers → start in data-visualization-discipline; invoke this Skill only if underlying denominators, aggregation, or causal claims fail inspection.
  • Growth diagnosis starting from raw exports → run this Skill's Stages 1–3 for data hygiene and statistical validity, paired with product-growth for value-journey and feedback framing (preserving multiple requested outcomes when tradeoffs matter).
  • Diagnosis delivered as a standalone HTML report → run this Skill (analytical truth) → data-visualization-discipline (chart judgment) → report-with-html (page layout and visual QA).

Load Analytical Traps and Counterexamples once when entering Stage 3 (for worked formulas, synthetic counterexamples, and decision-threshold templates).


Stage 1 · Anchor the Business Outcome and Inspect Schema

Fix the decision target before writing aggregations. You may inspect file headers, row counts, and schemas read-only first so you do not guess available fields, but lock the analytical target before computing summary metrics.

  1. Name the primary business outcome(s): the concrete downstream result the decision-maker actually cares about (e.g., qualified demos, paid activations, net revenue, resolved incidents, retained accounts). When the user requests multiple outcomes (e.g., volume and margin), retain them explicitly and expose tradeoffs rather than forcing a single metric.
  2. Apply the Proxy-Metric Alarm: for every upstream metric you plan to report (views, clicks, completion rate, raw inquiry count), ask "If this doubled while the business outcome stayed flat, would we call it a win?" If no, demote it to a diagnostic input — never the headline or success target.
  3. Write the falsifiable question: state the concrete choice (or descriptive question) this analysis must answer and what evidence would overturn the default hypothesis.

Stage 1 Handoff Check (complete before computing metrics):

  • Primary business outcome(s) and any tradeoff axis: ___
  • Demoted proxy metrics: ___
  • Decision or descriptive question to answer + falsifying evidence: ___

Stage 2 · Preserve Raw Inputs and Bound Scope Honestly

Never mistake a narrow, ephemeral slice for the full population — and never block a valid read-only analysis when external sources are unavailable.

  1. Archive raw inputs only when authorized and destination-safe:
    • Inside a maintained project with an established raw-data convention and user authorization, archive fresh exports (with checksums, source metadata, and export-window notes) into the project's canonical raw directory before pointing derived scripts at them.
    • Destination privacy check: before copying any raw export into a tracked repository, verify repository visibility and PII/secret boundaries. Never copy unredacted sensitive files into a public or unauthorized repo.
    • For read-only or ad-hoc scratch requests (or when archival is unauthorized), analyze the supplied files read-only and explicitly record "read-only scratch scope; not archived."
  2. Check ingestion integrity and unknown windows:
    • Record exact observation timestamp, timezone, and coverage cutoff for each source. If timestamp metadata is absent, state "cutoff unknown."
    • Treat an empty or header-only export (0 rows) as confirmation_required, not proven zero activity, until the export filter and date range are verified.
    • Distinguish "observed row date min/max" from "selected query window"; keep unconfirmed export windows labeled window-unknown.
  3. Establish the three-layer baseline (or mark missing layers explicitly):
    • Self-history baseline: available history segmented by operating regime (active vs. dormant/pre-change) using P50, P25–P75, P90, and max.
    • Peer / benchmark pool: comparable external or historical cohorts, strictly stratified by platform, channel, or segment.
    • Downstream business ledger: live CRM, order, ticket, or fulfillment system rather than stale snapshots.
    • When a layer is unavailable, unauthorized, or inapplicable to the user's request, record its exact status (unavailable / unauthorized / inapplicable) and state what conclusions remain bounded by its absence rather than fabricating coverage or stalling.
  4. Check downstream consumer parity: if a scheduled BI job or dashboard reads archived batches from a separate synced root, verify whether the new batch is actually visible to that consumer before claiming the dashboard is updated.

Stage 2 Handoff Check (complete before computing comparisons):

  • Source status recorded: archived canonical paths (with destination safety checked) OR explicit read-only scratch scope
  • Exact cutoffs, empty/header-only files, and unknown query windows flagged
  • Each of the 3 baseline layers marked verified, unavailable, unauthorized, or inapplicable

Stage 3 · Audit Six Analytical and Causal Traps

Load Analytical Traps and Counterexamples now. For chart-level mean-vs-median presentation and Simpson's paradox visual rules, defer to data-visualization-discipline.

Trap 1 · Right-Censoring (Follow-Up Horizon Bias)

Censoring occurs whenever observation ends before an item's outcome window is complete — regardless of historical percentage cutoffs.

  • Use a common follow-up horizon when comparing cumulative outcomes across cohorts (e.g., exact Day-7 cumulative vs. Day-7 cumulative). Use maturity bands (Day 0–2, Day 3–7, Day 8–14, Day 15–21) only to stratify observation status, not to compare raw cumulative volume across unequal elapsed days (e.g., Day 3 vs. Day 7 inside one band).
  • When measuring late accumulation from paired snapshots (T1, T2), label the share strictly as fraction of outcomes observed by T2 (not lifetime total, since outcomes may continue after T2).
  • Derive age-uncertainty bounds from the actual timestamp precision and timezone of the export (a calendar date without time spans one local calendar day — normally 24h, or 23h/25h on daylight-saving transition days — and widens further when timezone is unknown).
  • Mark immature items as right-censored / observation pending with a concrete same-horizon re-check date instead of declaring them failures.

Trap 2 · Time-Pulse Concentration vs. Sustained Regime Shift

Period totals hide spikes, while short windows inflate concentration mechanically (a flat 3-day window puts 2/3 = 66.7% in its top 2 days).

  • Apply top-2 / top-k pulse alerts only to non-negative time series with matched grain and sufficient periods (e.g., N ≥ 7 periods; compare against the uniform baseline k / N and align with data-visualization-discipline's >50% over-half alert on top-2 / period_sum). When handing a short window (N < 7) downstream to data-visualization-discipline Gate 6, report top-2 / period_sum beside the uniform 2 / N baseline so Gate 6 is satisfied without misclassifying a flat short window as a pulse. Handle sum ≤ 0, signed net flows, and historical P50 == 0 explicitly rather than dividing blindly.
  • Separate a pulse from a sustained shift: check both top-2 / period_sum and current-regime P50 vs. prior-regime P50. A spike can coexist with a higher steady-state median; never size recurring targets off peak days, and do not use top-day concentration to diagnose a drop.

Trap 3 · Heterogeneous Pools, Scale Confounding, and Circular Bucketing

  • Never merge incomparable platforms, channels, or vastly different unit scales (e.g., a 10-second teaser vs. a 6-minute walkthrough) into one undifferentiated median or rate comparison. If a pooled or standardized summary is explicitly required by the decision (such as blended portfolio CAC or total footprint), state the weighting/standardization definition alongside the stratified view.
  • Why avg_watch / completion_rate is an invalid duration proxy: whenever completion rate is positive (0 < p < 1) and incomplete viewers watch more than zero seconds (E[watch | incomplete] > 0), even with zero replays avg_watch / p = L + ((1 - p) / p) * E[watch | incomplete] > L (replays inflate it further; at p = 0, the ratio is undefined). Never present this ratio as true duration.
  • No circular stratification: never group items using a formula containing metric M (such as completion_rate) and then compare M across those same buckets — even with a caveat label. Use directly measured physical attributes (media metadata duration, word count, contract tier) to stratify; when physical length is unavailable, compare metrics independent of the grouping formula (e.g., shares per view, qualified inquiries) or mark duration strata unknown.

Trap 4 · Eligible Population, Unknowns, and Exclusions

Separate four counts on every funnel or rate: total records, explicit exclusions (stating which step they are excluded from), known outcomes, and unknown / unrecorded records.

  • Never collapse unknown into No or 0%. When all 12 rows are blank, report "0 / 12 confirmed recorded (12 unknown — true handoff rate is unknown, spanning 0%–100%)", never "0.0% handoff rate."
  • Choose and label the rate definition explicitly:
    • Recorded-confirmation share: confirmed / eligible_total (always paired with N unknown and bounds).
    • Known-outcome rate: confirmed / known_outcomes (valid only when unknown share is disclosed and non-response bias is noted).
  • When a source reports a percentage only without raw counts, transcribe it as reported and mark "source-reported percentage; numerator/denominator not provided."

Trap 5 · Primary-Source Artifact Inspection Before Causal Storytelling

Never invent content, creative, UX, or operational causes from titles, tags, or summary tables alone.

  • When explaining a comparative gap ("Item A beat Item B because A had X and B lacked X"): inspect the actual primary artifact (video frames/audio, call recording/transcript, raw ticket/chat log, raw page/SQL rows) for both A and the closest negative counterexample B matched on pre-outcome attributes (same channel, similar publish window, target segment, and format).
  • Immediate falsification: if counterexample B already contains feature X, the premise "only A had X" is refuted regardless of the performance ratio. Report only observed artifact differences and list unobserved confounders (thumbnail, feed slot, targeting seed, timing).
  • When investigating a single incident or when one artifact is missing: a paired counterexample is not required when a single complete primary log establishes what happened; if an artifact is missing, mark it uninspected, deliver the supported findings, and leave the untested mechanism open.

Trap 6 · Epistemic Ladder: Co-occurrence, Linkage, and Causal Identification

Keep five epistemic tiers strictly separate in every finding:

TierWhat the evidence establishesPermitted phrasing
1. Observed factDirectly present in a verified raw record or primary artifact"Logged 24 signups in Week 8: 4 in-territory, 5 unknown, 15 excluded."
2. Temporal co-occurrenceTwo series moved in adjacent windows without paired statistical testing or linkage"Traffic peak and inquiry wave occurred in adjacent days; no link established."
3. Correlation / recorded linkagePaired association across observations, OR row-level join key recording a touchpoint (still not causal lift by itself)"Tracked via utm_content: 9 inquiries tagged Post A (recorded attribution; incremental lift unmeasured)."
4. Identified causal effectRandomized experiment, holdout, geo-lift, or valid quasi-experimental control (can identify incremental lift without row-level join keys)"14-day geo holdout showed +18% net qualified demos vs. matched control regions."
5. Hypothesis / UnknownUnverified mechanism, missing join key, or unrecorded downstream outcome"Item-to-lead join key is absent (null); revenue closure unrecorded."

When neither an experimental/quasi-experimental control nor a verified join key exists, forbid single-item causal attribution and recommend adding the missing join key or running a controlled test.

Stage 3 Handoff Check (complete before writing recommendations):

  • Cumulative comparisons matched on a common follow-up horizon; right-censored cohorts explicitly separated
  • Pulse concentration checked on applicable (N ≥ 7, non-negative) series and distinguished from sustained median shifts
  • Physical strata used; zero circular metric-in-bucket comparisons
  • Eligible population, known outcomes, unknowns, and exclusions separated
  • Primary artifacts inspected for causal claims (matched counterexample when comparative); missing artifacts marked uninspected
  • Every claim placed at its verified tier on the 5-tier epistemic ladder

Stage 4 · Output Falsifiable Decisions and Conditional Handoffs

  1. For actionable decisions, structure a complete decision contract (if rendering an HTML page, defer page layout to report-with-html's decision-card component):
    • Options compared: concrete choices, including status quo or phased test.
    • Phased gating for paid or risky moves: separate Phase A (zero-spend readiness: original notice/eligibility check, tracking join key, assigned owner) from Phase B (capped small-batch test with explicit spend cap and review horizon).
    • Complete decision matrix: specify ONE primary outcome metric, its comparator (control group or matched pre-period baseline), budget/time cap, and the exact next action for every result band (pass/continue, intermediate/hold, zero/stop, and incomplete measurement).
  2. Keep three buckets visibly separate:
    • Confirmed Findings (verified raw records + primary artifacts);
    • Decisions & Thresholds (or scoped descriptive summary / one-off repair actions when no recurring test is needed);
    • Open Unknowns & Missing Evidence (explicitly retained, never guessed).
  3. Conditional downstream handoffs:
    • Need charts → load data-visualization-discipline before drawing.
    • Need a standalone HTML report or interactive workbench → hand off to report-with-html (paired with data-visualization-discipline). If unavailable in the host, report that HTML packaging is unavailable rather than substituting an unverified template.

Pre-Delivery Analytical Gate (7 Checks)

Mark any inapplicable item explicitly (N/A: <reason>) rather than skipping it:

  1. Outcome vs. Proxy: Does the headline answer the real business outcome(s) from Stage 1, with proxy metrics explicitly demoted?
  2. Source, Safety & Scope: Are source paths (archived canonical or read-only scratch), cutoffs, destination privacy checks, and verified / unavailable / unauthorized / inapplicable baseline statuses stated honestly?
  3. Baseline & Pulse (applicable series): On matched-grain non-negative time series (N ≥ 7), are spikes benchmarked against P50 / P25–P75 / P90 and top-2 concentration, separating pulses from sustained regime shifts?
  4. Horizon & Scale Fairness: Are cumulative comparisons matched on a common follow-up horizon, right-censored cohorts protected, incomparable pools stratified (or explicitly weighted/standardized), and circular bucketing eliminated?
  5. Denominators, Unknowns & Source Rates: Are eligible population, known outcomes, unknowns, and exclusions kept separate (never folding all-unknown into 0%), and source-only percentages explicitly labeled as lacking raw counts?
  6. Primary-Source Verification: Was every comparative artifact/content causal claim (not already identified by a Tier-4 randomized or holdout design) checked against primary artifacts (winner + pre-outcome-matched counterexample), with missing artifacts marked uninspected?
  7. Epistemic & Decision Completeness: Does every claim stay within its verified tier on the 5-tier ladder, and does every proposed decision define outcome, comparator, cap, review horizon, and actions across all result bands (or N/A for purely descriptive / one-off repair tasks)?