Thursday, October 4, 2012

Win Estimators, or Why Baseball and Football are Different

What would it take for you to believe that a Major League Baseball team went undefeated? I mean in terms of runs scored and allowed. Like, if those were the only two pieces of information you had, what would they need to be (or be like) for you to believe a season was undefeated?  I think, for me, it would take something pretty incredible - like allowing no runs for the entire season (or, like 10).  Because, even if a team scored like 4000 runs, but gave up 500... well, don't you think it's possible that they'd lose, I don't know... 2 or 3 games?  The basic Pythagorean formula (Runs squared over (runs squared plus runs allowed squared)) says a team like that would go 159.5-2.5 (I guessed two or three games before doing the calculation, by the way, so I'm pretty proud of that guess).  And that seems about right, doesn't it?  I mean, even with a run differential that big, you'd still expect to lose a game or two.  Which, in the scheme of a 162-game season, is nothing.  But the point is, the run differential it would take to believe in an undefeated baseball season is astronomical.  I mean, this hypothetical team, which averages a 25-3 game, could hypothetically lose 12-11 twice or thrice during the year, right?

But football is fundamentally different, because it takes place in a small sample size.  For example, if I told you a team scored 400 points on the season, and gave up only 50, well, you'd assume they went undefeated.  And you'd probably be right.  The pythagorean formula agrees with this one.  Because it predicts this team to go 15.75-.25... so yeah.  They'd probably go undefeated.

But what if we double their points allowed?  What if they scored 400, and gave up 100?  That's an average score of 25-10... but would they go undefeated?  The Pythagorean formula says they'd go 15-1.  My guess is, in an NFL where the average team scores 22 points/game (close to the historical average, and in fact just behind the average for 2011 of 22.2), that's  probably about right.  But, frankly, in a league where an average team scores 22 ppg, 400 points isn't that many (average team would score 352).  So we'd expect the offense to fail once in the season, even if the defense is tough.

Anyway, why are we talking about this?  I mean, who cares?

Well, I do.  Because here are some real numbers.  I'm going to list the team, their points scored/allowed, Pythag. record, and then actual record.  Here goes:
2007 Patriots - 589-274; 13.8-2.2; 16-0
1985 Bears - 456-198; 14.1-1.9; 15-1
1998 Vikings - 556-296; 13.1-2.9; 15-1
1972 Dolphins - 385-171; 12.2-1.8; 14-0
2008 Lions - 268-517; 2.8-13.2; 0-16
1976 Buccaneers - 125-412; .8-13.2; 0-14

What you see here is that it's basically impossible, by the Pythagorean formula, to ever expect an undefeated season in the NFL . . . or a winless one.  The reason is because of a quirk of the Pythagorean formula, in which the PSsq/(PSsq+PAsq) will only yield a 0 if the team scores no points, and will only yield 100 if the team allows no points.  But the truth is, teams do go undefeated.  So it makes no sense to use a quadratic equation when we know that football doesn't quite work that way.

So what do I suggest we do about this?  Well, it's a pretty easy solution, actually.  You go linear.  And how does one do that?  Like so:
Use the information we already have.
Figure out the number of points/game.
That's all you need.
Take the team's points differential.  Divide by 2*(ppg).  Add to half of the number of games in a season.  That's it.

For example, in 2007, all NFL teams scored 11104 points.  If we divide that by 32 (number of teams), by 16 (number of games), and then multiply by two (because two teams play in each game), we get 43.375 as the number of ppg.  The Patriots that year had a points differential of (589-274=)315 points.  315/43.375=7.26 wins, plus 8 (a half-season's worth) = 15.26 wins.  So, by my formula, we'd expect the 2007 Patriots to have gone 15.3-.7... which is much closer to their actual record of 16-0 than the Pythagorean expectation, which gave them less than 14 wins (13.8).

Here are the expectations for the other teams I mentioned:
1985 Bears - 14.0-2.0
1998 Vikings - 14.1-1.9
1972 Dolphins - 12.3-1.7
2008 Lions - 2.3-13.7
1972 Bucs - -.4-14.4

Yes, that is a negative expectation of wins for the 1972 Buccaneers.  They were that bad.  In every case, this linear method comes closer to the team's actual record (for the Vikings, it's one full win closer!), except the 1985 Bears, which my method misses by .1 wins more than the classic way of doing it.  Frankly, I don't really see how anyone could use the Pythagorean method when one could do this, which is just as easy, works the same for middle-of-the-pack teams, and works significantly better for teams at the periphery.

Saturday, September 29, 2012

Fun with Runs Created

I've been rather prolific lately.  It's been fun while it's lasted, though I don't know how much longer that'll be.

Regardless, when I was looking at all of that Chipper Jones stuff yesterday, I couldn't help but start looking at Runs Created.  Why?  Well, when I was thinking "What might Chipper Jones have 1500 of?" one of the things that crossed my mind was RC.  And, in fact, Chipper does have over 1500 RC.

For the uninitiated, Runs Created has many versions, but the basic version is this:

RC=((H+BB)*TB)/(AB-H)

It's a handy formula, because it only takes four variables.  Just for funsies, I checked six teams this year, to see how closely these factors matched with what we'd expect them to be.  I tried to get teams from different types of parks, overachievers, underachievers, good teams, and bad.  And I didn't want to do all 30 teams.  So anyway, you can see how ridiculously accurate RC is.  The team is listed, and then actual Runs/RC:

Milwaukee:  752/748
Pittsburgh:  639/626
Los Angeles Dodgers: 616/606
Colorado Rockies:  745/777
New York Mets:  639/640
New York Yankees:  765/789
Boston Red Sox: 721/714

So you can see that Colorado's been a pretty extreme example... but they've been awful, so it makes sense that they've been underachieving what components would have you believe they'd do.

Anyway, RC doesn't actually work great for individual hitters.  The reason is that the formula assumes that these four factors (AB, H, BB, TB) actually interact with one another.  Well, obviously, Chipper Jones doesn't just interact with his own AB/H/BB/TB... he actually interacts with other people's... and those other people weren't as good as Chipper Jones.  So RC naturally overestimates the abilities of good hitters.  But who cares?  It's still fun, and it's a good, summative way to look at basically all parts of hitting while still being easy enough to calculate yourself.  So keep this in your pocket, because it's fun to pull out sometimes.

And on to the crux of this post...

So, after goofin' around with RC a little, I looked at the leaderboard on Baseball-Reference (mad shout-out to them... that's where I've gotten the stats for the last few posts I've done, but I completely forgot to credit them - sorry, Sean and Neil!), and realized that they used a more complex version of RC*.  No biggy.  I just used their top 100 players, and recalculated the "basic" version of RC for each player.

