Pages

Monday, May 5, 2014

2014 NBA Playoffs 2nd Round Preview

jQuery UI Accordion - Default functionality There are many potential areas of improvement in both the model and the testing of the model, most importantly perhaps a means of adjusting for various series states (i.e. how should the line be adjusted when the home team is down 1-0), but in the still small sample size of the first round, I was 20-14-1 against the spread using my model with subjective adjustments.  While that's a 59% win percentage (which would be amazing if it were indeed my true win percentage), the small sample size means that this likely isn't my true win percentage, as even a coin flip would still finish with the same record or better in 34 trials 20% of the time.  Here are the full results:

ATL 6 times: 3-2-1
MIA 3 times: 2-1-0
BKN 7 times: 4-3-0
CHI 2 tims: 1-1-0
DAL 1 time: 1-0-0
SAS 1 time: 0-1-0
MEM 7 times : 4-3-0
GSW 7 times: 5-2-0
HOU 1 time: 0-1-0

I will now proceed to provide a similar analysis of the second round.  There will be new minutes allocations (changed due to updated information, i.e. that Shane Battier has apparently retired, as well as different matchups) and a slightly smaller home-court-advantage adjustment.  The minutes allocations will be slightly more conservative for the top players, as I failed to account for the potential of foul trouble dragging average minutes down (which is what happened in Clippers-Warriors), and the home-court-advantage adjustment will be 3.2 points.  Of course, as mentioned earlier, one future improvement would be to make these adjustments empirically.  Similar to before, all of the computation was done in R and the script I ran will be included.

Series Previews:

East: (1) Indiana vs. (5) Washington

Model Vegas*
Game 1 Probability IND: 69% / WAS: 31% IND: -175 / WAS: +155
Game 1 Spread IND: -5.4 / WAS: +5.4 IND: -4 (-115) / WAS: +4 (-105)
Series Probability IND: 71% / WAS: 29% IND: -160 / WAS: +140

Based solely on regular season numbers, it would appear that my model would suggest betting the Pacers.  However, the same disclaimer from Round 1 still applies, given that Indiana has simply been a much worse team over the final few months, including the series against the Hawks.  Given that my model does not have a recency weighting factor, the regular season numbers use Indiana's season-long averages.  One potential proxy for Indiana's struggles (that happens to include a separate but also important factor) would be Nate Silver's study on rest.  If I understand the study correctly, a team's margin of victory relative to SRS in the first round (independent of the number of games played) is not significant, but the recency factor should impact the number of games played as well.  Furthermore, while Atlanta posed specific matchup issues for Indiana that Washington doesn't in terms of three-point shooting bigs, there are other issues for Indiana.  The supposed better matchup for Hibbert might not necessarily be a good thing, as Hibbert has been horrendous in the second half of the year and handing Hibbert more minutes might have a net negative effect.  Furthermore, Indiana is a horrible offensive team that can't pass, screen, or space the floor, and their past offensive adequacy was dependent on David West overpowering his defender and drawing help, and he'll likely be unable to manhandle Nene the way he might other defenders.  As a result, I would adjust the margin of victory for each game towards Washington by approximately 4 points.  This moves Indiana's expected margin of victory in Game 1 to 1.5 and actually makes Washington a 58% favorite in the series.  As a result, I would bet Washington.

East: (2) Miami vs. (6) Brooklyn

Model Vegas*
Game 1 Probability MIA: 79% / BKN: 21% MIA: OFF / BKN: OFF
Game 1 Spread MIA: -10.0 / BKN: +10.0 MIA: -7 (-115) / BKN: +7 (-105)
Series Probability MIA: 90% / BKN: 10% MIA: -550 / BKN: +375

There are a number of potential adjustments to the model in the Miami-Brooklyn series.  The first is that Silver’s study suggests that a team coming off a sweep is even more likely than expected to win against a team coming off a seven-game series.  Counteracting this, there is some anecdotal evidence that there might be diminishing marginal returns on RAPM, so, for example, a ten-point expected margin using RAPM in reality might only be eight.  Furthermore, Brooklyn had significant success against Miami during their regular season four-game series (yes, the margins of victory were small, but that they were positive is a significant improvement for Brooklyn over the overall numbers of each team), and there are matchup reasons that explain this.  Miami’s bread-and-butter half-court offense involves LeBron pick-and-rolls with a big, and Brooklyn has the big wings and quick bigs to switch these plays. Furthermore, supply of big wings also makes it difficult for LeBron to post up and draw help, as Pierce, Johnson, Livingston, Kirilenko, and even Teletovic could have success defending him in isolations.  On the other side of the ball, Miami’s defense in the past has been predicated on aggressive traps of pick-and-rolls (a little less so this year), which led to both efficient defense and efficient offense (as the traps led to turnovers and fast breaks).  However, Brooklyn does not run many pick-and-rolls, and their offense involves more isolations than normal.  While isolations, even ones by skilled isolation players, are inherently inefficient shots, they’re inefficient against anyone and Brooklyn won’t experience much extra resistance on their isolations because they’re facing Miami.  As a result, I would adjust the expected margin six points towards Miami for the first-round performance/rest, five points towards Brooklyn for diminishing marginal returns (more for the Heat home games), and five points towards Brooklyn for the matchup issues.  This would make the Heat just under a six-point favorite in Game 1 and a 73% favorite in the series.  These numbers are already very close to the Vegas lines, and given the uncertainty in my manual adjustments, I would abstain from this series for now.

