Benford's Law Calculator
Enter observed frequencies for first digits 1–9 to see how closely they match Benford's logarithmic distribution.
| Digit | Expected % | Observed Count | Observed % |
|---|---|---|---|
| 1 | 30.10% | — | |
| 2 | 17.61% | — | |
| 3 | 12.49% | — | |
| 4 | 9.69% | — | |
| 5 | 7.92% | — | |
| 6 | 6.69% | — | |
| 7 | 5.80% | — | |
| 8 | 5.12% | — | |
| 9 | 4.58% | — |
Total Observations
0
Chi-square Statistic
—
df = 8. Compare with chi-square table for significance.
How to Use This Calculator
- Collect the leading digits (1–9) from numerical records, such as financial transactions or energy readings.
- Enter the count for each digit. Leave blanks for digits that do not appear.
- Review expected versus observed percentages and the chi-square statistic.
- Use the interpretive note to decide whether the dataset aligns with Benford’s Law.
Formula
P(d) = log10(1 + 1 / d)
χ² = Σ (Oi − Ei)² / Ei
Ei = total observations × P(digit i)
Benford’s distribution emerges in scale-invariant datasets and follows a logarithmic pattern. The chi-square test assesses whether discrepancies between observed and expected counts are statistically significant.
Frequently Asked Questions
What kinds of data follow Benford’s Law?
Datasets spanning multiple orders of magnitude—such as tax returns, scientific measurements, or population figures—often follow Benford’s Law. Data with imposed minimums or maximums may not.
How many records do I need?
More data increases test reliability. A few hundred observations provide a reasonable baseline; small samples may yield unstable results.
Can I compare multiple datasets?
Yes. Run the calculator separately for each dataset and compare chi-square statistics to spot anomalies.
Does a high chi-square prove fraud?
Not necessarily. It indicates deviations worth investigating. Combine Benford analysis with domain knowledge and additional auditing techniques.