In an anticipated rebuilding year for Major League Baseball’s Detroit Tigers, this analysis seeks to compare win probability as a function of runs scored, then runs allowed, with one of the top teams in MLB’s 2018 season, the Boston Red Sox. Information was gathered slightly before the midway point of the 2018 season at 70 games for each team.
Since runs are necessary for wins, maybe they are the best predictor for victory. Disregarding the probabilities that the following plots ascribe to winning without scoring a run or losing without allowing a run, we see a practical generalized linear model of the binomial family that indicates that the Tigers need plenty of runs to win games. Wins are scored with a value of 1, losses a value of 0. The darkness of shaded points is a product of increased frequency.
win_loss <- c(0,0,0,1,0,1,1,1,0,0,0,0,0,1,1,1,1,0,1,0,1,0,0,0,1,0,0,1,1,0,0,1,0,0,1,0,1,0,1,1,1,0,1,0,0,0,0,0,1,1,0,1,1,0,1,1,1,1,0,0,1,0,0,1,0,1,0,0,1,1)
runs_for <- c(10, 0, 6,6,0,9,6,1,0,1,1,3,6,4,6,13,3,2,12,5,13,3,0,0,9,3,2,2,3,6,2,3,2,6,7,4,4,5,5,6,9,0,3,4,2,2,2,0,4,5,4,3,9,2,6,6,5,7,4,4,4,0,1,7,1,4,2,4,5,3)
Tigers_win <- glm(win_loss ~ runs_for, binomial)
runs_weight <- seq(0, 14, 0.01)
wins_weight <- predict(Tigers_win, list(runs_for = runs_weight),type="response")
plot(runs_for, win_loss, pch = 16, col=rgb(red=0.2, green=0.2, blue=1.0, alpha=0.5), xlab = "Runs Scored", ylab = "Win Probability")
lines(runs_weight, wins_weight, lwd = 4)
Even with four runs, the Tigers have less than a 47% chance of winning.
“Defense wins championships.” - Paul “Bear” Bryant
Since low opponents’ scores would intuitively make winning more likely, perhaps the runs the Tigers allow are the best predictor for victory.
runs_against <- c(13,1,8,1,1,7,1,0,2,2,5,9,8,2,5,8,2,3,4,8,10,8,1,6,5,5,3,1,2,10,4,2,4,7,4,5,3,9,4,3,8,6,2,5,7,3,4,6,1,4,8,2,3,9,1,2,2,4,8,7,2,6,7,2,4,2,9,6,2,1)
Tigers_win2 <- glm(win_loss ~ runs_against, binomial)
wins_weight2 <- predict(Tigers_win2, list(runs_against = runs_weight),type="response")
plot(runs_against, win_loss, pch = 16, col=rgb(red=0.2, green=0.2, blue=1.0, alpha=0.5), xlab = "Runs Allowed", ylab = "Win Probability")
lines(runs_weight, wins_weight2, lwd = 4)
For the sake of comparison, we introduce the statistics compiled by the Boston Red Sox, who amassed a record of 48 wins and 22 losses to the Tigers 33-37. Let us overlay the models generated for the Tigers on the Red Sox data with the Tigers in blue and the Red Sox in red.
bosox_win_loss <- c(0,1,1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1,0,0,0,1,1,0,0,1,1,0,1,0,1,1,1,0,0,1,0,1,1,0,0,1,1,0,1,1,1,1,0,1,1,0,1,1,1,0,0,1,1,1,1,0,0,1,0,1,1,1,1)
bosox_runs_for <- c(4,1,3,2,7,4,3,10,8,14,7,6,7,10,3,10,9,8,7,0,1,3,4,5,3,6,4,10,6,5,5,5,6,6,2,6,5,3,5,5,5,3,6,6,4,6,5,4,4,3,6,8,1,8,8,6,2,3,5,9,6,7,2,0,4,2,2,6,5,2)
bosox_win <- glm(bosox_win_loss ~ bosox_runs_for, binomial)
runs_weight2 <- seq(0, 15, 0.01)
wins_weight3 <- predict(bosox_win, list(bosox_runs_for = runs_weight2),type="response")
plot(bosox_runs_for, bosox_win_loss, pch = 16, col=rgb(red=0.2, green=0.2, blue=1.0, alpha=0.5), xlab = "Runs Scored", ylab = "Win Probability")
lines(runs_weight2, wins_weight3, lwd = 4, col = "red")
lines(runs_weight, wins_weight, lwd = 4, col = "blue")
Clearly, the Red Sox have a greater win probability than the Tigers at each value of runs scored. For comparison, when the Red Sox score four runs, they have an almost 63% chance of winning.
bosox_runs_against <- c(6,0,2,1,3,2,2,3,7,1,10,3,3,3,1,1,0,2,3,3,4,4,3,4,4,12,3,6,7,4,11,1,5,1,3,9,4,5,2,3,6,5,4,2,7,3,0,2,1,6,2,6,7,3,3,4,4,7,4,3,0,1,7,1,2,5,0,4,1,1)
bosox_win2 <- glm(bosox_win_loss ~ bosox_runs_against, binomial)
wins_weight4 <- predict(bosox_win2, list(bosox_runs_against = runs_weight2),type="response")
plot(bosox_runs_against, bosox_win_loss, pch = 16, col=rgb(red=0.2, green=0.2, blue=1.0, alpha=0.5), xlab = "Runs Allowed", ylab = "Win Probability")
lines(runs_weight2, wins_weight4, lwd = 4, col="red")
lines(runs_weight, wins_weight2, lwd = 4, col = "blue")
Though the Red Sox hold the advantage almost across the board in this analysis, surprisingly, the Tigers are more likely to win than the Red Sox when allowing six or more runs.