In this fall term, we start a reading course about sports analytics. We read through the textbook "Handbook of Statistical Methods and Analyses in Sports" from Chapter 9-12, and quickly go over the first 12 chapters of "Bayesian Data Analysis".
The notes could be found in Reading Notes.
Also, the project specifically focuses on the Chapter 12 of the HSMAS, about fitting the intensity surface for player's shots and typifying players based on the surface, is created in the last few weeks.
The code for fitting the intensity surface is modified from the Github Repo flecks, contributed by one of the authors of the chapter, Andrew Miller.
However, the fitted surfaces are still problematic, since the intensity surface around the three point line is hard to converge. The current progress can still be viewed in the notebook Project.
We might continue to make the fitting process work in the next few weeks. Besides, the next step of this interesting project will be discussed later.
The goal of the case study is to use HMM for modelling basketball data and provide useful insights, advised by Professor Vianey Leos Barajas.
The textbook we use is "Hidden Markov Models for Time Series: An Introduction Using R".
Identify the 3pt shooting together with long pass. Consider the dribble, and other complex basketball events.
(a) Idetify the long pass and 3pt shooting.
The data is obtained from this repo, Credit: @sealneaward and @neilmj
The additional preprocessing codes are written in python (preprocess data), including swithcing the player name and creating speed.
The analysis part are written in R and R Studio, the pdf file is here: Identify long pass and 3pt shooting.
Two gif plots are made for the identification respectively, pass and 3pt shooting.
(b) Identify the layup following other's case.
The codes are written in R and R Studio, the pdf file is in the same location: Identify the Layup by HMM.
Reference: Tagging Basketball Events with HMM in stan
(c) Writing codes for simulating a simple basketball game (leading or falling behind, and what are the strategies under these cases) by HMM.
The codes are written in R and R Studio Simple Basketball Game Simulation by HMM, and the report can be found here.
End up reading the textbook chapter 1-5, and make notes for summarizing the key points in the textbook.
The notes can be found in HMM Notes.