Fun with Excel #19 – Defending the World Cup

The World Cup is undoubtedly one of the most prestigious tournaments in all of sports. Although the competition has been held 21 times since its debut in 1930, only eight national teams have won it: Brazil (5 times), Germany (4), Italy (4), Argentina (2), France (2), Uruguay (2), England (1), and Spain (1). Only twice has a World Cup champion successfully defended the title (Italy in 1938 and Brazil in 1962). This is not too surprising, given that the tournament is held once every four years, which can be a lifetime in professional sports.

Summary of World Cup Results, 1930–2018
Points Per Game for Defending Champions (Red Bars = Eliminated in the First Round / Group Stage)

The above charts show the performance of every defending champion since 1930, as well as their average points per game (Win = 3 points, Draw = 1 point, Loss = 0 points). Interestingly, since the World Cup expanded to 32 teams in 1998, the defending champion has lost in the group stage (i.e. failed to reach the knockout stage) in four out of the last six World Cups, including the last three tournaments.

One potential explanation for these early exits is the increase in competition over the last 20 years, both from the higher number of teams participating in the World Cup, as well as the rise in overall skill levels which has led to more parity among nations. Even so, out of the four most recent instances where the defending champions were eliminated in the group stage (France in 2002, Italy in 2010, Spain in 2014, and Germany in 2018), all four countries entered their respective World Cups ranked in the top 20% of all teams. On top of that, all of them had favorable groups from which they were expected to advance. So who suffered the worst group stage exit from a defending champion?

A Slight Detour on Methodology

To analyze each team’s performance, I not only examined their win/loss records, but also how they played relative to expectations. I accomplished the latter by comparing each defending champion’s Elo rating to the ratings of all the nations competing in World Cup. I also compared each team’s Elo to the ratings of the other three nations in its group to determine how difficult it would be for each team to advance from the group stage.

Used widely across sports, board games, and video games, the Elo rating system calculates the relative skill of players (or teams) based on match outcomes.

After every game, the winning player takes points from the losing one. The difference between the ratings of the winner and loser determines the total number of points gained or lost after a game. In a series of games between a high-rated player and a low-rated player, the high-rated player is expected to score more wins. If the high-rated player wins, then only a few rating points will be taken from the low-rated player. However, if the lower-rated player scores an upset win, many rating points will be transferred.

Wikipedia

In soccer, the rating system is further modified to account for the goal difference of the match, such that a 7–1 victory will net more rating points than a 2-1 win. Thus, we expect nations with higher pre-World Cup Elo ratings to perform better than those with lower ratings, which the chart below illustrates.

The relationship isn’t perfect, but we can see that teams with higher Pre-World Cup Elo ratings tend to perform better during the tournament

We’re more interested in the outliers on the right side of the chart, so without further adieu, here is my ranking for the “worst of the worst” World Cup defenses.

The Hall of Shame

4. Italy (2010): 0W/2D/1L, -1GD

Italy entered the tournament with the sixth highest Elo (1938), 142 above the average of 1796
Italy had the fifth easiest group (out of eight) in the first stage of the tournament

In 2010, Italy (1938 Pre-WC Elo) drew Paraguay 1–1 (-14 Elo), drew New Zealand 1–1 (-24 Elo), and lost to Slovakia 2–3 (-50 Elo) in Group F, for a cumulative loss of 88 Elo. In doing so, it gained the dubious honor of being the only defending champion to be eliminated in the first round twice (1950 was the first time). That said, compared to other early exits, this one was slightly more forgivable. For one, Italy entered the World Cup ranked sixth by Elo, by far the weakest of the four most recent defending champions that failed to advance past the group stage. Italy also had the fifth easiest group (out of the initial eight), the only defending champion to start off in the bottom half of group difficulty.

3. Spain (2014): 1W/0D/2L, -3GD

Spain entered the tournament with the second highest Elo (2109), 267 above the average of 1842
Spain had the third easiest group (out of eight) in the first stage of the tournament

