Exoddic v1.3.2 Exoddic
A means for working with odds and probability.
In particular, a means to convert between different representations.
Summary
Types
A keyword list with conversion options
Functions
Convert values among the various supported odds formats
Types
exoddic_options :: [from: atom, to: atom, for_display: boolean]
A keyword list with conversion options
The to
and from
formats are identified by atoms corresponding to
the converter module names. They default to :prob
from
: the supplied input formatto
: the desired output formatfor_display
: whether to nicely format the output as a string, defaults totrue
Functions
Specs
convert(number | String.t, exoddic_options) ::
String.t |
float
Convert values among the various supported odds formats.
Conversion amounts provided as strings will receive a best effort attempt at conversion to an appropriate number.