/benfordpy

Using Benfords law with python against datasets

Primary LanguagePythonOtherNOASSERTION

Newcomb-Benfords Law

Benford's Law, also called the Newcomb–Benford law, the law of anomalous
numbers, or the first-digit law, is an observation about the frequency
distribution of leading digits in many real-life sets of numerical data. The
law states that in many naturally occurring collections of numbers, the leading
digit is likely to be small. For example, in sets that obey the law, the number
1 appears as the leading significant digit about 30% of the time, while 9
appears as the leading significant digit less than 5% of the time. If the
digits were distributed uniformly, they would each occur about 11.1% of the
time. Benford's law also makes predictions about the distribution of second
digits, third digits, digit combinations, and so on.

Goal

Measure and plot the occurrence of integers 1 through 9 from 
user provided dataset.
Measure the occurrence of each integer in the first place value in set.
Extended: measure and plot occurrence of int for each place value.

Documentation

Code Contribution Guidelines

* Fork away and refactor | add code. I encourage pull requests to allow for review and discussion of code changes.
* When creating a pull request:
    * Have test cases for the new code.
    * Add documentation if you are adding new features or changing functionality.
    * Converge commits. `git rebase -i`.