In 2014, Spain (2109 Pre-WC Elo) lost to the Netherlands 1-5 (-75 Elo) in a re-match of the 2010 Finals, lost to Chile 0-2 (-57 Elo), and beat Australia 3-0 (+16 Elo) in Group B, for a cumulative loss of 116 Elo. Spain entered the World Cup with the second highest Elo overall and played in the third easiest group, but still found themselves mathematically eliminated after only two games, the quickest exit for a defending champion since Italy in 1950 tournament. Pretty embarrassing, but still not enough to make our Top 2…

2. Germany (2018): 1W/0D/2L, -2GD

Germany entered the tournament with the second highest Elo (2077), 249 above the average of 1828
Germany had the second easiest group (out of eight) in the first stage of the tournament

In 2018, Germany (2077 Pre-WC Elo) lost to Mexico 0-1 (-47 Elo), beat Sweden 2-1 (+14 Elo), and lost to South Korea 2-3 (-80 Elo) in Group F, for a cumulative loss of 113 Elo. For the first time since 1938, Germany did not advance past the first round. Although this remarkable streak was bound to end at some point, almost no one would have thought that 2018 would be the year. After all, Germany entered the World Cup with the second highest Elo and also played in the second easiest group.

Unlike the Spanish team in 2014, which appeared to be on its last legs after a remarkable run from 2008 to 2012 during which it won back-to-back European titles and a World Cup, the German team was seemingly still near the height of its powers. Indeed, their early “exit at group stage was greeted with shock in newspapers around the world,” according to The Guardian.

1. France (2002): 0W/1D/2L, -3G

France entered the tournament with the highest Elo (2096), 274 above the average of 1822
France had the easiest group (out of eight) in the first stage of the tournament

In 2002, France (2096 Pre-WC Elo) lost to Senegal 0-1 (-54 Elo), drew Uruguay 0-0 (-19 Elo), and lost to Denmark 0-2 (-61 Elo) in Group A, for a cumulative loss of 134 ELO. Shockingly, the French failed to win a single match despite starting the World Cup with the highest Elo and playing in the easiest group. Perhaps more embarrassing, the team bowed out without scoring a single goal, good enough for the worst performance ever by a defending champion.

An Important Caveat

Of course, one should never draw conclusions solely from data, because knowing the context surrounding the data is just as crucial. As Gareth Bland rightly points out in his article detailing the story behind France’s failure in the 2002, several factors contributed to the team’s early exit besides mere under-performance:

  1. France’s star player, Zinedine Zidane, regarded as one of the greatest players of all time, injured himself in a friendly less than a week before the team’s first match against Senegal. He returned for France’s third match against Denmark, but was clearly not 100%.
  2. Thierry Henry, considered one of the best strikers to ever play the game, committed a poor challenge in the second match against Uruguay and received a red card. Although France managed to scrape a tie while down one man, Henry was forced to miss the third match because of the red card.
  3. Many members of France’s old guard like Marcel Desailly, Frank Leboeuf, and Youri Djorkaeff were pushing their mid-thirties. Although not old by any stretch of the imagination, they were undoubtedly past their prime as players.
  4. On the other hand, the team’s younger players like Patrick Vieira, Sylvain Wiltord, and Henry found themselves mentally and physically exhausted after a successful but grueling campaign with their domestic club Arsenal.

While none of these reasons should pass as excuses (after all, other teams had to deal with injuries and fatigue as well), this perfect storm of events helps to explain why France so drastically under-performed relative to their Elo rating. As Bland writes, the team’s “return home was not met with disgrace…Rather, it was an acknowledgement that some legs had got tired, while some needed to be moved on, while those of the maestro must just be left to heal.”

Lessons Learned?

One last observation is that none of the four defending champions won their opening matches (Italy drew, and the other three lost). With every match being so critical to advancing, a poor start likely put a tremendous amount of pressure on the defending champions and affected their remaining two matches. Perhaps the defending champions failed because of their relatively easy groups, which led them to become complacent going into the first match. In that case, the biggest takeaway is to not be overconfident, advice that I hope team France will heed going into Qatar 2022.

As always, you can find my work here.

Fun with Excel #18 – The Birthday Problem

Meeting someone with the same birthday as you always seems like a happy coincidence. After all, with 365 (366 including February 29th) unique birthdays, the chances of any two people being born on the same day appear to be small. While this is indeed true for any two individuals picked at random, what happens when we add a third, a fourth, or a fifth person into the fray? At what point does it become inevitable that some pair of people will share a birthday?

