Help with calculating WARP (from basketball-prospectus)

Home for all your discussion of basketball statistical analysis.
Kevin Pelton
Site Admin
Posts: 104
Joined: Thu Apr 14, 2011 10:05 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by Kevin Pelton »

Yeah, use the traditional one there.
AcrossTheCourt
Posts: 237
Joined: Sat Feb 16, 2013 11:56 am

Re: Help with calculating WARP (from basketball-prospectus)

Post by AcrossTheCourt »

So on the website http://www.sonicscentral.com/warp.html Pos% means the traditional usage? And where you use "usage" you mean the one with adjusted assists? Does that mean teammate offrat should use the traditional usage? If so, LeBron's Teammate OffRat is 105.6. Otherwise it's 105.9. If that's correct, then we can move on to Teammate FGA%.
Kevin Pelton
Site Admin
Posts: 104
Joined: Thu Apr 14, 2011 10:05 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by Kevin Pelton »

In this case it looks like I used the definition of usage with assists. But it should be Offensive Rating Minor (points per play) rather than Offensive Rating Major (points per possession), so I have LeBron at 94.8.
AcrossTheCourt
Posts: 237
Joined: Sat Feb 16, 2013 11:56 am

Re: Help with calculating WARP (from basketball-prospectus)

Post by AcrossTheCourt »

Okay I got 94.8 for Teammate OffRat too. Next step?
Kevin Pelton
Site Admin
Posts: 104
Joined: Thu Apr 14, 2011 10:05 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by Kevin Pelton »

Moving along that group:
Teammate FGA%: .782
Teammate eFG% = .503
TeammateFG% = .463
TeammateRebOpp% = .450
AcrossTheCourt
Posts: 237
Joined: Sat Feb 16, 2013 11:56 am

Re: Help with calculating WARP (from basketball-prospectus)

Post by AcrossTheCourt »

Teammate FGA%:
The formula is (1 - ((LgTO/LGPos)*(1+(0.5*(0.2-Usage)))) - (LgFTA/LgPoss)) but it seems like there should be a .44 product with the last term because we're looking at possessions. If I use .44, then I get:
=(1-((27620/208413)*(1+(0.5*(0.2-0.321))))-(44472/208413)*0.44)
=0.78161

The usage I use there is the traditional one, right?

Teammate eFG%:
This one isn't fully described. "In the denominator, we must take out possessions that end in turnovers (which is affected by the usage rate) and those that end in free-throw attempts."

Here's what I have so far:
=(94.8/100-33465/208413)/(1-27620/208413-0.44*44472/208413)/2
Denominator is (1-LgTOV/LgPos-.44*LgFTA/LgPos)
=0.5091

How do I adjust turnovers for usage rate? Multiply it by (1-0.25*(Usage-0.2))?

Teammate FG% is an easy calculation. so it's all about having the right league FG% and eFG%.

LgFG%
0.4479

LgeFG%
0.4873

TmReb Opp% is easy as well and depends on the previous calculations. I'm getting 0.425, but Teammate eFG% wasn't correct.
Kevin Pelton
Site Admin
Posts: 104
Joined: Thu Apr 14, 2011 10:05 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by Kevin Pelton »

I think, to simplify, the denominator can just be FGA%.
AcrossTheCourt
Posts: 237
Joined: Sat Feb 16, 2013 11:56 am

Re: Help with calculating WARP (from basketball-prospectus)

Post by AcrossTheCourt »

That's what I did at first. Then I convinced myself of something else....

With that, I get:
Teammate eFG% = 0.5038
Teammate FG% = 0.4631
Teammate RebOpp% = 0.4492
TmReb Opp% = 0.4276

That's really close. Not sure what the small discrepancy is. For comparison, Haslem's Teammate eFG% is 0.4785. And now LeBron's final OffRtg is 114.5.

Thanks for all the help, by the way. I know you've been busy with Hollinger's profiles and other ESPN stuff.
Kevin Pelton
Site Admin
Posts: 104
Joined: Thu Apr 14, 2011 10:05 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by Kevin Pelton »

I have LeBron at 114.5, but I think we're within the margin of error now.

