We the North. We Predicted the Champs.

By |2019-06-24T11:42:41-04:00June 24, 2019||

Multivariate Analysis to Predict Basketball ScoresThis past week, as the nation celebrated the Toronto Raptor’s historical NBA championship win, ProSensus got to work doing what we do best – crunching the numbers – for a little bit of fun.  Sure, hindsight is 20/20, but how neat is it that multivariate analysis (MVA) actually predicted that the Raptors would win game 6 of the NBA finals?

Let’s get you some details.  Using the first 23 games of the Raptor’s playoff run (starting with Game 1 of the Conference Quarter Finals), we correlated the score margin (Raptors’ score minus Opponents’ score) from each of the first three quarters to the final game outcome (win or loss) and final game score margin.  

We then applied the resulting model to Game 6 of the NBA Finals.  And as it turns out, a simple 2 component PLS model is able to accurately predict the final game outcome and final game margin with impressive accuracy!  Read on to see the results for yourself.

Using MVA to Predict the Raptors’ NBA Championship

As evident in the Score Plot, the Raptors’ 16 wins are readily distinguished from their 8 losses, across all 4 series and opponents. At this point, I’ll clarify that a Score Plot is a standard visualization used in MVA, and has nothing at all do with the points in the ball game. For your interest, the game boxed in red in the score plot is Game 24, otherwise known as the NBA Finals Game 6.

The observed versus predicted plot shows us that only two games (boxed in green) deviate from our model.  These games were Game 5 of the Conference Finals against Milwaukee and Game 2 of the NBA Finals against Golden State; an unexpected win and loss respectively, according to our model.  Nonetheless, we accurately predict the Raps victory against Golden State in Game 6 of the NBA Finals (boxed in red).

Toronto Raptors Score Plot

Analyzing Game 2 Prediction Error

But let’s backpaddle for a minute, and do a little bit of a post-mortem on one of those unexpected game outcomes.  Let’s go with Game 2 of the NBA Finals.  Why did our model have misguided confidence in the Raptors that night? Referring to the Squared Prediction Error (SPE) plot below, it is clear that Game 2 of the NBA Finals (circled in blue) was an outlier in the dataset, falling well above the 95% confidence interval.  

What made this game an outlier?  A contributions plot tells us that in this game, the Raptors enjoyed a larger-than-average positive game margin (in their favor) in the 2nd quarter, but then sustained a much larger-than-average negative game margin in the 3rd quarter (in Golden State’s favor).

Squared Prediction Error Plot

How Accurate is ProSensus’ MVA Basketball Model?

If you are now pondering the idea of supporting your betting habit with MVA, you’ll definitely be interested in how well our model was able to fit the final game margins across all 4 playoff series.  It’s time to get excited folks: ProSensus’ MVA model fit the final game margins with an R2 of 90%, as illustrated in the observed versus predicted plot below!

In addition, the game outcomes are matched with 100% accuracy when inferred from the final game margin fit by the model.  As illustrated in the plot below, our model accurately shows a loss for Game 2 of the NBA Finals (circled in blue). Now check out the all-important game boxed in red in the plot below.

Again, let me remind you that this last game was not used in the model-fitting process; rather, we applied the model to the first 3 quarters of play to predict the final game outcome (win/loss) and final game margin (points differential).  

Here’s the best part: ProSensus predicted that the Raptors would win Game 6 of the NBA Finals by 2, when in fact they took the championship title by 4.  How do you like those odds?

Congrats Toronto Raptors! We the North. We Predicted the Champs.

Final Game Margin - Observed vs Predicted

About the Author: Kristin Wallace

Kristin Wallace, MASc
Project / Sales Engineer
Kristin has a Bachelor’s Degree in Chemical Engineering and a Master’s Degree in Applied Science (optimization focus) from McMaster University. She has worked on projects in rapid product development and troubleshooting and plays a key role in writing technical proposals. Prior to working at ProSensus, she spent 5 years working at Hatch designing and troubleshooting non-ferrous electric arc furnaces.