Week 11: Unsupervised Learning I
We now study structure in the predictors without using an outcome to guide the analysis. Principal component analysis summarizes variation in fewer dimensions. K-means and hierarchical clustering group observations according to their similarities.
Guiding question: What structure can we learn from the predictors alone?
The discussion of Week 10 is Tuesday, November 3, 2026. The Unsupervised Learning I lecture is Thursday, November 5, 2026, and its discussion session is Tuesday, November 10, 2026.
Learning goals
By the end of this week, you should be able to:
- interpret principal-component directions, scores, and explained variation;
- connect PCA to singular value decomposition and explain the effects of centering and scaling;
- describe the K-means objective and its assignment and center-update steps;
- explain why initialization and the number of clusters affect a K-means fit; and
- interpret a dendrogram and compare hierarchical linkage rules.
Lecture notes
-
Projection, SVD, centering, scaling, and visualization using iris and handwritten digits. This develops the PCA preprocessing used in Homework 10.
-
Cluster assignments, center updates, and random initialization, followed by iris clustering and image color compression.
-
Distance, linkage, and dendrograms, with iris and gene-expression heatmap examples.
Homework 11
Homework 11 has three questions. Implement K-means, use your implementation to compress an image’s colors, and compare hierarchical clustering methods on car data. Use either R or Python. Homework is evaluated as Complete or Incomplete.
Solutions will be available after Monday, November 9, 2026.
Place homework-11.pdf or homework-11.html in the homework/week-11/ folder of your stat432-fall2026 GitHub repository by Sunday, November 8, 2026, at 11:59 p.m. Central Time. The report must be either a PDF or a self-contained HTML file and must not exceed 10 pages. The final file version shown on GitHub is treated as the submitted version, and its GitHub timestamp determines whether it is on time.
Discussion
Tuesday, November 10, 2026
Submit discussion/week-11-question.md by Sunday, November 8, 2026, at 11:59 p.m. Central Time. This required weekly discussion question counts toward the Weekly GitHub Discussion Questions component, worth 10% of the course grade.
The final version shown on GitHub is the submitted version. If its GitHub timestamp is after the deadline, the submission receives 0 points. No late-submission exceptions are allowed.
For the required format and GitHub submission steps, see Discussion Questions: Procedures and Rules.
The Week 11 discussion session is Tuesday, November 10, 2026. Open Popping when the instructor asks you to join.
See the Discussion tab for login information. Tell the instructor during class if you cannot sign in.
Week 11 is included in Quiz 4 on Tuesday, November 17, 2026, which covers the Week 9 through Week 11 discussions. See Quizzes for the quiz format.
Discussion Question Topics
The following topics are suggestions. Your question is not limited to this list, but it should relate to the Week 11 material.
PCA and useful information. Retaining variation can simplify an analysis while discarding information important for grouping or prediction.
Similarity and scaling. Variable choice, scaling, and distance determine what it means for observations to be close.
K-means optimization and initialization. Different starts can reach different solutions, so convergence alone does not guarantee the smallest objective value.
Choosing and evaluating clusters. A smaller within-cluster sum of squares does not alone justify more clusters; stability and interpretation also matter.
Comparing clustering methods. K-means and hierarchical linkage rules respond differently to cluster shape and unusual observations.
AI-assisted implementation and diagnostics. Checking assignments, center updates, and stopping rules helps distinguish coding errors from limitations of the method.
Ask one focused question that calls for an explanation, a comparison, a short derivation, a counterexample, a small computation, or a diagnosis of a concrete difficulty. Do not submit a request for code alone or repeat a homework calculation without asking about the statistical reasoning or the specific difficulty you encountered.