Of course, the only way to guarantee a shared birthday among a group of people is to have at least 367 people in a room. Take a moment to think about that statement, and if you’re still stumped, read this. Now that we know 100% probability is reached with 367 people, how many people would it take to reach 50%, 75%, or 90% probability? If you think the answer is 184, 275, and 330, then you would be quite wrong. Here’s why:

Let’s assume that all birthdays are equally likely to occur in a given population and that leap years are ignored. To paint a more vivid picture in our minds, let’s further assume that we have a large room and that people are entering the room one at a time while announcing their birthdays for everyone to hear. The first person enters the room and announces that his/her birthday is January 1st (we can choose any date we want without loss of generality). The second person has a 364/365 probability of having a different birthday from the first person and therefore a 1 - 364/365 probability of having the same birthday. The third person has a (364/365) \times (363/365) probability of having a different birthday from either of the first two people and therefore a 1 - (364/365) \times (363/365) probability of having the same birthday as either of first two people. The fourth person has a (364/365) \times (363/365) \times (362/365) probability of having a different birthday from any of the first three people and therefore a 1 - (364/365) \times (363/365) \times (362/365) probability of having the same birthday as any of first three people. To generalize, the probability of the nth person being the first person to have the same birthday as any of the n-1 people before him/her is:

P(n) = 1- \frac{364}{365} \times \frac{363}{365} \times \frac{362}{365} \times \cdots \times \frac{365-n+1}{365}

Note that the yellow series in the above graph grows exponentially rather than linearly, with the probability reaching 50% at just 23 people. 75% and 90% probability are reached at 32 and 41 people, respectively. By the time 70 people are in the room, there is a greater than 99.9% chance that two individuals will have the same birthday!

As the number of people increases, P(n) switches from exponential to logarithmic, with each additional personal providing less incremental probability than the previous. Interestingly, the 20th person provides the greatest incremental probability, as seen in the above table.

In contrast, the probability that any one person has a specific birthday is denoted by the much simpler equation:

P_1(n) = 1 - \left( \frac{364}{365} \right)^n

This relationship, which is highlighted by the green series in the graph, grows at a much slower rate than the yellow series. In comparison, it takes 253 people for P_1(n) to exceed 50%.

Testing Our Assumptions

One key assumption we made in the above exercise was that all birthdays (aside from February 29th) occur with equal probability. But how correct is that assumption? Luckily, Roy Murphy has run the analysis based on birthdays retrieved from over 480,000 life insurance applications. I won’t repeat verbatim the contents of his short and excellent article, but I did re-create some charts showing the expected and actual distribution of birthdays. The bottom line is that the actual data show more variation (including very apparent seasonal variation by month) than what is expected through chance.

Implications on Birthday Matching

Now that we know that birthdays in reality are unevenly distributed, it follows that matches should occur more frequently than we expect. To test this hypothesis, I ran two Monte Carlo Simulations with 1,000 trials each to test the minimum number of people required to get to a matching birthday: the first based on expected probabilities (each birthday with equal likelihood of 1/365.25 and February 29th with likelihood of 1/1461) and the second based on actual probabilities (sourced from the Murphy data set).

Note that the distributions of both simulations are skewed positively (i.e. to the right). The results appear to corroborate our hypothesis, as evidenced by the gray line growing at a faster rate than the yellow line in the above graph. Indeed, the average number of people required for a birthday match is 24.83 under the simulation using actual probabilities, slightly lower than the 25.06 using expected probabilities. However, the difference is not very significant; therefore, our assumption of uniformly distributed birthdays works just fine.

As always, you can find my work here.

Fun with Excel #7 – A Better Chance of Winning One Billion Dollars

Warren Buffett and Quicken Loans made quite a splash last week when they announced that they would be awarding $1 billion to anyone who filled out a perfect bracket for this year’s NCAA Men’s Division I Basketball Tournament.

As many news articles all over the web have already pointed out, the total number of possible variations is enormous. In a single-elimination bracket involving 64 teams, there are exactly 63 matches played. As each match can have two outcomes, the total number of possible outcomes is 2^63, or 9,223,372,036,854,780,000 (roughly 9.2 quintillion).

