# On the Randomness, or Lack Thereof, of a Baseball Linescore

Last night, the Texas Rangers beat the Baltimore Orioles by a score of 30 to 3. In a baseball game. The last major league baseball team to score 30 or more runs in a game was the Chicago Colts, in 1897.

If you had to guess when the Rangers scored their runs over 9 innings (the game was in Baltimore, so Texas batted in the top of the 9th), how would you distribute the runs? If I had to do it, my linescore would probably look about like this:

1 2 3 4 5 6 7 8 9

4 3 1 0 5 6 3 5 3

But here is the actual linescore:

1 2 3 4 5 6 7 8 9

0 0 0 5 0 9 0 10 6

The Rangers scored 30 runs in just 4 innings! It’s a good reminder, once again, that the way data plays out in real life is often nowhere near as orderly, predictable, or consistent as you might imagine it to be. Even though runs scored per inning isn’t quite a matter of random distribution, this linescore did call to mind the common exercise of predicting coin flips. Levitt wrote about this topic a while ago: if you ask most people to predict how a sequence of 100 coin flips would come out, they would rarely have long streaks of heads or tails. Their answer, in other words, would end up just as fake as my imagined linescore above.

## ryan

Finaly something us Ranger fans can cheer about. Now when does the Maverick's season start???

## Tyler

I actually would have guessed something close to the actual linescore. Baseball has a tendency to score in bursts, not in an even distribution.

The amount of runs scored in any given inning has a lot to do with the opposing team's pitcher, and where in the batting order each inning begins and ends.

A particular late relief pitcher could be having a bad day and give up four or more runs before being pulled and replaced by someone else, who may or may not be a 'better' pitcher (or may not be fully warmed up!) As for the batting order, if your top of the order hitters are great, and your bottom-order hitters are of less quality, you're more likely to score when your 'good' hitters are up immediately at the start of a new inning. Also, the weaker hitters may have an easier time batting another player around (by sac fly, etc) than getting a multi-base hit themselves.

Looks like a lot of these (and probably other) factors lined up in the 4, 6, 8, and 9 innings. It was also a double header, so the Baltimore manager may have been trying to get every pitch out of his bullpen.

## TWstroud

A disappointing column. The nature of baseball encourages the clustering of runs. There are casual factors at play. Pitcher fatigue. The impact of full queues (loaded bases). Batting order. It is not the proper setting for a lesson on random numbers.

## Richard Simon

This is less surprising than you might think. A number of studies have shown that not only do runs most-often score in clumps (i.e. more than one run per inning) but that the winning team most-often scores more runs in one inning than its opponent scores in the whole game!

In this case, the Rangers simply took this to the extreme.

## Bill Effros

Computers have random number generators used to approximate randomness. They don't work very well, and never have. That's why the iPod plays the same songs over and over, and never plays others.

But it does demonstrate the difficulty of simulating or predicting randomness.

If you program an iPod to generate baseball linescores, it will probably never generate one like the one last night.

## James

Aside from the normal factors in clustering of runs, one has to figure that the Baltimore manager essentially gave up in the 6th inning. Winning the game was extremely unlikely, and he was not going to use a limited resource (quality pitching) to support an almost-certain losing cause.

I would expect there was also reduced effort on defense by the fielders -- would you risk injury in a game you're going to lose?

## josh

The other interesting baseball related fact about the game is that about half of those 30 runs came from the 7,8 and 9 hitters; typically the least productive batters in the lineup.

## jonathan

I think the box score is more interesting . . . because Steve looks at the 30 and imagines that overly large number must be broken up because the odds of scoring 9 runs and 10 runs is very low, while others look at a regular box score, notice that it clumps and then enlarge those clumps to get to 30. The two perspectives that normally go together don't. If you look at the box score, the Baltimore manager kept his pitchers in to take a beating. Why? Perhaps the answer is twofold: that this was the first game of a doubleheader, so he couldn't burn out all his pitchers in this game, and that he was that day named the manager for next year and he knew he has job security despite a truly embarrassing loss.

## Harvey Wachtel

I assume there is some statistical metric for deviation from equal distribution. Has anyone calculated it for some large set of major league baseball games? Is it comparable to the value in, say, class-A ball? Is it different for teams with different styles of play? There's some unexplored stuff here.

## Jon

I just can't believe they did it without a single hundred-yard rusher or hundred-yard receiver.

## Mack

@5 --

Computers (99%) don't have random number generators, but programming languages often have pseudo-random number generators in their libraries. Some native PRNGs aren't very good, but many, especially those from third parties, are excellent.

I'm sure the iPod cheaped out, but that shouldn't be an indictment of all or even most PRNGs.

And ditto to the notion that baseball stats aren't at all about randomness.

## Mario Ruiz

Hi Stephen,

