Skip to content

LeSingh1/edge-nba

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

edge-nba

NBA player prop projection model. One of the edge-models family.

Give it a player's recent game log and a betting line. It returns a calibrated probability that the player goes over, plus a quarter Kelly stake. Trained on 16.0M synthesized lines pulled from real NBA game logs.

Results

Held out test split (3.22M rows that the model never trained on):

accuracy brier log loss baseline lift
88.3% 0.084 0.280 0.290 +3.3%

Lift is how much lower the calibrated log loss is than a no-skill baseline (0.010 absolute, 3.3% relative). The hardest market I model. NBA props are sharp and heavily bet, so after the book's cut the calibrated lift is only a few percent. Honest answer: most NBA props are close to a coinflip and I would not lean hard on them.

Run it

git clone https://github.com/LeSingh1/edge-nba
cd edge-nba
node src/predict.js --stat "Points" --line 24.5 --log 27,19,31,22,28

Output is the projection, the raw over probability, the calibrated probability, and a suggested stake.

How it works

  1. Weight the recent games up and fit a mean and standard deviation.
  2. Turn the line into a raw over probability with a normal model.
  3. Correct that probability with the trained isotonic calibrator in models/calibration.json. The correction is clamped to +/-0.20 so a thin bucket cannot fake confidence.
  4. Size the bet with quarter Kelly.

The calibrator is keyed by stat type, so "Points" gets a different correction than other stats.

What is not here

The scraping pipeline and the raw training rows live in the private app this came out of. This repo ships the trained model and the code to run it, which is the useful part.

License

MIT. Not financial advice. The house edge is real, bet responsibly.

About

NBA player prop projection model (isotonic calibration + EV)

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors