Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email
?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
Join the forums now, and start posting to receive access to our Scripts Vault!
Home
Forum
Help
Login
Register
BBGameZone.net
»
Webmasters
»
Coding Discussion
»
Code Help
»
dynamic betting
« previous
next »
Print
Pages: [
1
]
Go Down
Author
Topic: dynamic betting (Read 1221 times)
Garbit
Level 4
Posts: 10
Reputation: +0/-0
dynamic betting
«
on:
July 03, 2008, 01:08:15 PM »
Im trying to write a script to calculate a decimal odd dependant on the amount of people betting on an outcome.
For example
team a - 1.25 (30% of bets)
team b - 1.05 (60% of bets)
draw - 6 (10% of bets)
Now when i bet on team a, i want the odds to change for all other outcomes including itself, relative to the current popularity of each outcome.
I hope that makes sense
There are 2 ways in which i can think this could be written,
Firstly, and probably the worst, by having thresholds such as if 20% of bets are placed on team a then increment the team b odds so that the payout is larger and by this token also decrement the team a because it is obviously the favorite.
Secondly, i think somehow it is possible to work out the ratio of bets made in total in comparison to the bets made on a single outome and then find out how relative that is to all other outcomes. Once this ratio is found, have an multiplying factor which can be applied to all three outcomes.
Any other offers are really really welcome
Thanks
Logged
mobeamer
Level 13
Posts: 93
Reputation: +0/-0
Re: dynamic betting
«
Reply #1 on:
July 03, 2008, 01:49:13 PM »
My 2 cents,
Actually you may want to look at it a bit differently (or maybe I'm thinking about it wrong, but what about this.)
Figure out a base ratio, if all things are equal...
Team A: 5.0 (33.33%) (0 bets)
Team B: 5.0 (33.33%) (0 bets)
Draw X: 5.0 (33.33%) (0 bets)
Now, you have to decide what the modifier is for each percentage point movement. Let's say the modifier is .10 point for every 1% change from 33.33%. After 5 votes are placed.
Team A: 6.7 (50%) (2 bets) (50%-33% = 17 * .10 = 1.7 point change)
Team B: 4.2 (25%) (1 bets) (25%-33% = 8 *.10 = .8 point change)
Draw X: 4.2 (25%) (1 bets)
You'll have to play with the modifiers to get the number closer to where you want.
That seems like a simple solution to me...
Logged
I build games
My Blog
Garbit
Level 4
Posts: 10
Reputation: +0/-0
Re: dynamic betting
«
Reply #2 on:
July 03, 2008, 03:45:42 PM »
That idea is similar to my threshold idea, however the only problem i can see is that the numbers will always increase which means i could be paying out 100's times the money bet.
So there must be some way of having a deduction on the most betted outcome otherwise it would just get higher and higher.
really appreciate the help!
Keep those suggestions going!
«
Last Edit: July 03, 2008, 03:48:55 PM by Garbit
»
Logged
Garbit
Level 4
Posts: 10
Reputation: +0/-0
Re: dynamic betting
«
Reply #3 on:
July 03, 2008, 04:13:14 PM »
oh wait i see what you've done, the 25% - 33% is a negative. I understand, this could sound like a very good idea indeed.
The only problem i see is that when more people bet on an outcome, the outcome's odds should then DEcrease and become lower so that the payout is less, as they are the obvious favorite. This in turn should be the opposite for the other less betted options and the difference should be an increase in thier multiplier factor.
«
Last Edit: July 03, 2008, 04:24:21 PM by Garbit
»
Logged
Garbit
Level 4
Posts: 10
Reputation: +0/-0
Re: dynamic betting
«
Reply #4 on:
July 03, 2008, 05:45:31 PM »
i've found something really interesting and its about working out odds and thier probabilites using decimal form.
http://www.isfa.com/betting-odds-probability.php
Basically you take the multiplier from our equation and drop it into this:
100/x = probability% (in my case probability is substituted as payout percentage)
Although this isn't what im after entirely, the idea of the payout system could work. Just because more people have bet on an outcome it does not make it more probable, however it does make it more popular which suggests its a more probable outcome.
Logged
saljutin
Level 22
Posts: 266
Reputation: +6/-0
Re: dynamic betting
«
Reply #5 on:
July 14, 2008, 05:34:26 AM »
what if you change your view on this problem
lets say something like this:
team A: 10 people (50% of people)
team B: 5 people (5% of all)
draw: 5 people (25% of all)
so lets say all people invest 10credits each for bet, that would mean total money invested is 200, and lets say you want to return all money invested to people. so we get to this
teamA: 10 people, 100 invested => 2.00 (200/100)
teamB: 5 people, 50 invested => 4.00 (200/50)
draw: 5 people, 50 invested => 4.00 (200/50)
so now one more guy comes and bets to teamB. new rates:
total is now 200+1*10 = 210
teamA: 10 people, 100 invested => 2.00 (210/100)
teamB: 6 people,60 invested => 3.50 (210/60)
draw: 5 people, 50 invested => 4.20 (210/50)
also I really like money flow so that it comes and goes from somewhere. so what happens when we wanted to have starting bet of 1.10 meaning that all people bet on 1 result...because of above system that would mean all/all=1.00, so we make something like this:
100 people would bet pay 1000 so they would get 1100 back as a credit = 1000/1100 =0.909090 = 0.90 so now we take that number to calculate % from total invested money:
BEFORE:
total invested 100+50+50=200 <- we return this number into system
teamA: 10 people, 100 invested => 2.00 (200/100)
teamB: 5 people, 50 invested => 4.00 (200/50)
draw: 5 people, 50 invested => 4.00 (200/50
NEW:
total invested 100+50+50=200
we modify this number with our 0.90 => 200*0.9=180 <- we return this number into system
teamA: 10 people, 100 invested => 1.80 (180/100)
teamB: 5 people, 50 invested => 3.60 (180/50)
draw: 5 people, 50 invested => 3.60 (180/50)
IF quota gets less then 1.10 then we change it to 1.10
I think this is good idea for some system like mafia one where you have horse races and lets say 5 players have concession to take bets from players. they would choose minimum coefficient of the bet (1.10 or 1.05 or 1.20 or even 2.00), and percentage of money that is given back to players when bets are resolved.
comments please
Logged
My Blog
http://phpgamedev.blogspot.com/
Garbit
Level 4
Posts: 10
Reputation: +0/-0
Re: dynamic betting
«
Reply #6 on:
July 16, 2008, 09:39:18 AM »
I'll have to read this a couple more times because i've just woke up. But yes the other algorithm i noticed would only increase continually even if LESS people started betting on the previously more populated team. I did write a quick script with just text output of all values and it did really wierd things.
I think that when i generate each new bet odd i need to consider the change from previous bet odds and then either minus or plus that change to the new bet odd. I'll make another post when i've woken up properly with some numbers but im glad someone else is thinking about this
Logged
Garbit
Level 4
Posts: 10
Reputation: +0/-0
Re: dynamic betting
«
Reply #7 on:
July 16, 2008, 09:44:58 AM »
Btw the higher the decimal number the lower the possiblility of that outcome happening when using the idea i posted before.
E.g. 100/x = probability
so
100/8 = 12.5%
100/3 = 33.33%
Logged
Print
Pages: [
1
]
Go Up
« previous
next »
BBGameZone.net
»
Webmasters
»
Coding Discussion
»
Code Help
»
dynamic betting
SimplePortal 2.3.3 © 2008-2010, SimplePortal