Great Posting. I like this kind of recalls. Because it reminds us that not only the score in baseball come random, but also the events in life does not come in the sequence we hoped.

For example, The Financial Times today reports on a planned social network for the U.S. intelligence community in an effort to transform the analytical point of view to the more humanistic (random approach).

Beyond the point of changing the type of analysis the CIA makes, I was surprised to reveal they recently used Facebook to help boost applications for the national clandestine service.

I know what are they doing promoting like a teenager their new site.

Mario Ruiz

@ http://www.oursheet.com

## Isabel

I thought the same thing, and did some computation. My conclusion was that under certain "reasonable" assumptions about how runs score -- that the scoring in each inning is independent and that the distribution of runs in innings is chosen from the distribution for the actual 2005 AL -- scoring thirty runs in just four innings is actually quite rare. The most typical way to score 30 is to score in seven of the nine innings.

But this required assuming that a 30-run game is in some ways like a "typical" game, which it certainly is not.

## Paul

Suppose we try to construct all possible combinations of 9-inning scores that produce 30 runs. Start by dividing the runs evenly. This produces permutations of 3-3-3-3-3-3-3-3-6, or perhaps 4-4-4-3-3-3-3-3-3.

If you decide many runs were concentrated in one inning, which seems plausible, then you might get permutations of 9-3-3-3-3-3-3-3-0 and it will quickly become clear that anytime many runs are scored in a single inning there will be no runs scored in at least one other inning. Two large innings might produce permutations like 9-8-3-3-3-3-1-0-0 and three large innings might produce combinations like 9-8-5-3-3-1-0-0-0-0.

After deconstructing the universe of 9-inning games that produce 30 runs, it's then possible to answer questions like, "How many permutations produce no runs in X of 9 innings?" and "What is the probability of a 30 run game in which X innings produce no runs?"

You haven't really convinced anyone that the Rangers score is a rare distribution, you've only convinced us that most people, including yourself, don't waste time enumerating the sample space of 30 run games, and so you "guess" that a sample with 5 scoreless innings is unusual based on observing yourself as a single data point.

Respectfully, this is not analysis.

My deconstructions embed the assumptions that the 30 runs are distributed randomly among the 9 innings.

Real "freakonomics" might look at the actual history of high-scoring games and compare the empirical data vs expected simulated data. If high-scoring games contains many more big innings than would be expected from the mathematical sample space, that would indeed be interesting.

My own personal hunch is that they do. Most games in which one team scores more than, say, 15 runs has a "big inning." If this is true then the more interesting question is, "Why?" I think the answer is obvious. Baseball managers don't seek to maintain a bad status quo. If your pitcher gets into trouble, you bring in a new one, and you usually bring in one who optimizes the chance of getting the next hitter out. This process usually works, or at least it increases the probability of getting the next hitter out, and so the assumption of distributing runs evenly in any inning is wrong. Hence there really aren't as many big innings in actual baseball as would be expected in modeled baseball.

Put differently, whenever there *are* really high scoring games, it may be because the managerial strategy fails. Hence high-scoring games are historically rarer than mathematical chance, and those that occur have a higher-than-usual chance of having a big inning precisely because the managerial strategy fails.

I did perform similar analysis by simulating .300 and .400 hitters using a coin toss to see how many games (4-toss events) would produce hitting streaks. To my surprise, though the 56-game streak by DiMaggio is rare (for a .356 hitter), there are more longer historical streaks (30 and 40 games) than we would expect if .300 and .400 hitters distributed their hits randomly over games in a 162-game season. In other words 40-game hitting streaks actually occur with more frequency than one would expect from a random model that correctly simulates hitters with certain batting averages over a season.

## David R.

It is interesting to me that Stephen looked at the linescore. I noticed the distribution of hits, runs and rbis by batter. Of the three columns, the only zeros were for RBIs (Nelson Cruz, Michael Young). RBIs ranged up to 7.

Excluding T. Metcalf, 1 hit in 1 ab, hits ranged from 2-5. Excluding Michael Young, 1 run scored before being removed from the game, everyone scored 2,3,4 or 5 runs. Everyone had a hit. Everyone had a run. Amazing.

## Howard

I, too, would think runs would be distributed evenly across innings. However, at some point, the number of total runs will probably lend itself to the "big inning theory" posited by a few of the posters. Reasons? (1) A manager leaves in a tired reliever in order to save his bullpen. (2) A manager uses a position player to pitch in order to save his bullpen. Think Canseco or Mattingly tossing knuckleballs. (3) The "runs come in bursts" theory put forth by #2 and #4.

Perhaps you could test the Big Inning Theory by looking at games in which a team has scored, say, 15 or more runs in a game. In that case, I would hypothesize that at least half of all runs were scored in 3 or less innings as opposed to the evenly-distribted 4-plus innings. Can you test this? I wonder if it would be statistically significant.

