Using ELO Ratings with Scoring Differential in R

556 Views Asked by At

I've been playing around with the EloRating package to generate ELO Ratings for basketball teams. The only issue is that this package (to my knowledge) only uses whether a team wins or loses (I understand this is standard). I know ESPN uses point differential to weight the change in a team's ELO score. Does anyone know of an R package that already does this, or will I have to create my own functions?

Below is an extract of the data I'm using to calculate the ELO scores. I have the season of a given matchup, the winning team ID, losing team ID, winning team score, losing team score, and the date of the matchup. The EloRating package has a function to calculate these scores called "elo.seq", but this only takes the winning team ID, losing team ID and date. It does not deal with the score of the game. Nate silver wrote about how he calculates ELO ratings here.

    Season WTeamID LTeamID WScore LScore       date
     <int>   <int>   <int>  <int>  <int>     <date>
 1   2017    1104    1157     70     53   2016-11-11
 2   2017    1107    1336     87     81   2016-11-11
 3   2017    1112    1277     65     63   2016-11-11
 4   2017    1113    1340     88     70   2016-11-11
 5   2017    1116    1236     92     83   2016-11-11
 6   2017    1120    1316     83     66   2016-11-11
1

There are 1 best solutions below

0
On

There are at least 2 R packages that compute Elo ratings:

elo and EloRating