However, without knowing too much about basketball, much less having an educated view of which teams are most likely to make the tournament this year, we can actually narrow that number down by quite a bit.

Part A: The first and most important step is noting that in the history of the tournament, no #1 seed has ever lost to a #16 seed in the first round (116-0). Assuming things stay that way this year, we can reduce the number of variations to 2^59 (since 4 of the matches are decided), which is 576,460,752,303,423,000. This is a still a massive number, but only 6.25% of the theoretical total.

Part B: Continuing off of A, we can build on the concept of upsets to further narrow the number of bracket variations. If we define an upset as simply any result where a lower ranked seed defeats a higher ranked seed, then the result of every match becomes binomial: it is either an upset, or it isn’t. This is a powerful notion, because we can now think of the total number of variations as the sum of distinct sub-variations based on the number of upsets. In a tournament consisting of 63 matches, there can either be 0 upsets, 1 upset, 2 upsets, 3 upsets…62 upsets, or 63 upsets. Furthermore, there is (63 choose 0)=1 way of achieving 0 upsets, (63 choose 1)=63 ways of achieving 1 upset, etc. Summing up all of these terms in fact gives us 9,223,372,036,854,780,000, which is what we expect. Astute readers will note that this is simply a combinatorial identity demonstrated by Pascal’s Triangle, but it is nonetheless meaningful to take a moment to verify this identity yourself if you’ve never encountered it. While it is theoretically possible for any number of upsets to occur during a particular tournament, the last five NCAA tournaments have all had between 16 and 20 upsets (average of 18.4). Thus, if we only consider brackets with  15 to 22 upsets (going out by ~2 standard deviations on both ends for some margin of safety), the number of variations drops down to 19,420,762,596,874,200, or 0.211% of the theoretical total.

Part C: We make one last simple observation to refine our analysis: for any given tournament, most of the upsets (about 50%) occur in the first round (average of 9.2), with no less than 7 upsets in the first round over the last five years. Thus if we disregard all the bracket variations in B that include 5 upsets or less in the first round, we can cut down the number of variation by an additional 200 trillion of so, giving us 19,219,810,265,601,500 variations, or 0.208% of the theoretical total.

Science has also shown that you are more likely to click on a colorful graphic.

Conclusion:  Clearly, the odds of predicting a perfect bracket is still extremely small. However, the key takeaway here is that even with no knowledge of college basketball, we can quickly reduce the total theoretical number of bracket variations by almost three orders of magnitude to a more practical number by using basic probability concepts and making a few simple assumptions.

P.S. While you do have a better chance of winning the lottery than getting your hands on the grand prize of 1 billion dollars, the NPV of this particular “investment” is still positive since the cost of registration is free 😛

Fun with Excel #5 – Monte Hall Meets Monte Carlo

The famous Monte Hall Problem poses the following question: “Suppose you’re on a game show, and you’re given the choice of three doors. Behind one door is a car, behind the others, goats. You pick a door, say #1, and the host, who knows what’s behind the doors, opens another door, say #3, which has a goat. He says to you, ‘Do you want to pick door #2?’ Is it to your advantage to switch your choice of doors?”

While the intuitive answers seems to be “no,” as one might argue that the two remaining doors are equally likely to contain the car, the correct answer is actually “yes.” As vos Savant points out later on in the above link, the probability of winning if you switch is actually 2/3.

But what if you wanted to find the solution without using probability directly? One way is through a Monte Carlo Simulation, which involves running a simulation of the game numerous times in order to calculate the probabilities of winning heuristically. The idea is that as the number of observations increases, the average of the results will coincide with the expected value.

For instance, if we run the simulation 1,000 times, we see a fair amount of volatility in the results over the first 250 and even 500 trials. As we add more trials, however, the average of the results begin to converge to the true expected values: 2/3 chance of winning if we switch doors, and 1/3 chance if we don’t.

The results are even more concrete if we consider 10,000 trials:

And there you have it, a simple application of Monte Carlo Simulation to support one of the more counter-intuitive results in probability theory.