West: (1) San Antonio vs. (5) Portland

Model Vegas*
Game 1 Probability SAS: 84% / POR: 16% SAS: OFF / POR: OFF
Game 1 Spread SAS: -11.9 / POR: +11.9 SAS: -6.5 / POR: +6.5
Series Probability SAS: 96% / POR: 4% SAS: -900 / POR: +550

Having not paid much attention to inter-series rankings beforehand, I was surprised to see that Dallas graded as a significantly better team than Portland.  The reason for the dissonance was threefold: 1) Dirk was a significantly better per-minute player than Aldridge (who already was pretty awesome), 2) Portland’s worst rotation players (Wright and Williams) grade out worse than Dallas’ (Calderon and Marion), and 3) Dallas’ players simply have less name value than Portland’s (specifically, Carter, Harris, and Wright).  However, there are reasons to believe that these are two very similar teams. They’re both built around a two-point shooting bigs creating threes for teammates, and both coaches smartly utilized switching man defenses to slow down elite pick-and-roll attacks in the first round (unsurprising given Stotts’ background as a former assistant under Carlisle).  Furthermore, much of Dallas’ high ranking in my model was dependent on a minutes distribution tilted away from their bad starters, and simply adjusting Wright, Harris, and Crowder’s minutes towards Calderon, Marion, Dalembert, and Blair lowers the Mavs’ efficiency down to 7.9, much closer to Portland’s 6.9.  Given San Antonio’s struggles against Dallas and the clear blueprint established in slowing down their offense, I certainly don’t believe the Spurs should be almost a nine-point favorite on a neutral court.  However, the Spurs also adjusted later in the series to more Ginobili pick-and-rolls in place of Parker pick-and-rolls, as Ginobili was able to hit pull-up threes or get to the basket using his long strides against switches, and they had much more success in the later games of their series.  As a result, I would adjust the line four to five points towards Portland per game (more for the Spurs home games due to diminishing marginal returns on RAPM), which would make the Spurs a seven point favorite in Game 1 and an 83% favorite in the series.  As a result, I would abstain from this series for now.

West: (2) Oklahoma City vs. (3) L.A. Clippers

Model Vegas*
Game 1 Probability OKC: 52% / LAC: 48% OKC: -225 / LAC: +185
Game 1 Spread OKC: -0.1 / LAC: +0.1 OKC: -5 (-115) / LAC: +5 (-105)
Series Probability OKC: 36% / LAC: 64% OKC: -200 / LAC: +170

The biggest difference between the Thunder and Clippers statistically is that the Thunder give significant minutes to horrible players (Butler, Perkins, Adams).  There is definitely a mainstream misconception that the Grizzlies were better than the Warriors minus Bogut and thus that the Clippers struggled in Round 1 more than the Thunder, and this is simply not true.  In reality, the Warriors were an elite team that also presented matchup problems that Oklahoma City likely will not provide.  Golden State was able to mostly limit the Clippers' Paul-Griffin PNR by switching, which was made possible by the Warriors assigning a bigger defender as Paul's primary defender (mostly Thompson and sometimes Iguodala) and Draymond Green's ability to defend perimeter players after a switch.  Furthermore, the Warriors had no hiding places for perimeter players, so Darren Collison, Redick, and Crawford were enormous liabilities defensively, and this won't be the case with Fisher, Sefolosha, Butler, and even Jackson serving as potential hiding spots.  Furthermore, Oklahoma City had a lot of issues defending the three in the regular season, due largely to inattentive ball-watching or over-helping, and the Clippers have the ball/player movement to take advantage of that.  Durant will definitely be a problem, given that Barnes is at best an above average defender, and the Clippers don't really have big wings behind him as second options.  Still, my raw numbers like the Clippers significantly more than Vegas does, and the net matchup adjustments may actually be in the Clippers favor.  As a result, I would have a lot of confidence betting the Clippers in this series.
*All Vegas numbers from Bovada


List of minutes estimates and xRAPM ratings:

Show/Hide

x
     Spurs:

player minutes orpm drpm rpm onet dnet net
Boris Diaw 20 0.55 1.45 2.00 0.23 0.60 0.83
Cory Joseph 2 -0.83 -3.38 -4.21 -0.03 -0.14 -0.18
Danny Green 25 0.68 2.61 3.29 0.35 1.36 1.71
Kawhi Leonard 35 0.58 1.84 2.42 0.42 1.34 1.76
Manu Ginobili 30 4.66 -0.11 4.55 2.91 -0.07 2.84
Marco Belinelli 12 1.03 -2.94 -1.91 0.26 -0.74 -0.48
Matt Bonner 5 2.05 0.37 2.42 0.21 0.04 0.25
Patty Mills 15 2.70 0.50 3.20 0.84 0.16 1.00
Tiago Splitter 26 -0.92 4.59 3.67 -0.50 2.49 1.99
Tim Duncan 35 -0.10 5.37 5.27 -0.07 3.92 3.84
Tony Parker 35 3.16 -0.07 3.09 2.30 -0.05 2.25

     Blazers:
player minutes orpm drpm rpm onet dnet net
C.J. McCollum 3 0.03 -0.66 -0.63 0.00 -0.04 -0.04
Damian Lillard 40 4.31 -2.03 2.28 3.59 -1.69 1.90
Dorell Wright 10 -0.86 -0.94 -1.80 -0.18 -0.20 -0.38
Joel Freeland 2 -2.83 0.96 -1.87 -0.12 0.04 -0.08
LaMarcus Aldridge 40 1.73 3.17 4.90 1.44 2.64 4.08
Meyers Leonard 0 -4.22 -0.98 -5.20 0.00 0.00 0.00
Mo Williams 25 0.28 -2.66 -2.38 0.15 -1.39 -1.24
Nicolas Batum 40 1.47 -1.19 0.28 1.23 -0.99 0.23
Robin Lopez 37 -0.29 3.38 3.09 -0.22 2.61 2.38
Thomas Robinson 5 -2.37 -2.03 -4.40 -0.25 -0.21 -0.46
Wesley Matthews 38 1.54 -0.89 0.65 1.22 -0.70 0.51

     Thunder:
player minutes orpm drpm rpm onet dnet net
Caron Butler 22 -0.75 -3.61 -4.36 -0.34 -1.65 -2.00
Derek Fisher 19 -1.14 2.00 0.86 -0.45 0.79 0.34
Jeremy Lamb 2 -0.49 -0.79 -1.28 -0.02 -0.03 -0.05
Kendrick Perkins 20 -7.12 2.73 -4.39 -2.97 1.14 -1.83
Kevin Durant 43 6.36 0.17 6.53 5.70 0.15 5.85
Nick Collison 16 2.75 3.40 6.15 0.92 1.13 2.05
Reggie Jackson 23 0.81 0.50 1.31 0.39 0.24 0.63
Russell Westbrook 36 4.30 0.19 4.49 3.23 0.14 3.37
Serge Ibaka 34 0.88 3.03 3.91 0.62 2.15 2.77
Steven Adams 10 -2.68 -0.93 -3.61 -0.56 -0.19 -0.75
Thabo Sefolosha 15 -1.14 2.29 1.15 -0.36 0.72 0.36

     Clippers:
player minutes orpm drpm rpm onet dnet net
Blake Griffin 41 2.58 1.88 4.46 2.20 1.61 3.81
Chris Paul 38 5.44 1.84 7.28 4.31 1.46 5.76
Danny Granger 13 0.30 0.70 1.00 0.08 0.19 0.27
Darren Collison 15 1.48 -3.00 -1.52 0.46 -0.94 -0.48
DeAndre Jordan 36 0.68 3.60 4.28 0.51 2.70 3.21
Glen Davis 10 -3.08 2.00 -1.08 -0.64 0.42 -0.23
Hedo Turkoglu 2 -0.96 0.24 -0.72 -0.04 0.01 -0.03
J.J. Redick 25 2.98 -2.96 0.02 1.55 -1.54 0.01
Jamal Crawford 25 1.55 -2.31 -0.76 0.81 -1.20 -0.40
Jared Dudley 5 -0.76 0.24 -0.52 -0.08 0.03 -0.05
Matt Barnes 30 2.14 0.58 2.72 1.34 0.36 1.70

     Pacers:
player minutes orpm drpm rpm onet dnet net
C.J. Watson 18 0.39 -0.40 -0.01 0.15 -0.15 0.00
Chris Copeland 4 0.34 -2.05 -1.71 0.03 -0.17 -0.14
David West 36 0.98 2.33 3.31 0.74 1.75 2.48
Evan Turner 14 -1.14 -1.12 -2.26 -0.33 -0.33 -0.66
George Hill 37 2.00 0.60 2.60 1.54 0.46 2.00
Ian Mahinmi 14 -4.85 4.05 -0.80 -1.41 1.18 -0.23
Lance Stephenson 35 0.79 -0.04 0.75 0.58 -0.03 0.55
Luis Scola 10 -3.27 0.76 -2.51 -0.68 0.16 -0.52
Paul George 40 0.03 2.49 2.52 0.03 2.08 2.10
Roy Hibbert 32 -0.94 3.68 2.74 -0.63 2.45 1.83

     Wizards:
player minutes orpm drpm rpm onet dnet net
Al Harrington 4 -0.29 0.22 -0.07 -0.02 0.02 -0.01
Andre Miller 8 1.80 0.12 1.92 0.30 0.02 0.32
Bradley Beal 38 -0.86 -0.08 -0.94 -0.68 -0.06 -0.74
Drew Gooden 8 -0.97 -2.19 -3.16 -0.16 -0.37 -0.53
John Wall 40 2.54 -0.46 2.08 2.12 -0.38 1.73
Marcin Gortat 36 -0.16 3.85 3.69 -0.12 2.89 2.77
Martell Webster 17 2.19 -2.87 -0.68 0.78 -1.02 -0.24
Nene Hilario 36 -1.65 4.39 2.74 -1.24 3.29 2.06
Trevor Ariza 38 -0.26 0.94 0.68 -0.21 0.74 0.54
Trevor Booker 15 -0.12 -2.77 -2.89 -0.04 -0.87 -0.90

     Heat:
player minutes orpm drpm rpm onet dnet net
Chris Andersen 16 0.42 3.99 4.41 0.14 1.33 1.47
Chris Bosh 38 0.29 3.70 3.99 0.23 2.93 3.16
Dwyane Wade 35 1.23 0.87 2.10 0.90 0.63 1.53
James Jones 6 -2.10 0.97 -1.13 -0.26 0.12 -0.14
LeBron James 42 8.72 -0.16 8.56 7.63 -0.14 7.49
Mario Chalmers 33 0.54 1.03 1.57 0.37 0.71 1.08
Michael Beasley 2 -2.94 -2.89 -5.83 -0.12 -0.12 -0.24
Norris Cole 12 -1.60 -1.87 -3.47 -0.40 -0.47 -0.87
Rashard Lewis 10 -2.34 -0.72 -3.06 -0.49 -0.15 -0.64
Ray Allen 20 2.03 -2.77 -0.74 0.85 -1.15 -0.31
Shane Battier 12 -0.29 1.36 1.07 -0.07 0.34 0.27
Toney Douglas 2 0.25 -1.62 -1.37 0.01 -0.07 -0.06
Udonis Haslem 12 -4.21 1.60 -2.61 -1.05 0.40 -0.65

     Nets:
player minutes orpm drpm rpm onet dnet net
Alan Anderson 15 -0.88 -1.64 -2.52 -0.28 -0.51 -0.79
Andray Blatche 6 -0.54 -0.04 -0.58 -0.07 -0.01 -0.07
Andrei Kirilenko 16 -0.72 1.16 0.44 -0.24 0.39 0.15
Deron Williams 36 4.69 -1.86 2.83 3.52 -1.40 2.12
Joe Johnson 41 3.39 -1.08 2.31 2.90 -0.92 1.97
Jorge Gutierrez 0 -2.11 -1.27 -3.38 0.00 0.00 0.00
Kevin Garnett 25 -2.86 6.57 3.71 -1.49 3.42 1.93
Marcus Thornton 10 -0.12 -1.96 -2.08 -0.03 -0.41 -0.43
Mason Plumlee 17 -0.90 -1.34 -2.24 -0.32 -0.47 -0.79
Mirza Teletovic 15 -0.28 -2.16 -2.44 -0.09 -0.68 -0.76
Paul Pierce 33 -0.62 3.14 2.52 -0.43 2.16 1.73
Shaun Livingston 26 -0.18 0.27 0.09 -0.10 0.15 0.05


R Script:

Show/Hide


library(XML)
library(RCurl)
v.pages <- 1:11            #change if increase in number of pages on http://espn.go.com/nba/statistics/rpm/_/page/1/sort/RPM

v.column.names <- c("player","team","orpm","drpm","rpm")
v.teams.home <- c("sas","okc","ind","mia")
v.teams.away <- c("por","lac","was","bkn")
v.teams <- c("sas","por","okc","lac","ind","was","mia","bkn")

hca <- 3.2                #difference between neutral court and home court; this is total hca adjustment, not the adjustment for each team
avg_eff <- 104            #average league points per 100 possessions

df.rpm <- data.frame(player=character(0),team=character(0),orpm=numeric(0),drpm=numeric(0),rpm=numeric(0))

for(page in v.pages)
{
    v.url.rpm <- paste("http://espn.go.com/nba/statistics/rpm/_/page/",page,"/sort/RPM",sep="")
    table <- readHTMLTable(v.url.rpm)[[1]]
    table <- table[as.character((table[,2]))!="NAME",]
    table2 <- cbind(as.data.frame(matrix(unlist(strsplit(as.character(table[,2]),", ")),ncol=2,byrow=TRUE),stringsAsFactors=FALSE)[,1], as.data.frame(matrix(unlist(table[,3]),ncol=1,byrow=TRUE),stringsAsFactors=FALSE), as.data.frame(matrix(unlist(table[,6]),ncol=1,byrow=TRUE),stringsAsFactors=FALSE),as.data.frame(matrix(unlist(table[,7]),ncol=1,byrow=TRUE),stringsAsFactors=FALSE),as.data.frame(matrix(unlist(table[,8]),ncol=1,byrow=TRUE),stringsAsFactors=FALSE))
    table2[,3] <- as.numeric(table2[,3])
    table2[,4] <- as.numeric(table2[,4])
    table2[,5] <- as.numeric(table2[,5])
    colnames(table2) <- v.column.names
    df.rpm <- rbind(df.rpm,table2)
}