This was useful. I'd like to go back and update the instructions to clear up some of the places that were confusing since I wrote them long after actually putting everything together in the spreadsheet.
AcrossTheCourt
Posts: 237
Joined: Sat Feb 16, 2013 11:56 am

Re: Help with calculating WARP (from basketball-prospectus)

Post by AcrossTheCourt »

Clearing up which usage for each calculation would be helpful. Give them different names too. (ModUsage? UsageA? Usage2?) And was it only used in one place?

Just to check, here's are some other Offensive Ratings I calculated:
Wade: 111.8
Haslem: 104.9
Ray Allen: 110.1
Chalmers: 108.4
Battier: 108.5

Since there are no other sources publicly for WARP, could I post them somewhere or share them? Thanks again.
oosode
Posts: 1
Joined: Tue Sep 17, 2013 3:31 am

Re: Help with calculating WARP (from basketball-prospectus)

Post by oosode »

So, was the WARP data from past seasons ever made publicly available?
Crow
Posts: 10536
Joined: Thu Apr 14, 2011 11:10 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by Crow »

WARP includes shot defense but it is based of the overall shot defense data for the team for the season regardless of who the player guarded and well he did or did not do at the counterpart level (or on help defense either) and regardless of whether he was even on the court for some of the specific baskets. Thus the treatment of shot defense in WARP is not very individualized and similar is this regard to winshares and wins produced (which at least make an attempt to include shot defense whereas many earlier metrics such as PER did not). Given that shot defense is probably 20-25% of all the value being assigned to players (on offense and defense), the lack of precision of this component of WARP seems worth noting in a discussion of the formula. With use of counterpart data and / or play by play data it could conceivably be improved.

The treatment of shot defense in adjusted plus minus is subject to error in the estimates but whether that error is more or less than what occurs in WARP and winshares is more or less on average is a worthy question.
AcrossTheCourt
Posts: 237
Joined: Sat Feb 16, 2013 11:56 am

Re: Help with calculating WARP (from basketball-prospectus)

Post by AcrossTheCourt »

Any word on WARP being on ESPN soon?
jkeen39
Posts: 21
Joined: Mon Feb 03, 2014 10:04 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by jkeen39 »

I wanted to follow up on this thread as I'm trying to calculate WARP myself. I struggled at first with Kevin's explanation (as he admits it probably needs some work) but the step by step calculations here really helped.

Before I dive into my questions, I wanted to note that I also got an Offensive Rating of 114.5 for LeBron in 2011-12. I thought I had the formulas all figured out but got slightly different numbers for the other few players that Across the Court calculated:

Wade: 111.89
Haslem: 104.94
Chalmers: 108.29
Battier: 108.18

Hoping Kevin can chime in with his numbers on those guys so I can figure out if I need to go back and fix something.

Onto my main question, it seems this thread stopped at the Offensive Rating calculation and never got all the way to WARP.

In my attempts to calculate the Defensive Rating, something clearly went wrong but I'm not quite sure where my calculations broke down. Hoping Across the Court or Kevin can chime in on what their numbers are for LeBron in 2011-12. Here is what I came up with, I can post the detailed calculations once someone can help me pinpoint where I went wrong.

Pos (Defense) = 5,086.4
TmBSPos = .1295
LgFTARate = .5051
TmFTAPos = .0846
TDF= .1450
TmFTOPos = .0668
TmOppPos = 7,015.08
TmFGRat = 1.0379
TmDefRatMinor = 89.1058
TmDReb% = .7465
OppFG% = .4770
OppRebOpp% = .5215
TmDefRatMajor = 92.9540
Win% = .9488
WARP = 25.87

Obviously my Win% and WARP calculations are WAY too high and somewhere along the line I've got a bad formula. Appreciate any help.
Kevin Pelton
Site Admin
Posts: 104
Joined: Thu Apr 14, 2011 10:05 pm

Re: Help with calculating WARP (from basketball-prospectus)

Post by Kevin Pelton »

I actually have different offensive ratings for those guys than both of you:
Wade 111.44
Haslem 103.26
Chalmers 107.40
Battier 106.76

On the defensive end, we look relatively similar through Defensive Rating Major, which should be much higher than the Minor version (I have 100.2 for LeBron). The original possessions are different, which leads me to think you might have team turnovers included as opposed to just the sum of individual turnovers.
Post Reply