Below is the code for the Buckets Model, inclusive of latent profile analysis of the spatial distributions of offensive effeciancy and defensive points allowed around the NBA court. Such latent groups are used in generalized logistic mixed modeling to predict one-match ahead results for NBA games between 2009 and 2020.
To properly reliplicate resutls, clone project and run model_prep.py followed by lpa.Rmd. Other scripts are will be run using only these two steps.