PyProbs¶
Get True or False from a probability, whether you write it as a
float, a percentage or a fraction.
PyProbs turns a probability into a decision. Ask for "25%" and roughly one call in four returns True. You can draw
once, draw many times in a single call, or keep an instance around that remembers every result and counts them for you.
-
Any notation
0.25,"25%","1/4"and"0.25"all mean the same probability. -
Quick or tracked
Probability.prob()draws without any setup, while an instance'siprob()records a history you can count. -
Typed
Ships with type hints and is checked with mypy in strict mode.
-
No dependencies
Pure Python, nothing else to install.