#minutes distributions and individual xrapm:
df.sas.r2 <- data.frame(player=c("Tony Parker","Tim Duncan","Kawhi Leonard","Marco Belinelli","Boris Diaw","Danny Green","Manu Ginobili","Tiago Splitter","Patty Mills","Cory Joseph","Matt Bonner"),minutes=c(35,35,35,12,20,25,30,26,15,2,5))
df.sas.r2 <- merge(df.sas.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)
df.por.r2 <- data.frame(player=c("LaMarcus Aldridge","Nicolas Batum","Damian Lillard","Wesley Matthews","Robin Lopez","Mo Williams","Dorell Wright","C.J. McCollum","Thomas Robinson","Meyers Leonard","Joel Freeland"),minutes=c(40,40,40,38,37,25,10,3,5,0,2))
df.por.r2 <- merge(df.por.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)
df.okc.r2 <- data.frame(player=c("Kevin Durant","Serge Ibaka","Russell Westbrook","Reggie Jackson","Caron Butler","Thabo Sefolosha","Jeremy Lamb","Kendrick Perkins","Derek Fisher","Nick Collison","Steven Adams"),minutes=c(43,34,36,23,22,15,2,20,19,16,10))
df.okc.r2 <- merge(df.okc.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)
df.lac.r2 <- data.frame(player=c("Blake Griffin","DeAndre Jordan","Chris Paul","Jamal Crawford","J.J. Redick","Matt Barnes","Darren Collison","Jared Dudley","Danny Granger","Glen Davis","Hedo Turkoglu"),minutes=c(41,36,38,25,25,30,15,5,13,10,2))
df.lac.r2 <- merge(df.lac.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)
df.ind.r2 <- data.frame(player=c("Paul George","Lance Stephenson","George Hill","David West","Roy Hibbert","Evan Turner","C.J. Watson","Luis Scola","Ian Mahinmi","Chris Copeland"),minutes=c(40,35,37,36,32,14,18,10,14,4))
df.ind.r2 <- merge(df.ind.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)
df.was.r2 <- data.frame(player=c("John Wall","Trevor Ariza","Bradley Beal","Marcin Gortat","Nene Hilario","Martell Webster","Trevor Booker","Drew Gooden","Al Harrington","Andre Miller"),minutes=c(40,38,38,36,36,17,15,8,4,8))
df.was.r2 <- merge(df.was.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)
df.mia.r2 <- data.frame(player=c("LeBron James","Dwyane Wade","Chris Bosh","Mario Chalmers","Ray Allen","Norris Cole","Shane Battier","Chris Andersen","Rashard Lewis","Toney Douglas","Michael Beasley","Udonis Haslem","James Jones"),minutes=c(42,35,38,33,20,12,12,16,10,2,2,12,6))
df.mia.r2 <- merge(df.mia.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)
df.bkn.r2 <- data.frame(player=c("Joe Johnson","Deron Williams","Paul Pierce","Shaun Livingston","Marcus Thornton","Alan Anderson","Andray Blatche","Kevin Garnett","Mirza Teletovic","Andrei Kirilenko","Mason Plumlee","Jorge Gutierrez"),minutes=c(41,36,33,26,10,15,6,25,15,16,17,0))
df.bkn.r2 <- merge(df.bkn.r2, df.rpm[,c(1,3,4,5)], by="player", all.x=TRUE)

df.sas.r2$onet <- df.sas.r2$minutes * df.sas.r2$orpm / 48
df.por.r2$onet <- df.por.r2$minutes * df.por.r2$orpm / 48
df.okc.r2$onet <- df.okc.r2$minutes * df.okc.r2$orpm / 48
df.lac.r2$onet <- df.lac.r2$minutes * df.lac.r2$orpm / 48
df.ind.r2$onet <- df.ind.r2$minutes * df.ind.r2$orpm / 48
df.was.r2$onet <- df.was.r2$minutes * df.was.r2$orpm / 48
df.mia.r2$onet <- df.mia.r2$minutes * df.mia.r2$orpm / 48
df.bkn.r2$onet <- df.bkn.r2$minutes * df.bkn.r2$orpm / 48

df.sas.r2$dnet <- df.sas.r2$minutes * df.sas.r2$drpm / 48
df.por.r2$dnet <- df.por.r2$minutes * df.por.r2$drpm / 48
df.okc.r2$dnet <- df.okc.r2$minutes * df.okc.r2$drpm / 48
df.lac.r2$dnet <- df.lac.r2$minutes * df.lac.r2$drpm / 48
df.ind.r2$dnet <- df.ind.r2$minutes * df.ind.r2$drpm / 48
df.was.r2$dnet <- df.was.r2$minutes * df.was.r2$drpm / 48
df.mia.r2$dnet <- df.mia.r2$minutes * df.mia.r2$drpm / 48
df.bkn.r2$dnet <- df.bkn.r2$minutes * df.bkn.r2$drpm / 48

