A Monte Carlo Investigation of Baseball Decision Making

Greg Chanan

2/13/01

Abstract

For over a hundred years baseball strategists and diehard baseball fans have argued over batting order strategy. The traditional batting order (with the player with the best on-base percentage first, the best power hitter fourth, etc.), has been used almost as long as baseball has been around. With baseball contracts for superstars exploding at an exponential rate, some have questioned how much difference one player can make to an entire baseball team. The purpose of this experiment is to discover what the best batting order is, using a Monte Carlo simulation of a baseball game. By playing the members of the Anaheim Angels against each other in different batting orders for 1,000 simulated seasons with a program I wrote to simulate baseball games, I found that the traditional batting order is not optimal, but rather, the best batting order is the best batter first, followed by the rest in decreasing order of their slugging percentages. Far too much time and energy is put into managing and juggling batting orders, as changing it only yields, on average, only an extra ½ game won each year. By substituting a superstar like Manny Ramirez for an average player, I found that one player can make an enormous difference, up to nine extra wins per season, far more than by can be gained by shuffling the batting order. Run scoring is mainly a factor of the players on a team, not the order in which those players are placed.

Table of Contents

Section Page #

Introduction

Background Research..…………………………………………..4-6

Rationale...……………………………………………………….7

Hypotheses……………….………………………………………8

Variables…………………………………………………………9

Materials and Procedures

Materials…………………………………………………………10

Procedure..……………………………………………………….11-13

Data and Discussion/Analysis

Data………………………………………………………………14-15

Discussion/Analysis…………………………………...…………...16-20

Conclusion……………………………………………………………..….21-22

Introduction

Background Research

The Monte Carlo method provides an approximate solution to problems that can either not be solved mathematically, or are much easier to solve by using random numbers than by deriving a formula. A Monte Carlo simulation is simply a way of using random numbers and probability statistics to investigate problems. People have used Monte Carlo-like simulations for centuries, but the first use as a research tool stems from the work on the atomic bomb during the Second World War – to simulate the problems concerned with random neutron diffusion. The name was coined at this time because of the similarity of statistical simulations to games of chance, and because Monte Carlo, the capital of Monaco, was a center for gambling. Today, however, Monte Carlo simulations are used to simulate everything from radiation transport in the earth's atmosphere to a simple "Bingo" game. With the proliferation of low-priced, high-performance computers, Monte Carlo has become even more popular as a means of estimating one's retirement worth, based on certain random variables. Monte Carlo simulations are invaluable in many fields, and can easily be used to simulate baseball games, as in this experiment.

In Philip Roth's (1973) The Great American Novel, a story about professional baseball in the 1940s, an owner's son rambles on about how baseball teams play the game incorrectly, choosing to play based on past assumptions rather than proven statistics and probability. He goes on to suggest that the best batting order would be a team's most productive hitter first, followed by the remaining men in the descending order of their batting averages. This idea was actually borrowed from Earnshaw Cook's book, (1966) Percentage Baseball. The reasoning behind this idea is that a manager wants his best players at the plate as often as possible. Since there is equal probability that any one of nine players becomes the last man out, each player will become the last out approximately 18 times in a 162 game season [(1/9)*162 = 18]. Each player preceding the last player out a game must also have been up to bat, so for each positive increment in the batting order, a player can expect to appear at the plate 18 more times during the course of a season. Thus, the 8th player in a batting order can expect to have 18 more at bats than the last; the 7th 36 more; all the way up to the first player, who can expect to have 144 more plate appearances over the course of a season than the last player.

Cook also argues against using the conventional leadoff man (traditionally, a fast player with an experienced eye for the strike zone, in order to get walks), since a more productive batter -- one with a higher batting average -- will be afforded more opportunities by being placed first. For example, in a nine-game series, there will be 81 leadoff opportunities (innings), of which nine must be begun by the leadoff man. Since each player has a 1/9th chance of batting last (shown above), the player after him must bat first, and thus, has a 1/9th chance of leading off any inning. The remaining 72 innings (81 – 9 for the leadoff man), are split among the remaining players such that (1/9)(72) = 8. Therefore, in a nine game series the lead-off man can expect to start an inning 17 times, while all other players can expect to lead off only 8 times. If this is expanded to a 162-game seasons, the lead-off man can expect to lead off (17 *18) or 306 innings, the rest only (8 * 18) or 144 times. Thus the first player in the batting order leads off over twice as often (306 / 144 = 2.124), and as Cook states, "[…] the importance of anyone other than the most productive batsman doing so may be overemphasized" (pg. 215).

