↓ Skip to main content
  1. Glossary/

Class imbalance

A data set in which one class is much rarer than the other, such as fraud among payments or a disease among patients. With class imbalance, accuracy is misleading, because a model that always predicts the common class scores high.

A bank has 1,000,000 payments, and 1,000 of them are fraud. A model that calls every payment legitimate is right 999,000 times: 99.9% accuracy. It catches no fraud.