I've worked on this website since beginning of 2014 in my spare time. The initial goal was to have fun with lot of data.
The idea is to count StackExchange badges of an user in the same way as TrueAchievements does. This project has no practical use, you can view it as a fun website in order to have an overview of the efforts you put in StackExchange websites.
TrueAchievements is a website dedicated to Xbox and Windows games' achievements. Achievements are rewards given to players for realizing specific actions (complete a game, win 20 rounds in online game, etc.). Each achievement is associated with a score from 0 to 300 (or more). The idea behind TrueAchievements is that the score can be corrected by the percentage of players having unlocked an achievement compared to the numbers of players who own a game. For example, it's easier to get 5 points by starting the game GTA IV than meeting all the random characters. So the first achievement is worth 5 TA score and the second one is worth 13 TA score.
StackExchange Badges (SEB)
Badges are very similar to achievements, but they are only associated to bronze, silver or gold rank, they have no value in points.
I want to use the same calculation in order to calculate a score based on the SEB earned by an user in all of the StackExchange websites. Note that this score is different from the reputation, even if the two scores are more or less correlated (eg. good answers give reputation and badges).
The value of each badge is calculated from the number of times a badge has been earned divided by the number of times the most earned badge has been earner. In other words, the rarest badges will be worth more points. The formula is still not perfect, I have to decide if I should cap score of each badge. Some badges are awarded only once, their value can be huge.
For each site, the website (TrueBadges) need to grab all the badges and the number of times they are awarded. Then the score of each badge can be calculated. Edit: the formula has been designed with the help of Mathematics (Stack Exchange).
Once a user register to TrueBadges (the only required data is the id of the user on StackExchange), the website has to make several requests:
- Get the websites where the user logged in (StackOverflow, Arqade, etc.)
- Get all the badges from the user on each site
- Calculate the score for each badge of the user (a badge can be earned multiple times, so the value of a badge can be multiplied)
- Calculate the score for each site
- Calculate the total score of the user
I use Symfony2 (a PHP framework) and Doctrine2 (an abstraction layer for MySQL).
Here is the current database schema: