williamleonard / obblm

Automatically exported from code.google.com/p/obblm
1 stars 0 forks source link

ELO in Standings Showing Incorrect Value? #451

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Change HRS to use ELO
 // Rule #4
$hrs[4]['rule']   = array('-elo', '-pts'); // Sort Teams agains: ELO, Games 
Played
$hrs[4]['points'] = '1*[won] + 1*[draw] + 1*[lost]'; // The definition of points

2. Play/Submit a few matches
3. Review Standings (Tournament using HRS 4)

What is the expected output? What do you see instead?
 - In the database, TEAM ELOs are 200.575 / 199.425 (two teams went 1W, 1L against each other)
 - In the standings, TEAM ELOs are 210.54 / 198.46

I would expect the TEAM ELOs to be 200.575 / 199.425 in the standings.

Reference URL :: http://98.118.10.228/ select "The Challenge League" to see 
this.

--Micah

What version of the product are you using?

Please provide any additional information below.

Original issue reported on code.google.com by micah.im...@gmail.com on 12 Jul 2010 at 5:42

GoogleCodeExporter commented 9 years ago
I pulled out the 2 games that had been played and even with just the first game 
submitted - the "Team Standings" page shows the Team's ELOs as 210/190

The Frontpage Standings shows them as 219.42 / 180.58

--Micah

Original comment by micah.im...@gmail.com on 12 Jul 2010 at 7:31

GoogleCodeExporter commented 9 years ago
This could be ELO for that specific tournament...

Original comment by funnyfin...@hotmail.com on 13 Jul 2010 at 8:14

GoogleCodeExporter commented 9 years ago
Are there configuration / parameters for ELO - or some calculations for a 
Tournament that are done differently than for a team?

Without any games played, both teams have an ELO of 200 - and no other games 
are played by those teams.  So If their Team ELOs go to 190/210 after a single 
game, why would the standings show them with different ELOs than that?

I'm just trying to understand if there's a difference (and I'm fine with that) 
and/or how I can set the parameters for how ELO functions within a Tournament.

--Micah

Original comment by micah.im...@gmail.com on 13 Jul 2010 at 8:18

GoogleCodeExporter commented 9 years ago
There is a slight difference on my team with the ELO in coach corner vs the ELO 
in a tournament vs another tournament.

319.89 - coach corner
326.29 - in a 8 team KO where I played and won the first game.
319.18 - in the free for all where I have 22 matches (vast majority of matches).

Original comment by funnyfin...@hotmail.com on 14 Jul 2010 at 6:24

GoogleCodeExporter commented 9 years ago
I understand where you are coming from - I just don't understand why there 
should be a discrepancy in the values after playing just 1 game.

With 1 game played - my team's ELO in the "Statistics -> Team Standings" split 
to 210/190, but in the League Standings which are based on ELO.. they were 
showing as more like 180.456 and 219.544.

--Micah

Original comment by micah.im...@gmail.com on 14 Jul 2010 at 9:20

GoogleCodeExporter commented 9 years ago
Examples on display at http://www.iamakkim.com - look at the Free For All 
League.

Original comment by micah.im...@gmail.com on 14 Jul 2010 at 9:24

GoogleCodeExporter commented 9 years ago
I was just giving those as examples.  Not sure why it does that really as if it 
were per tournament I would think it would be around 200 for a single game.

Original comment by funnyfin...@hotmail.com on 15 Jul 2010 at 2:48

GoogleCodeExporter commented 9 years ago
Will have a look at this soon.

Original comment by Nimda...@gmail.com on 27 Jul 2010 at 3:43

GoogleCodeExporter commented 9 years ago
These value are only the same IF you have played all the matches in the same 
tournament.

The ELO value depends on the match sequence in question. 
So, if you are looking at a team in a specific tournament then only those 
matches are included in the ELO calculation, where as on the other hand if you 
are looking in the CC (ie. overall stats) the ELO is calculated on the basis of 
all matches played.
These two results cannot possibly be the same unless all matches played by a 
team are from the same tournament.

Can you verify this?

Original comment by Nimda...@gmail.com on 19 Oct 2010 at 10:31

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
What is there to verify, if you say it is this way then it is this way, right?

Original comment by funnyfin...@hotmail.com on 20 Oct 2010 at 11:14

GoogleCodeExporter commented 9 years ago
Ehm, a late (and probably brief) comeback.
Lets see if I can add to the confusion or clear things up a bit. ;-)