Today many major league baseball teams are willing to invest exorbitant amounts of money on one superstar athlete. Just this off-season, Alex Rodriguez signed a $252 million dollar contract, while Manny Ramirez and Derek Jeter signed contracts upwards of $180 million. These teams are willing to bet that one player will make a significant impact on the entire team, even though concrete details are not available for the effect of one player. Earnshaw Cook, in Percentage Baseball writes, "High scoring teams necessarily have more high-producing players. Manipulation of the equations (see above), shows that Bragan's [the manager who originally devised the batting order with players in decreasing order of their batting averages] batting order yields proportionally greater increments of runs scored as the number of high-index players in the lineup increases" (pg. 217), which suggests that the addition of one or two superstars to a team can make an exceptional difference in a teams performance, especially with the non-traditional batting orders suggested above.

Rationale

For over a century, baseball managers and serious fans have debated the effectiveness of various batting orders. Before the proliferation of low-priced, high-performance computers, however, these arguments were limited to speculation and trial and error. With today's high speed computers, millions of baseball games can be simulated in seconds using Monte Carlo methods, allowing the opportunity to test different batting orders quickly and accurately. This experiment attempts to answer, at least for the 1999-2000 Anaheim Angels, what the best batting order is, and possibly, to prove that by changing the batting order slightly, the Angels could add extra runs and wins over the course of the season. Additionally, with contracts for superstar baseball players skyrocketing, some have questioned how much difference one player can make on a whole team. This experiment will also attempt to answer how much difference a superstar like Manny Ramirez can make to a team.

Hypothesis

I predict that using a batting order that places the players in decreasing order of their batting averages, rather than the traditional order, will increase the Angel's total runs, and thus wins, by a small amount over the course of the season. I predict this because the more batting attempts the better players on a team have, the more scoring opportunities the team has. As shown in the background research, each move up in the lineup by one position affords 18 extra plate appearances per year, so if the better players –i.e. the ones traditionally in batting positions three to five -- are closer to the front of the lineup, they will have more plate appearances, and thus, more scoring opportunities for the team. I predict this will only change the runs and wins by a small amount. Previous mathematical tests with more limited statistics showed the batting order with players in decreasing order of their batting averages added only 11 extra runs per season. This could, at most, add up to 11 extra wins, but realistically would only cause an extra one or two wins per season, since only a small percentage of games are decided by one run.

I also predict that an addition of one exceptional player, like Manny Ramirez, will impact the total runs and wins to a greater degree than manipulating the batting order. I predict this because a manipulation of the batting order is limited by the personnel; you can try literally thousands of different lineups, but in the end, the players, and thus, statistics and potential are the same.

Consistent with my hypothesis about manipulating the batting orders, I predict that having an exceptional athlete and using a batting order that places the players in decreasing order of their batting averages will add an additional 1 or 2 wins a season over a batting order with the exceptional athlete in a conventional batting order.

Variables

Independent Variable: batting order.

Dependent Variables: runs and wins per season.

Controlled Variables: players' statistics, number of games played.

Additionally, the Manny Ramirez test also has an independent variable of players, since he and Scott Spiezio are switched.

Materials and Procedures

Materials

1. A computer (500 MHz Pentium 3, 128 MB SDRAM, Windows 98SE).

2. A C++ Compiler to compile the program.

3. Mersenne Twister: A 623-Dimensionally Equidistributed Uniform Pseudo-Random Number Generator," by Makoto Matsumoto and Takuji Nishimura. (Provides better random numbers for the Monte Carlo simulation.)

4. Batting Statistics for the Angels 2000-2001 season. (See Data section for complete statistics.)

Procedure

1. Write a baseball simulation program, capable of running 1000 seasons at a time and using player statistics from the 2000-2001 season, in order to run the tests.

1. Run the program, (b2.exe) ten times, for 1000 seasons each time, for each different batting order. The batting orders are:

1) Darrin Erstad 2) Tim Salmon 3) Garret Anderson 4) Troy Glaus

5) Ben Molina 6) Mo Vaughn 7) Adam Kennedy 8) Scott Spiezio

9) Benji Gil

A) The batting average in decreasing order: (123456789). This batting order was the one suggested in Percentage Baseball, due to the fact that the best players get up to the plate the most (See Background Research).

B) The batting order chosen by the Angels early in the season (176234859). This is to compare the batting order the angels chose early in the season to late in the season, to see if any improvement was made.

C) Decreasing batting order, but with Tim Salmon first, rather than Darrin Erstad: (213456789). This is to test how much the first player in the batting order truly matters (see Background Research).

D) Decreasing batting order, but with Troy Glaus rather than Darrin Erstad: (413256789). This is to test how much the first player in the batting order truly matters.