*Under normal circumstances, the various "technical" versions of RC don't differ that much from one another, but they do for a couple of people.  Specifically, they crush the guys who have mad base-stealing skills.  Barry Bonds loses 246 Runs using the basic version, and so does Joe Morgan - seriously, both lost 246, on the nose.  Rickey Henderson lost - get this - 334 runs.  Those are HUGE differences, and I'm sorry to have to not include them.  But it does take away from the beautiful simplicity of RC the more you add.  And most other players were affected by 40 runs or fewer.  That sounds huge, but since we're dealing with guys who, for the most part, had 20-year careers, we're talking 2 R/year, which is pretty insignificant.  74/100 were affected by 60 runs or fewer, and no one had 60 or more runs added by using the less-technical version.  Besides, while it does affect the number, it only rarely has a significant effect on the order of players, so I decided to do this as simply as possible.

Anyway, this is really just for fun.  So I calc'd it, and looked at the results.  Interesting, no doubt.  But then I decided to look at it as a rate stat.  Actually, as a ratio stat, because I didn't want to estimate PAs, or use ABs, or use AB+BB (which would have been fine, I guess).  So I used batting outs (AB-H).  My question was, who has "hit" .300, using RC/O (that's runs created/out)?

Well, of these 100 guys, less than 1/3 of them.  Ruth tops the list, with nearly 1 RC for every 2 outs (.495).  Hank Aaron "hit" exactly .300 by this calculation.  As always, the list was populated by pre-integration guys, and guys who played in the Selig Era.  Every one of the 32 guys fits into one of those 3 categories, or is Hank Aaron, Willie Mays, or Mickey Mantle.  I was expecting Mike Schmidt, but he finished lower at .273 than (get this) Will Clark (.274).  In case you're curious, the worst finisher by rate was Lou Brock, who "hit" .198.  Now, I know what you're thinking - "but Brock was a basestealer!  So he probably got robbed by using the basic formula!"  Nope.  Brock lost only 46 runs by using the basic version of RC.  Still a hefty load, yes, but only enough to push him up from #100 to #98.  So, yeah.

But then I thought, well, why don't I take the rate, and multiply it by the raw number.  That should give a nice compromise.  Of course, it does do this.  If you're into algebra, write out the equation, look at the cancelling, and be amused.  I was.  But it doesn't really matter, because it pretty much looks right.  Anyway, by this reckoning, here are the top ten hitters of all-time, balancing rate and total.  They're presented as Runs Created/RCRate/RC*RCRate, with the third of those being the organizing principle.

Babe Ruth 2733/.495/1352
Ted Williams 2347/.468/1091
Barry Bonds 2646/.383/1013
Lou Gehrig 2250/.426/959
Stan Musial 2551/.348/887
Ty Cobb 2510/.346/870
Jimmie Foxx 2119/.386/818
Rogers Hornsby 2030/.387/786
Hank Aaron 2576/.300/772
Willie Mays 2333/.307/716

Something about having Aaron and Mays next to one another feels really right about this.

In case you're curious, since we've been talking Chipper lately, he ranks #19, for now.  I say "for now" not just because he's active, but because he's two spots behind A-Rod, one ahead of Todd Helton, and two ahead of Jim Thome.  Actually by B-R RC, RC rate, or RCRate+RC, Thome and Jones end up right next to each other, so I guess they belong together.  But anyway, there could still be some movement among those guys, even by the end of the season, so nothing's really set in stone there.  Manny Ramirez (#12) is the highest ranking "active" player.  Among "active" players who actually are active, Albert Pujols tops the list (#14).  The lowest ranking player among these 100 was Steve Finley.  At #99 was Lou Brock.  Derek Jeter ranks 1 point behind Lance Berkman (432-433).  I wouldn't have guessed that.  Edgar Martinez ranks at #37 - and people say he's not a HOFer.  Milwaukee's own Al Simmons ranks #22.  Speaking of Milwaukee, Robin Yount is all over the map.  He ranks #55 by RC (behind another Milwaukee connection, Eddie Mathews), by rate he ranks #98 (ahead of Finley and Brock), and by overall, he ranks #90.  Frankly, it's not bad for a SS, I think.  Molly fairs better, #56 overall; and since I mentioned Mathews, he's one spot ahead of Molitor.

So, that's pretty much it, I guess.

The Greatness of Chipper

Well, Cybermetrics got me thinking again with Cy's post over there today.

Players with .300 Avg, 1000 XBH, 1500 BB, 150 SB, 1500 RBI:

Chipper Jones

That's the whole list.  So that's pretty cool.  But here are some other exclusive lists of which he's a part.

.300/.400/.500 career guys:

Dan Brouthers
Ty Cobb
Jimmie Foxx
Lou Gehrig
Hank Greenberg
Harry Heilmann
Todd Helton
Rogers Hornsby
Shoeless Joe Jackson
Chipper Jones
Edgar Martinez
Stan Musial
Lefty O'Doul
Mel Ott
Albert Pujols
Manny Ramirez
Babe Ruth
Tris Speaker
Frank Thomas
Joey Votto
Larry Walker
Ted Williams

1500 RBI, 1500 R, 1500 BB (the 1500 Club, as it were)


Barry BondsLou Gehrig
Chipper Jones
Mickey Mantle
Stan Musial
Mel Ott
Babe Ruth
Mike Schmidt
Jim Thome
Ted Williams
Carl Yastrzemski
 And, of course, both groups combined (which gives us totals and rates combined):


Lou Gehrig
Chipper Jones
Stan Musial
Mel Ott
Babe Ruth
Ted Williams


Honestly, I know all about the "let's make a list fallacy," as Bill James called it, but I nonetheless find it impressive that one can create a group with just these six names on it.  I mean, the other five are generally regarded as some of the best pure hitters of all time (although Mel Ott is often left out of such discussions).  And only one of them played his entire career post-integration:  the great Chipper Jones.

Friday, September 28, 2012

Answer to Trivia Question

Over at Cybermetrics, there's a post asking two trivia questions.  First, who are the only two players with 1200+ RBI, 250+HR, 300+ SB, and 3000+ Hits.

Easy.  Got it on my first guesses.  Willie Mays and Derek Jeter.

But that's actually the lesser question.  The primary question is, "Through 1990, Who Were The Only 3 Players With 1000+ RBIs, 250+ HRs, 250+ SBs and 2500+ Hits?"

Answer:
Willie Mays
Joe Morgan
Vada Pinson

Since 1990 (since it's only seven more guys):
Craig Biggio
Barry Bonds
Andre Dawson
Steve Finley
Derek Jeter
Gary Sheffield
Robin Yount

Actually, both Yount and Paul Molitor narrowly miss on the first question.  Yount finished 29 SBs shy... Molly missed by 26 HRs.

For the second trivia question, I noticed that including RBI actually has no bearing on the answer to the question.  As to the first question, Biggio misses by 25 RBI.  I guess Biggio and Jeter are pretty closely tied in my mind.  I've watched them both throughout my life, both are middle infielders, both are part of a core "group" of players (Bags and Bigg in Houston, the "Core Four" in New York), both are associated with just one team (though, who knows, Jeter may finish his career elsewhere).  It doesn't surprise me to see them this close statistically on such a list.  The only real difference is that the media had a positive effect on Jeter's popularity; the media was more or less neutral on Biggio, though it could be argued that they had an averse effect, by not appreciating what he did well.  Anyway, that's that.

Thursday, September 27, 2012

ERA+ Estimators, All-Time Greats

So, after my last post (which I realize just went live this morning), I decided it would be fun to look at some of the great seasons of all time.  If you need explanations of what the numbers mean, see that other post.  Here are the numbers:

Bob Gibson, 1968:  206/106/628
Doc Gooden, 1985:  322/137/892
Greg Maddux, 1995:  235/91/494
Walter Johnson, 1910:  428/181/1585
Steve Carlton, 1972:  256/136/887
Curt Schilling, 2002:  328/196/852
Roger Clemens, 1997:  361/165/954
Pedro Martinez, 1999:  520/223/1111
Hal Newhouser, 1946:  867/156/2540
Randy Johnson, 2001:  320/207/1008
Justin Verlander, 2009:  228/112/548
Sandy Koufax, 1965:  300/207/1008
Lefty Grove, 1930: 4913/145/14299 (!!!!!)
Dizzy Dean, 1933:  945/120/2770
Cy Young, 1905:  317/123/1018

What's funny is,  last year, no one broke 1000 in the final category (and I doubt anyone will this year).  Basically, all of these guys either won the Cy Young in the year noted, or there was no CY, but the pitcher at hand was considered the best in the league.  There are a couple of exceptions, however:  Schilling '02 and Verlander '09.

Verlander lost out to Zack Greinke, who posted a 234/109/536 line, which is very, very similar to Verlander's.  Schilling in '02 lost out to teammate Randy Johnson, who posted a 300/175/780 line, which is just a hair below what Schilling did that year.  Neither of these could really be considered a "bad" choice, particularly Greinke over Verlander in '09, since they were nearly identical by this measure.

These columns are, of course, somewhat interesting.  What I found myself most drawn to was the middle column - it's SO-BB over average (if an average pitcher faced the same number of batters).  Both Randy Johnson and Sandy Koufax had differences of 207 over an average pitcher, but both pale in comparison to Pedro Martinez's 223 in 1999.

As for the other two columns, the first functions a bit like ERA+:  it shows how much better the player was than the league rate.  Obviously, Lefty Grove's 1930 line is absolutely ridiculous.  So is Martinez's, Newhouser's, and Dean's, when you look at them.  But the others?  Well, they're not actually that far off from some of the best ERA+ seasons of all-time.  High-200s, low-300s seems pretty normal for an historically great season.  So it doesn't even seem weird.

The final column, which is the rate/league rate multiplied by innings pitched, serves to take workload into account, so that a relief pitcher's line can be compared (somewhat) to a starting pitcher's.  Well, again, Grove is off the charts.  But most of the other numbers are pretty tame, actually.

So, the point is, I really like this stat line, and I think I'll return to it once in a while to check up on how various pitchers are doing in the coming years.

ERA+ Estimator

Tom Tango's been doing some brilliant stuff lately.  That links to an article at The Hardball Times, at which there is a discussion of (and hyperlink to) an article from THT last week about ERA estimators.  Anyway, as it turns out, the best way to estimate ERA is (K-BB)/BF.  That's it.  Strikeouts, minus walks.  Then divide by batters faced.

This is very, very interesting stuff, indeed.  Because I have an idea for how I may look at Cy Young voting differently in light of this fact.  Essentially, it makes sense to me to take a players (K-BB)/BF, and divide it over the league rate.  That is, it becomes (K-BB)/BF+, for all intents and purposes, or Est+ (as in "estimated+").  Here's last year's AL:

15655 SO
6949 BB
86425 BF
For a quotient of:  .1007

And, in that order, here are some of the leading candidates for last year's AL CY:

Verlander - 250/57/969
Sabathia - 230/61/985
Weaver - 198/56/926
Haren - 192/33/953
Wilson - 206/74/915
Hernandez - 222/67/964

Overall, here are their personal quotient, over the league quotient (of .1007, if you recall), times 100:

Verlander - 198
Sabathia - 170
Weaver - 152
Haren - 165
Wilson - 143
Hernandez - 159

Now, if you wanted to multiply these times IP to get a playing time factor, that would be fine by me.  But just know that this might be a way to look at things in the future.  Or another way to look at it would be to look at the raw total difference between the pitcher at hand and an average pitcher.  In other words, the league rate of (SO-BB)/BF, multiplied by the individual at hand's BF, and then subtracted from the individuals SO-BB.  In mathematical terms, it would look something like this ("pl" for "player," "lg" for "league):

plSO-plBB-(plBF(lgSO-lgBB)/lgBF)

For the aforementioned pitchers, that would yield these results (numbers truncated, rather than rounded; rate*IP in parentheses):

Verlander -95 (496)
Sabathia -69 (404)
Weaver -48 (358)
Haren -62 (394)
Wilson -39 (319)
Hernandez -57 (373)

Clear-cut in favor of Verlander, right?

So why do I bring this up?  I bring it up because of the Cy Young race in the NL right now.  As it stands, here are the numbers for some of the best candidates:

Dickey - 151/52/331
Gonzalez - 134/32/260
Cueto - 112/13/237
Kimbrel - 358/67/215
Chapman - 305/65/211
Kershaw - 151/52/321

No, those numbers for Cueto and Kimbrel are not misprints.  They're seriously that much better than the league... albeit in limited numbers.  However, as you can see, the difference in total numbers is not that great, as they rank ahead of all but one guy, who's out on the periphery...

Cliff Lee - 174/71/346

Seriously.  The guy with the 6-8 record is blowing people away.  He's actually having a great year; his team's just not winning.  The Phillies' offense is terrible, and it's getting taken out on Cliff Lee, even though he's probably been the best starting pitcher in the NL this season.

Now, I don't ever think a number like this would ever go "mainstream," but it's interesting to think that, if it did, Cliff Lee might have a shot at the NL Cy Young.  But as it stands right now, I can't imagine he's on too many people's radar screens.

Anyway, here's the AL as it stands right now, just in case you're curious:

Sabathia - 155/49/285
Hernandez - 153/54/338
Verlander - 162/66/374
Scherzer - 191/81/352
Price - 154/50/315
Weaver - 117/13/211
Darvish - 139/35/256
Sale - 158/50/298
Shields - 145/46/308
Rodney - 180/24/126
Nathan - 232/37/142

Now, obviously, the season isn't over yet, so we could see some movement on both of these leaderboards.  But as it stands right now, I believe my vote for AL Cy Young, strictly on the basis of these stats, would go the way of Justin Verlander.  He's pitched more innings than Scherzer, who's pitched better.  They'd be 1-2, with King Felix in third, since I view the third of these columns as most significant.  In the NL, I desperately want RA Dickey to win the Cy Young.  I've loved the guy since he was with the Twins and I was living in Minnesota.  But I can't shake the nagging suspicion that Cliff Lee is actually the NL's best pitcher.  So I suppose it'll be like last year's NL MVP, in which I voted for Matt Kemp, because he was the best player... but I wanted Ryan Braun to win, because he's my favorite player.  Likewise, I'll be rooting for RA Dickey, but when the time comes for the IBAs (Internet Baseball Awards - you should vote if you never have before!), as things stand right now, I'm voting for Cliff Lee.

Monday, September 24, 2012

Cabrera vs. Trout

So, everyone's weighed in on this already.  Like Brian Kenny.  And Joe Posnanski.  And a bunch of others.  What do I have to say?  Well, the "statheads" are right, of course.  Trout's been better than Cabrera this year, and by quite a bit.  That's true whether or not Cabrera wins the Triple Crown.

But I'm not actually here to debate the two (in spite of the title), because to my mind, it's pretty cut-and-dried who's been better.  I'm here to celebrate Miggy Cabrera.

As some of you who read older posts may have noticed, I love the Triple Crown.  I understand that it's pretty meaningless in the grand scheme of things, but it's so flippin' fun, I just can't help but love it.  But, as everyone knows, there's a HUGE amount of luck in the Triple Crown.  Like take Yaz's Triple Crown:  44/121/.316.  Good numbers, all.  But at no point in the 1990s would he have led the league in ANY of those categories.  At all.  So while it's true that he won the Triple Crown, that season wouldn't have in a lot of other years.

Now, I know I'm cherry picking here, and projecting, and not adjusting for era.  But Miggy's final numbers this year may be:  45/140/.330!  That's incredible.  Do you know how many times that's been done in MLB history?  17 times.  That's it.  By 7 different players.  Here's the list:

Babe Ruth, 1921:  59/171/.378 (no MVP awarded)
Babe Ruth, 1926:  47/146/.372 (ineligible for MVP)
Lou Gehrig, 1927: 47/175/.373 (Won MVP)
Babe Ruth, 1927:  60/164/.356 (ineligible for MVP)
Babe Ruth, 1929: 46/154/.345 (no MVP awarded)
Babe Ruth, 1930:  49/153/.359 (no MVP awarded)
Hack Wilson, 1930: 56/191/.356 (no MVP awarded)
Babe Ruth, 1931:  46/163/.373 (Did Not Win MVP)
Lou Gehrig, 1931: 46/184/.341 (Did Not Win MVP)
Jimmie Foxx, 1932:  58/169/.364 (Won MVP)
Jimmie Foxx, 1933: 48/163/.356 (Won MVP)
Lou Gehrig, 1934:  49/165/.363 (Did Not Win MVP, Won Triple Crown)
Lou Gehrig, 1936: 49/152/.354 (Won MVP)
Joe DiMaggio, 1937:  46/167/.346 (Did Not Win MVP)
Jimmie Foxx, 1938: 50/175/.349 (Won MVP)
Hank Greenberg, 1938:  58/146/.340 (Did Not Win MVP)
Todd Helton, 2001:  49/146/.336 (Did Not Win MVP)
Miguel Cabrera, 2012?

So, you can see, players have not won the MVP with this kind of season before.  In fact, in some ways, Gehrig's 1934 is most similar:  team missed the playoffs (as the Tigers may), but Gehrig reached these milestones AND won the Triple Crown... but he lost the MVP.  As you can see, there have been 17 of these seasons.  But in six of them, there was no MVP awarded, or the player who accomplished the feat was ineligible.  That leaves 11 seasons.  Of those 11, two occurred in the same season as another.  That leaves nine seasons in which a player COULD have won the MVP, finishing with a .45/140/.330 line. Someone won with that line 5 times - just over half (and keep in mind that we're not including near-misses, like Albert Belle in 1998, or Ted Kluszewski in 1954, which would lower the percentage even more).  So, while Cabrera is putting up a fantastic season, it still wouldn't be unprecedented for him to not win the award; and that's true even if he did win the Triple Crown.

One final note:  all of these seasons occurred in the 1920s and 1930s, the best eras in history for baseball offense, and before integration, good minor league systems, and proper scouting; well, besides the Helton season, which occurred in perhaps the most run-rich environment (outside of the Baker Bowl in the early '30s) in baseball history.  So if Cabrera does it this year, we may actually say that it's a totally unique season in baseball history.  And he deserves to be celebrated for that.  He just doesn't deserve the MVP.