PS: The statement by #4 that "the winning team most-often scores more runs in one inning than its opponent scores in the whole game" is a ridiculous statement. Evidence, please.

## PeeDub

#5,

People shouldn't want a real random number generator to be responsible for music shuffling, otherwise you *will* get repeats. The best music shufflers have some concept of history, such that a number (or song) being selected has the effect of making that number (or song) *less likely* in the future.

Again, the theme is that people really don't have a good, innate concept of what "random" is.

## Fred

Honestly? I would guess few, if any, runs in the first third of the game, a bunch in the middle, and some more in the final third.

First Third

The pitcher has an advantage at this point. Batters haven't seen him in a while and forget what his pitches look like. Plus, he hasn't shown any tendencies (like tipping a pitch or having a slow fastball or his curve not curving as much as normal) for this particular game. If I knew a team was going to score 30 runs in a game, I'd guess that they scored 5 of them in the first three innings, with most of then coming late in the second and mostly in the third. I'd take 0 1 4.

5 down, 25 to go.

Second Third

This is when the starting pitcher is vulnerable. It's why a starting pitcher can't get a win without going 5 innings. Given that the lineup has probably gone around twice at this point, we're probably pretty close to the heart of the order again. I'd guess they bat around in the 4th for 8 runs, then get stymied by a relief pitcher until the 6th, when they score another 8 runs due to the relief pitcher(s) having their inevitable bad game(s). Give me 8 0 8.

21 down, 9 to go.

Last Third

At this point, the entire pitching staff, including the bullpen, is having a nightmare of a night. I would guess that the way things played out had the heart of the order towards the end of the 6th inning. So, bring in a new pitcher and have the bottom part of the order score, not many, if any runs, in the 7th. Follow that by some more runs peppered in the 8th and 9th and give me 1 5 4.

So, I'd have a line score of:

0 1 4 8 0 8 1 5 4

Compared to the actual line score:

0 0 0 5 0 9 0 10 6

it's not all that different.

The natural tendency of outsiders is to think that runs in baseball are evenly distributed. The problem with that is that it assumes all batters and all pitchers are the same. There's a reason the bottom of the order is the bottom of the order. A team is trying to create big innings by clustering their good hitters so that they can get men on base and hit big hits to bring them home.

Further, there's a reason the far majority of relief pitchers have big ERAs. They're bound to get lit up every now and again and when they only pitch one inning and give up 5 runs, it kills their ERA and negates the other 8 innings they pitched across 8 games when they didn't give up a run.

In the end, the stars aligned and a lot of other factors came together last night, but one thing that was not unexpected, at least from a die-hard baseball fan's perspective, from a 30-3 score was the clustering of runs by inning.

## Victor

Scoring 30 runs in 4 innings is an anomaly. How many of you would guess two innings with 9 or more runs each? Yes, runs score in bursts in baseball, but generally the bursts cap out around 5-6 because the team either brings in new relievers or bottom of the order kills the rallies. Yes, sometimes they break that mark, but 9 and 10 in one game?

The biggest blowout in baseball history didn't even have 1 inning over 8 runs. It did have two with 7 and one with 8, though, and the Chicago Colts managed to score in every inning. Dubner's guess for this game is similar to what happened in that game. Other massive blowouts generally have 6 or more innings worth of scoring.

The double header, obviously, played a big factor here, like many people have mentioned. They couldn't afford to burn through too many relievers. Baltimore should have just had a position player pitch.

Anyway, the point I'm making is this: If you only looked at the score at the end of game, you wouldn't have put 30 runs into just 4 innings of play. Even considering the double header.

## Howard

#18

Your observations are in interesting... if baseball were played in a vacuum and you didn't have 20/20 hindsight to try and sound like. You fail to account for the fact that pitchers can have a really bad day from the get-go or tend to take an inning or two to get their mechanics together. There's a reason First-Inning-ERA has become a popular stat. Also, your theory fails to account for the fact that managers may not be motivated to replace a failing reliever during a blowout. At some point, you stop trying to "stop the bleeding" and just wait for the game to end.

Your assertation that only "outsiders" would tend to think that runs are evenly distributed feeds off your flawed theory. I know baseball. And I also know that your 1/2/3 and 7/8/9 batters do not hit indepedently of each other. In other words, your #1 hitter will probably bat in the same inning as your #8 hitter as many innings as your clean-up hitter will bat in the same frame as your #7 hitter. Over the course of a 162-game season, the scoring of runs will probably be evenly distributed.

Further, what is your definition of a "good hitter"? Merely batting average? If you think managers cluster good hitters, why does Joe Torre bat Robinson Cano eighth or ninth? Perhaps because he tries mixing strengths throughout the lineup - speed, power, high OBP, bunting ability, etc?