E) Decreasing on-base percentage: (124685937). Same idea as #1, except uses on-base percentage, because on-base percentage takes into account extra factors like walks.

F) Power-hitter 3rd rather than 4th: (124356789). This is the same as #1, but Troy Glaus, the Angel's best power hitter is placed 3rd rather than 4th to see if power is sometimes more important than average.

G) Leadoff, then decreasing slugging percentage: (142368579). The concept here is the same as #1, except slugging percentage is used to rate the players since the Angel's are such a prolific power-hitting team.

H) Leadoff, then decreasing order of home runs: (146328579). Same idea as #7, except home runs are used to test power rather than slugging percentage.

I) Increasing batting order: (987654321). This is used to see how much difference a terrible batting order would make on the team, to see if batting orders really make a significant impact.

All of these are compared with the Angels chosen batting order late in the season (J) (186234579) to see if any of these are better than the order the Angels actually chose.

2. The results of each test (total runs, total wins, average extra runs per season, and average extra wins per season) are output in a text file by the program. The results of the ten trials are averaged together and put in a table for comparison purposes.

3. Standard Deviation of runs is calculated for all of the batting orders, using the formula:

where <R^2> is the average of the squares of the runs per game and <R>^2 is the square of the average runs per game. The standard deviation represents the fluctuations from trial to trial. The uncertainty in the final averages is the error on the mean. The error on the mean is the standard deviation divided by the square root of N-1 where N is the number of trials. In my case, each trial was made up of 10,000 seasons.

4. The batting orders are then compared by runs per game and wins per season to determine which is best. The error on the mean is used to determine whether or not differences are significant.

5. To test how much difference one player can make on an entire team, switch Manny Ramirez in the lineup for Scott Spiezio, since both are Designated Hitters, and can be easily swapped. Follow the same procedure as above (1-2), but use the following batting orders in step two:

1) Darrin Erstad 2) Tim Salmon 3) Garret Anderson 4) Troy Glaus

5) Ben Molina 6) Mo Vaughn 7) Adam Kennedy 8) Scott Spiezio

9) Benji Gil 0) Manny Ramirez

Ar) The batting average in decreasing order: (102345679). This batting order was the one suggested in Percentage Baseball, due to the fact that the best players get up to the plate the most (See Background Research). This corresponds to order A in the above batting orders.

Gr) Leadoff, then decreasing slugging percentage: (104236579). The concept here is the same as #1, except slugging percentage is used to rate the players since the Angel's are such a prolific power-hitting team, and even more so with Manny Ramirez. This corresponds to order G in the above batting orders.

Jr) The same batting order the Angel's chose, except with Manny Ramirez switched for Scott Speizio (106234579). This corresponds to order J in the above batting orders.

6. These batting orders are compared by runs per game and wins per season to the corresponding batting order without Manny Ramirez, to see how much difference one player can make. Standard deviation and error on the mean are calculated and recorded the same way as in steps 3 and 4.Data and Discussion/Analysis

Data

Results for Ten Different Batting Orders

Batting Order Name Runs Per Game Wins Per Season Batting Order

A 6.4531 ± 0.0032 81.105 ± 0.073 123456789

B 6.4037 ± 0.0034 80.566 ± 0.060 176234859

C 6.4511 ± 0.0020 81.077 ± 0.035 213456789

D 6.4475 ± 0.0037 81.117 ± 0.055 413256789

E 6.4775 ± 0.0015 81.430 ± 0.123 124685937

F 6.4791 ± 0.0033 81.419 ± 0.074 124356789

G 6.4881 ± 0.0035 81.569 ± 0.874 142368579

H 6.4668 ± 0.0035 81.200 ± 0.078 146328579

I 6.3074 ± 0.0028 79.294 ± 0.088 987654321

J 6.4457 ± 0.0025 81.007 ± 0.052 186234579

Results for Batting Orders w/ & w/o Manny Ramirez

Batting Order Name Runs Per Game Wins Per Season Batting Order

Ar 7.1595 ± 0.0028 89.534 ± 0.058 102345679

Gr 7.2046 ± 0.0026 90.085 ± 0.066 104236579

Jr 7.1551 ± 0.0029 89.462 ± 0.052 106234579

A 6.4531 ± 0.0032 81.105 ± 0.073 123456789

G 6.4881 ± 0.0035 81.569 ± 0.874 142368579

J 6.4457 ± 0.0025 81.007 ± 0.052 186234579

Graphs

NOT AVAILABLE IN ABIWORD VERSION

Discussion/Analysis