df.sas.r2$net <- df.sas.r2$minutes * df.sas.r2$rpm / 48
df.por.r2$net <- df.por.r2$minutes * df.por.r2$rpm / 48
df.okc.r2$net <- df.okc.r2$minutes * df.okc.r2$rpm / 48
df.lac.r2$net <- df.lac.r2$minutes * df.lac.r2$rpm / 48
df.ind.r2$net <- df.ind.r2$minutes * df.ind.r2$rpm / 48
df.was.r2$net <- df.was.r2$minutes * df.was.r2$rpm / 48
df.mia.r2$net <- df.mia.r2$minutes * df.mia.r2$rpm / 48
df.bkn.r2$net <- df.bkn.r2$minutes * df.bkn.r2$rpm / 48

#team-level xrapm
df.all.r2 <- data.frame(team=v.teams)
df.all.r2$onet <- as.vector(t(data.frame(sas=sum(df.sas.r2$onet),por=sum(df.por.r2$onet),okc=sum(df.okc.r2$onet),lac=sum(df.lac.r2$onet),ind=sum(df.ind.r2$onet),was=sum(df.was.r2$onet),mia=sum(df.mia.r2$onet),bkn=sum(df.bkn.r2$onet))))
df.all.r2$dnet <- as.vector(t(data.frame(sas=sum(df.sas.r2$dnet),por=sum(df.por.r2$dnet),okc=sum(df.okc.r2$dnet),lac=sum(df.lac.r2$dnet),ind=sum(df.ind.r2$dnet),was=sum(df.was.r2$dnet),mia=sum(df.mia.r2$dnet),bkn=sum(df.bkn.r2$dnet))))
df.all.r2$net <- as.vector(t(data.frame(sas=sum(df.sas.r2$net),por=sum(df.por.r2$net),okc=sum(df.okc.r2$net),lac=sum(df.lac.r2$net),ind=sum(df.ind.r2$net),was=sum(df.was.r2$net),mia=sum(df.mia.r2$net),bkn=sum(df.bkn.r2$net))))
df.all.r2$home_perc <- (avg_eff+df.all.r2$onet+hca/4)^14/((avg_eff+df.all.r2$onet+hca/4)^14+(avg_eff-df.all.r2$dnet-hca/4)^14)
df.all.r2$away_perc <- (avg_eff+df.all.r2$onet-hca/4)^14/((avg_eff+df.all.r2$onet-hca/4)^14+(avg_eff-df.all.r2$dnet+hca/4)^14)

#specific round 2 matchups
df.r2.matchups.1 <- data.frame(team=v.teams.home, opponent=v.teams.away, stringsAsFactors = FALSE)
df.r2.matchups.1$team_home_perc <- merge(data.frame(team=df.r2.matchups.1$team),df.all.r2[,c(1,5)], by="team", all.x=TRUE, sort=FALSE)[,2]
df.r2.matchups.1$team_away_perc <- merge(data.frame(team=df.r2.matchups.1$team),df.all.r2[,c(1,6)], by="team", all.x=TRUE, sort=FALSE)[,2]
df.r2.matchups.1$opponent_home_perc <- merge(data.frame(team=df.r2.matchups.1$opponent),df.all.r2[,c(1,5)], by="team", all.x=TRUE, sort=FALSE)[,2]
df.r2.matchups.1$opponent_away_perc <- merge(data.frame(team=df.r2.matchups.1$opponent),df.all.r2[,c(1,6)], by="team", all.x=TRUE, sort=FALSE)[,2]
df.r2.matchups.1$team_matchup_home_perc <- (df.r2.matchups.1$team_home_perc - (df.r2.matchups.1$team_home_perc*df.r2.matchups.1$opponent_away_perc))/(df.r2.matchups.1$team_home_perc + df.r2.matchups.1$opponent_away_perc - (2*df.r2.matchups.1$team_home_perc*df.r2.matchups.1$opponent_away_perc))
df.r2.matchups.1$team_matchup_away_perc <- (df.r2.matchups.1$team_away_perc - (df.r2.matchups.1$team_away_perc*df.r2.matchups.1$opponent_home_perc))/(df.r2.matchups.1$team_away_perc + df.r2.matchups.1$opponent_home_perc - (2*df.r2.matchups.1$team_away_perc*df.r2.matchups.1$opponent_home_perc))
df.r2.matchups.1$series_perc <- df.r2.matchups.1$team_matchup_home_perc^4 + 4*df.r2.matchups.1$team_matchup_home_perc^3*(1-df.r2.matchups.1$team_matchup_home_perc)*(1-(1-df.r2.matchups.1$team_matchup_away_perc)^3) + 6*df.r2.matchups.1$team_matchup_home_perc^2*(1-df.r2.matchups.1$team_matchup_home_perc)^2*((3*df.r2.matchups.1$team_matchup_away_perc^2*(1-df.r2.matchups.1$team_matchup_away_perc))+df.r2.matchups.1$team_matchup_away_perc^3)+4*
df.r2.matchups.1$team_matchup_home_perc*(1-df.r2.matchups.1$team_matchup_home_perc)^3*df.r2.matchups.1$team_matchup_away_perc^3
df.r2.matchups.2 <- df.r2.matchups.1[,c(2,1)]
colnames(df.r2.matchups.2) <- c("team","opponent")
df.r2.matchups.2$team_home_perc <- df.r2.matchups.1$opponent_home_perc
df.r2.matchups.2$team_away_perc <- df.r2.matchups.1$opponent_away_perc
df.r2.matchups.2$opponent_home_perc <- df.r2.matchups.1$team_home_perc
df.r2.matchups.2$opponent_away_perc <- df.r2.matchups.1$team_away_perc
df.r2.matchups.2$team_matchup_home_perc <- 1-df.r2.matchups.1$team_matchup_away_perc
df.r2.matchups.2$team_matchup_away_perc <- 1-df.r2.matchups.1$team_matchup_home_perc
df.r2.matchups.2$series_perc <- 1-df.r2.matchups.1$series_perc
df.r2.matchups <- rbind(df.r2.matchups.1,df.r2.matchups.2)
df.r2.matchups <- df.r2.matchups[order(df.r2.matchups$series_perc, decreasing=TRUE),]



