Calculates the American Moneyline.
p: The probability.
From the referenced Wikipedia article:
Moneyline odds are favored by American bookmakers. There are two possibilities, the figure quote can be either positive or negative.
Moneyline odds are often referred to as American odds. Moneyline refers to odds on the straight-up outcome of a game with no consideration to a point spread.
If the figure quoted is positive, the odds are quoting how much money will be won on a $100 wager (this is done if the odds are better than even). Fractional odds of 4/1 would be quoted as +400, while fractional odds of 1/4 cannot be quoted as a positive figure.
If the figure quoted is negative, then the moneyline odds are quoting how much money must be wagered to win $100 (this is done if the odds are worse than even). Fractional odds of 1/4 would be quoted as -400, while fractional odds of 4/1 cannot be quoted as a negative figure.
Even odds are quoted as +100 or -100. Some bookmakers display the negative symbol while others do not.
Calculate the moneyline for a win percentage of 25%.
|.25||p||0.2500||Stores the p value.|
|ml||300.0000||Calculates the ml value.|
For a moneyline of +200, what is the win probability?
|200||ml||200.0000||Stores the ml value.|