My hypothesis was partially validated and partially invalidated. The batting order with batting average in decreasing order (A), did do better than the actual one the Angel's chose. It scored an average of 6.4531 ± 0.0032 runs compared to 6.4457 ± 0.0025 runs for the lineup the Angels chose. It also won 81.105 ± 0.073 games per season compared to 81.007 ± 0.052 wins per season. This difference in wins per season was very small and barely statistically significant.

However, batting order A wasn't the most successful, as I had expected. Batting order G, with Darrin Erstad first, then the rest of the players placed in decreasing order of their slugging percentages turned out to be the best. It scored an average of 6.4881 ± 0.0035 runs per game and won an average of 81.569 ± 0.087 games per season, compared to 6.4457 ± 0.0025 runs per game and 81.007 ± 0.052 wins per season for the lineup the Angels actually chose. This is most likely a quirk of the Angel's lineup: they have an unusually powerful lineup, and thus, a batting order where the more powerful hitters are up as often as possible would be beneficial. The difference between the best batting order and the batting order the Angels actually chose was so minimal (only slightly over ½ an extra game won per season), that using this lineup would not have changed the Angels final standings at all: they still would have ended up 8 or 9 games out of first place in the AL West. Of course, the fact cannot be ignored that I have proved mathematically and statistically that different batting orders ARE better than the ones the major league teams currently employ, and should be used. It does suggest, however, that too much effort is made juggling lineups, trying to find the best one, since it makes so little difference in the end. The differences in teams scoring runs are due to personnel, not order, as shown by the Manny Ramirez experiment below. Further evidence that the lineup does not make much difference at all is the fact that a ridiculous lineup (I), with the lowest average hitters first and the highest average hitters last, still managed to score 6.3074 ± 0.0028 -- a difference of only about 0.17 runs per game compared to the best batting order, G. Mr. Cook's prediction (see Background Research) that the best batting order would be the players in decreasing order of their batting averages (A), was probably correct when the book was written in 1966, but with players getting more powerful every year, it seems power is more important than batting average.

The results are quite accurate as well. When the lineup the Angel's chose played itself, they should have theoretically won 162/2 = 81 games per season, since neither team has an advantage. The average wins per game came out to 81.0069 ± 0.0520, or within one standard deviation of what it should be. There is one problem, however; the actual Angels only scored 5.3333 runs per game, while the batting order in the simulation that is the same as the Angel's scored 6.4457 ± 0.0025 runs per game. There are many things that could have caused this:

1) The lineups earlier in the season, as shown by batting order B, were less successful than the ones used late in the season, and thus, could bring down the average runs per game.

2) Managers have the advantage on defense; they can change pitchers for match-up purposes (to have a pitcher that the batter has done historically poorly against), much more easily than a manager on offense. These were not factored into the simulation.

3) The player's statistics in the simulation were higher than they actually were in reality; only at bats and walks were counted for total plate appearances, not very rare occurrences like reaching on errors, which means the simulated player's total plate appearances were lower than they were in actuality. Because of this, the chance that a given outcome occurred (e.g. single), was divided by a smaller number than it should have, making the statistics inflated for all players.

4) Double plays occurred about 1.135 times per game for the Angels. These were not factored into the simulation. Keep in mind that these limitations do not actually affect the validity of the experiment; both teams are under the same conditions, and thus, are both affected by these limitations the same way. So, when one batting order produces better results than the ones the Angel's chose, it still would do so in actual baseball; it has no advantage due to limitations of the simulation. I went back and added in double plays, occurring at the same frequency as in the actual game, and repeated the tests. Runs went down to 6.1296 ± 0.0019 runs per game, which is a difference of about 1/3 of a run per game, or about 1/3 of the difference between the runs per game in the simulation and the actual runs per game.

5) The teams played more innings that they would have in a real baseball game. In a real baseball game, if the home team is winning when they are up in the 9th inning, they don't play the last half of the 9th inning, since they will win no matter what. The simulation completed the game, however, so that the runs per game could be measured on the same scale between the home and visiting teams.

6) Because the teams have the same players, they will often go past the usual nine innings to decide the outcome of a game. This increases the runs per game because there are more opportunities to score. I did a quick retest and found that with double plays, the average runs per nine innings was around 5.43 -- or very close to the 5.33 they actually scored during the season, while the average number of innings per game for the simulation was around 10.17. This proves that they do play a lot of extra inning games due to the fact the teams are so closely matched.