#print results
df.r2.matchups
df.all.r2[order(df.all.r2$net,decreasing=TRUE),c(1:4)]
df.sas.r2
df.por.r2
df.okc.r2
df.lac.r2
df.ind.r2
df.was.r2
df.mia.r2
df.bkn.r2

10 comments:

  1. Game 1 Bets:
    WAS +4 (Adj Model: WAS +1.5, Game Result: WAS -6, Confidence: 2.5, Bet Result: 10)
    LAC +5 (Adj Model: LAC +0, Game Result: LAC -17, Confidence: 5, Bet Result: 22)

    Vegas Game 2 lines for 5/7:
    IND -4.5 (-105) / WAS +4.5 (-115)
    IND -190 / WAS +165

    OKC -5.5 (-105) / LAC +5.5 (-115)
    OKC -235 / LAC +195

    From the first round, it appears that after the home team loses Game 1, the standard is for the Game 2 line to move 0.5 points in favor of the home team (sometimes 1 point, sometimes 0 points). Given that each of these games follows this same practice, not much has changed. As a result, I would continue betting the Wizards and Clippers.

    ReplyDelete
  2. Vegas Game 2 lines for 5/8:
    MIA -7 / BKN +7
    MIA -400 / BKN +300

    SAS -6.5 (-105) / POR +6.5 (-115)
    SAS -275 / POR +235

    Hard to make too many conclusions off of the Game 1 blowouts, as both road teams appeared to just play poorly. As a result, I would still abstain from both games.

    ReplyDelete
  3. Vegas Game 3 lines for 5/9:
    IND +5 (-115) / WAS -5 (-105)
    IND +170 / WAS -200

    OKC +4 / LAC -4
    OKC +155 / LAC -175

    Both spreads moved the same relative to their Game 2 counterparts, but much more than just HCA would suggest (9.5 vs. 6.5). Given that the Clippers got blown out in Game 2, I would guess that there wasn't any significant adjustment by Vegas in the Clippers' favor (and, similarly, no significant adjustment in the Wizards' favor). I would bet the Clippers regardless, given that my pre-series expected margin of victory for the Clippers at home was 6.5 (and the Game 3 margin might be larger if there's some series-state factor that caused these lines to shift so much from Game 2). The Wizards bet is a little more questionable, given that my pre-series expected margin of victory for the Wizards at home was 5. However, I'm more enthusiastic about the Wizards chances now given their success defensively in the first two games (and in the series against the Bulls). As a result, I would still bet both the Wizards and Clippers.

    ReplyDelete
  4. Vegas Game 3 lines for 5/10:
    MIA -2.5 (-105) / BKN +2.5 (-115)
    MIA OFF / BKN OFF

    SAS -1.5 (-105) / POR +1.5 (-115)
    SAS OFF / POR OFF

    I'm less enthusiastic about Brooklyn and Portland than I was before given that many of the matchup worries for Miami and San Antonio have not been issues. However, I'm not sure how much to adjust for the 2-0 series scores. Given that the lines moved 4.5 and 5 points respective from the Game 1 line, I would still abstain from both games.

    ReplyDelete
  5. Vegas Game 4 lines for 5/11:
    OKC +5 (-115) / LAC -5 (-105)
    OKC +180 / LAC -220

    IND +4 / WAS -4
    IND +160 / WAS -180

    Even after Game 2 and 3 losses, I'm not overly concerned about the Clippers. Yes, they are some matchup/rotation issues, mostly with regards to their bench. Dudley can't guard Durant, Collison can't guard anyone (and is horrible offensively as well), and Griffin can't post up against Ibaka (which is somewhat surprising if you ignore their regular season matchups given that Ibaka generally has issues defending bullying post players) or Perkins (not as surprising). I would much rather have Granger guard Durant than Dudley, and to avoid that scenario as much as possible, I would try to match Barnes' minutes with Durant as much as possible. I would also much rather Collison not play at all; throughout the playoffs, Doc has seemed inflexible about a) always having a "pg" in the game at all times, and b) using almost-hockey substitutions and the 10-man rotations that result. Collison can't guard anyone in this series, and while on-ball PG defense is often overrated, he's so bad that Westbrook/Jackson isos are consistently resulting in layups or double teams, which is especially bad because those isos require no offensive execution and allows the Thunder to do what they do best (attack one-on-one instead of actually running plays). Offensively, he's basically the Marreese Speights of the Clippers; he'll shoot any 20-footer he can get, even if it comes with 15 seconds on the shot clock, and this is especially egregious in this series given the higher opportunity cost (the offenses are significantly better than the defenses for both sides). Ideally, Crawford would serve as the pg in the 8 or so minutes Paul is on the bench, but I wouldn't be overly upset about Collison playing those minutes as Paul's backup. However, he should never be on the floor with Paul, as whatever advantages he does bring (ball handling for the bench unit) is useless alongside Paul, and his defensive shortcomings and horrible shot selection are even more egregious. Doc inexplicably loves playing the trio of Paul-Collison-Crawford, and that should really be replaced by Paul-Redick-Crawford. This wasn't meant to be a long rant about Collison, but rather an indication that the Clippers may have realized what their biggest weaknesses are given that Collison only played 10 minutes in Game 3. Furthermore, while there were still some inexplicably lazy Griffin postups in Game 3 that were predictably unsuccessful (on a side note, Doc looks more and more like Mark Jackson given the hockey-like substitutions and dependence on isos despite some of the most unguardable pick-and-roll players in the game), Griffin appeared to face up a lot more in that game, and doing so makes it harder for Ibaka to time his moves for shot blocks. Add to all of that the part where Ibaka is not likely going to shoot something like 9 for 9 on open elbow jumpers in most games, I would still feel comfortable betting the Clippers.

    ReplyDelete
  6. cont.

    The Washington-Indiana series is a different story. I've dismissed all of the obsession over Hibbert's scoring/rebounding numbers because he's never been a significant offensive force anyways and his rebounding impact is more about eating space/boxing-out so his teammates (like rebound-stealer Lance) can get the rebounds. For example, in Game 1, Hibbert had 0 rebounds while Drew Gooden had 14 but Hibbert only had 3 rebounding chances while Gooden had 18 (this still isn't flattering for Hibbert of course). However, higher scoring/rebounding numbers might often be a manifestation of higher energy levels (and the offensive involvement might even cause him to be more active), and higher defensive intensity would be where Hibbert can really make an impact. After un-Pacers-like defensive performances throughout the first round and the first game of this series (in fairness, the Atlanta series was a bad matchup for Indiana's defense), Indiana has totally stifled Washington's offense. In Game 3, they mostly forced the Wizards into tough midrange jumpers (whenever the Wizards weren't turning it over), and if that persists, Washington has no chance. It's difficult to overlook 3 months of lackadaisical effort after 2 games, but at the same time, this could be a new Pacers team (who would actually be the old Pacers team). There is also very flimsy evidence that Vogel might have realized that Evan Turner is the Darren Collison of the Pacers (the Marreese Speights of the Clippers of the Pacers), as Turner played significantly less in Game 2 than in Game 1 (before playing 18 minutes again in Game 3's blowout). Point is, I now believe that the Pacers are the better team on a neutral court and I have a difficult time believing Washington should be a 4-point favorite at home (even given that they lost Game 3 and are now down 2-1). My rough subjective estimate at what the line should be is Washington by 3, but that comes with a significant amount of uncertainty in the adjustments. As a result, I would abstain from this game.

    ReplyDelete
  7. Vegas Game 4 lines for 5/12:
    MIA -3 / BKN +3
    MIA OFF / BKN OFF

    SAS -5 / POR +5
    SAS -190 / POR +165

    I would still abstain from both series.

    ReplyDelete
  8. Vegas Game 5 lines for 5/13:
    IND -5.5 (-105) / WAS +5.5 (-115)
    IND -230 / WAS +190

    OKC -5 / LAC +5
    OKC -230 / LAC +190

    Yes, the Hibbert effect is back (John Wall has had a horrendous series) and OKC's issues from Game 4 are clearly fixable (and Darren Collison's "success" in that game bodes well for the Thunder going forward), but both of these lines seem high for the home teams. As a result, I would bet the Wizards and Clippers.

    ReplyDelete
  9. Vegas Game 5 lines for 5/14:
    MIA -7 / BKN +7
    MIA -340 / BKN +270

    SAS -8 (-115) / POR +8 (-105)
    SAS -400 / POR +300

    I would still abstain from both series

    ReplyDelete
  10. Vegas Game 6 lines for 5/15:
    IND +4 (-115) / WAS -4 (-105)
    IND +150 / WAS -170

    OKC +4.5 (-115) / LAC -4.5 (-105)
    OKC +165 / LAC -190

    These lines are very similar to Game 4's so I would still bet the Clippers and abstain from the Pacers-Wizards.

    ReplyDelete