The points you get when you win in ELO is exactly the same as what the loser 
loses. How *many* points you win or lose depends on the previous difference in 
ELO points.

Nicholas is correct in his assessment. (The resulting ELO points are correct, I 
tested it thoroughly when developing. Even had the same matches calculated in 
excel to doublecheck.)

It's possible to change the values for ELO, eg the starting value (hardcoded to 
200) and the "range" (~1-19, almost 0-20 but never reaches it). I would 
recommend NOT messing with the values other than start value, unless you have a 
firm grip of the math behind ELO. (Search for ELO on wikipedia.)

I think this is a non-issue, this is the way ELO is implemented in OBBLM.

/Daniel

PS. I see no need to sort on anything more than ELO, if you want to use ELO. 
The likeliness that two teams end up with same ELO after playing different 
number of matches is very small.

Original comment by blodae@gmail.com on 21 Oct 2010 at 11:38

GoogleCodeExporter commented 9 years ago
I was hoping Micah could verify my explanation :-).

Original comment by Nimda...@gmail.com on 21 Oct 2010 at 11:42

GoogleCodeExporter commented 9 years ago
Thanks Daniel, the only difference is, that the new OBBLM core required that 
your code was in the SQL lang., which I translated it for. This is why I would 
like to have Micah verify it to rule out this maybe being a bug :-).

Original comment by Nimda...@gmail.com on 21 Oct 2010 at 11:47

GoogleCodeExporter commented 9 years ago
Aha, much happens while I'm away. ;-)

Take the most of my last comment with a pinch of salt (and a tequila). :-D

/Daniel

Original comment by blodae@gmail.com on 21 Oct 2010 at 11:56

GoogleCodeExporter commented 9 years ago
:-)
Good to hear from you anyway!

Original comment by Nimda...@gmail.com on 21 Oct 2010 at 12:05

GoogleCodeExporter commented 9 years ago
The real curiosity was to why the value you saw in the team's database entry 
was not the same as the value displayed on the pages when pulling the value.

It just struck me as odd.

As for why we would sort on ELO?  It was a type of league where it was meant to 
be open play against other teams.. and the "champion" would be determined after 
a pre-defined period of time with a minimum number of matches played on that 
team (IE :: 90 days and at least 30 matches).

--Micah

Original comment by micah.im...@gmail.com on 21 Oct 2010 at 3:05

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
I see. 
That's because when looking at the ELO stored in the teams table, it's the all 
time ELO. If, on the other hand, you are looking at the html standings tables, 
these reflect tournament/div/league progress. The ELO value for a given team in 
either of these is saved in the teams' compiled-stats-tables (for 
tours/divs/leagues), which are the mv_* tables.

No, not really, but you can sort teams against it, since the ELO rating system 
is a method for calculating the relative skill levels of players.

Closing.

Original comment by Nimda...@gmail.com on 22 Oct 2010 at 11:27

GoogleCodeExporter commented 9 years ago
@Micah: We did a similar type of open league using ELO (but with minimum 5 
matches played to be included in final results). It worked much better than a 
league with predetermined schedule - the ones wanting to play more were allowed 
to do that. (And dropouts didn't mess up the schedule.) Some coaches even had 
two teams. The only minor balance issue we experienced was with teams that have 
low win ratio to start with but much better when developed. (Chaos for example.)

/Daniel

Original comment by blodae@gmail.com on 25 Oct 2010 at 10:17

GoogleCodeExporter commented 9 years ago
@ Nimda ::

I understand the point you are making - what I don't understand is why after 
only one game there would be a difference.  If you've only played one games 
you'd think they would be the same value regardless.  

I don't lose sleep over it, but it just didn't seem to be working as intended 
from that point of view. =)

@ Daniel ::

Yeah, that's exactly like what we were after.. but in the end we didn't really 
push the critical mass necessary to make it fly between all the other leagues 
we had going on and the crunch of BB:LE coming in.

We'll try again soon now that LE's out.. I'm still hopeful that we can come up 
with a smooth/seamless way of using OBBLM (FunnyFingers did a GREAT job coming 
up with a simple uploader) - similar to the way BBLigue does things.. if we can 
get something that "user friendly" for OBBLM I really see this taking off.

--Micah

Original comment by micah.im...@gmail.com on 25 Oct 2010 at 5:09