For the Manny Ramirez test, one player made a huge difference -- far more than I had predicted. For the batting order with players in decreasing order of their slugging percentages (Gr against G), Gr scored 7.2046 ± 0.0026 runs per game, compared to only 6.4881 ± 0.0035 runs per game for the same batting order with Scott Spiezio instead of Manny Ramirez. This is a difference of 0.7165 runs per game, which multiplied over the whole season, comes out to 116 extra runs! Gr also won 90.085 ± 0.066 games per season against the actual Angel's lineup, a jump of 8 wins from the 82 games they actually won in the 2000-2001 season. This is enough to move them from third to first in the American League West, since the leaders of the division, The Oakland Athletics and Seattle Mariners both won 91 games, but those extra eight games have to be subtracted from the other teams in the league. More than likely, one or two of these games would be subtracted from the Mariners or Athletics, enough to move the Angels into first place and into the playoffs.

The other batting orders with Manny Ramirez stayed fairly consistent with the other tests, with the order with decreasing slugging percentage (Gr) being the best, followed by the one with decreasing batting average (Ar), followed by the one the Angels actually chose (Jr), exactly the same order that G, A, and J finished without Manny Ramirez. Batting order Ar scored 7.1595 ± 0.0028 runs per game, or an extra 0.7064 runs per game compared to batting order A. It also won 89.534 ± 0.058 games per season, or 7½ more than the Angels actually won. Batting order Jr scored 7.1551 ± 0.0029 runs per game, an increase of 0.7094 runs per game. Jr also won 89.462 ± .0.052 games per season, 7½ more than what the Angels won (82). As in the tests without Manny Ramirez, the batting order made a miniscule difference when comparing runs per game and wins per season, proving that the differences in team scoring are due mostly to personnel, and are only slightly affected by batting order.

Conclusion

My hypothesis was partially validated and partially invalidated. Batting order G, with Darrin Erstad first, then the rest of the players placed in decreasing order of their slugging percentages turned out to be the best of the ten batting orders. It scored an average of 6.4881 ± 0.0035 runs per game and won an average of 81.569 ± 0.087 games per season, more than the 6.4457 ± 0.0025 runs per game and 81.007 ± 0.052 wins per season for the lineup the Angels actually chose. This probably occurred because the Angels have such a strong power hitting lineup, and thus, a lineup where the more powerful hitters are up as often as possible would be the most beneficial. The difference between the best batting order tested and the batting order the Angels actually chose was so minimal (only slightly over ½ an extra game won per season), that using this lineup would not have changed the Angels final standings. Of course, the fact cannot be ignored that different batting orders ARE better than the ones the major league teams currently employ, and should be used. It does suggest, however, that too much effort is made trying to find the best lineup, since it makes so little difference in the end. The differences in teams scoring runs are due to differences in personnel, not the order in which those personnel are placed.

I also found that one player can make a huge difference. When Manny Ramirez was substituted for Scott Spiezio in three different lineups, the runs per game went up by about 0.7108, or 115 extra runs over a 162 game season. This was enough for the Angels to win 90 games per season, or enough to move them from 3rd to 1st in the American League West and into the playoffs. Batting order Gr (with players in decreasing order of their slugging percentage), was the best out of the three tested with Manny Ramirez, scoring 7.2046 ± 0.0026 runs per game and winning 90.085 games per season. Batting order Ar, with players in decreasing order of their average, scored 7.1595 ± 0.0028 and won 89.534 ± 0.058 games per season. Bating order Jr, the same as the Angel's actual lineup, but with Manny Ramirez swapped for Scott Spiezio, scored 7.1551 ± 0.0029 runs per game and won 89.462 ± 0.052 games per season. These batting orders finished in the same order as they did without Manny Ramirez, and, like the other test, didn't affect the results much. Manny Ramirez, on the other hand, made a huge difference, further proof that differences in runs scored are due mostly to different players, not the order in which those players bat.

This experiment can easily be extended. The most immediate thing to test is the run discrepancy discussed in the Discussion/Analysis section. The program can easily be modified to be more like major league baseball: include double plays, sacrifices, hit and runs, errors, pinch hitters, different pitchers, etc. It would also be able to test the hypothesis that offensive managerial decisions like pinch-hitting are detrimental to the team. Also, since the framework of the baseball game is already written, modifying it to test something else about baseball is a trivial task. For example, in Percentage Baseball (see Background Research), the author also suggests that sacrifices should never be used, that hit-and-runs are far superior. The program could have a team that sacrifices 100% of the time (with less than two outs) against a team that does a hit-and-run 100% of the time. The percentages could then be modified to find the most advantageous percentage of sacrifices to hit-and-runs to use during a game. Also, almost everything about baseball could be tested, like when to steal, best batting order, sacrificing vs. hit and runs, pinch hitters, etc., until a formula for playing true "percentage" baseball could be devised.