P23 · due at the start of Class 23, Tue, Mar 23
Classification and a leakage audit
ClassificationProjectBuild B-11
A classifier on project or open data with confusion matrix, precision and recall, plus the written leakage audit the book asks of every project.
Chapter 11: Is the Change Real? Statistics and Machine Learning · Week 11 hub
Book exercises
Course Guide: Classification and a leakage audit
- Exercise 11.11 CORE Python analysis, 20 min
Edit code/typical_error.py (Listing 11.1) to read the day-1 and day-2 heights of Exercise 11.5 and a change of 1.5 cm. Before running it, write down the three chances you expect from your hand… - Exercise 11.19 CORE Build, 75 min
B-11: a baseline on the device. Add to your app a page that: steps lets the athlete enter (or load from a results file) one number per session, with a date, and stores the list with saveSession from… - Exercise 11.20 CORE Communicate, 20 min
Riley's jump went from 30.4 to 30.9 cm after four weeks of training. The class typical error is 0.89 cm and the SWC is 0.65 cm (chances: 45% worthwhile gain, 37% trivial, 18% loss). Write the message… - Exercise 11.21 Check the AI, 8 min
A student asked an AI assistant to compute a typical error from the five pairs of Table 11.1. The answer: quote“The differences are $+1.0, -1.4, +1.1, -0.5, +1.6$, with standard deviation 1.26 cm.… - Exercise 11.29 Python analysis, 25 min
Use the synthetic accelerometer windows of Listing 11.19 for all three classes. parts Fit LogisticRegression(max_iter=1000) to predict the class (walk, jog or run), with GroupKFold(4) by person and… - Exercise 11.32 Python analysis, 40 min
Case file: your case-file athlete's chest-strap interval sessions (see apopt.com/data/athletes), or the instructor's case file. parts For each session, find each repeat's one-minute recovery as in…
Prepare with these tutorials
- Q-32 Split by athlete, not by row (quick tutorial, 15 min)
- CS-16 Forecast next week, and beat "same as last week" (case study, 60 min)
Two paths, same skills
Course data
Use the files below. The instructor's own data is the default.
Your own data
Any watch, phone, video or chest-strap recording of your own works in place of the course data. It stays on your device. How to collect it.
book
Book data, Chapter 11: Is the Change Real? Statistics and Machine Learning
The 10 example files that Chapter 11 of Data-Driven Athletics reads, under the same names the listings use.
open
Injury prediction in competitive runners (Lövdal et al.)
Daily and weekly training logs with injury labels for a Dutch high-level running team; two CSV files of 13–15 MB.
Build step
B-11 is part of this assignment.
What to turn in
- A notebook (or app) that runs top to bottom, reading the data by its address or from a file you include.
- The answer to the task, with units and how sure you are.
- One paragraph for the athlete or coach: what to do, and the limit of the finding.
- Your AI-use statement and the verify-it checklist (how).
Scoring
| Method and correctness | 40% |
| Reproducibility and data handling | 25% |
| Interpretation and limitations | 25% |
| Presentation and AI disclosure | 10% |