Class Imbalance, Exactly

Worked numerical examples showing how skewed label counts shape baselines, confusion tables, accuracy, and recall.

Class imbalance step by step

Count labels, test the majority baseline, and separate accuracy from positive recall and error cost.

  1. Label Counts Are Visible

    inspect class counts and positive share before touching a metric

  2. Always-N Baseline

    what a rule that predicts class 0 for every row gets right and misses

  3. Confusion Counts Show the Miss

    separate true positives, false positives, false negatives, and true negatives

  4. Accuracy Is Four Out of Five

    how (TP + TN) / N reaches 0.8 without catching a single positive row

  5. Positive Recall Is Zero

    why TP / (TP + FN) reads 0.0 on the exact run where accuracy reads 0.8

  6. What Imbalance Does and Does Not Say

    why class skew sets the accuracy floor while domain error cost picks the cutoff