Description Usage Arguments Value Examples
Calculate the fair (vigorish free) odds for a vector of vigged odds.
1 2 |
... |
Odds of the format defined in input, the odds can be submitted as a data.frame or as a vector |
input |
Default to US Odds. Valid selections are "us" for US odds, "prob" for Probability ,"dec" for Decimal odds,"malay" for Malaysian odds, "hk" for Hong Kong odds, "indo" for Indonesian odds |
output |
Default to US Odds. Valid selections are "us" for US odds, "prob" for Probability ,"dec" for Decimal odds,"malay" for Malaysian odds, "hk" for Hong Kong odds, "indo" for Indonesian odds |
Vectorized2wayOutput1stElement |
This speeds up the calculation as the output is a a vector that contains the FV of the first input. Usefull in dplyr chains. |
A vector or a matrix of the fair values of the the given vigged values in the format chosen in output
1 2 3 4 5 6 7 | odds.fv(-120,110)
odds.fv(2.05,3.12,2.90,input="dec",output="prob")
df <- data.frame(Home = c(1.5,1.8,1.9),
Away = c(2.9,2.2,2.05))
odds.fv(df,input = "dec",output = "prob")
odds.fv(df$Home,df$Away,input="dec",output="prob")
odds.fv(df$Home,df$Away,input="dec",output="prob",Vectorized2wayOutput1stElement = TRUE)
|
X.120 X110
-114.5455 114.5455
X2.05 X3.12 X2.9
0.4230212 0.2779466 0.2990322
Home Away
[1,] 0.6590909 0.3409091
[2,] 0.5500000 0.4500000
[3,] 0.5189873 0.4810127
df.Home df.Away
[1,] 0.6590909 0.3409091
[2,] 0.5500000 0.4500000
[3,] 0.5189873 0.4810127
[1] 0.6590909 0.5500000 0.5189873
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.