Machine LearningIntermediate

Unsupervised Learning: Clustering and Dimensionality Reduction

K-means, DBSCAN, PCA, t-SNE and anomaly detection.

Taught by Bibek Sharma · Data Scientist

What you'll learn

  • Segment a customer dataset with k-means and choose k using the elbow and silhouette methods
  • Apply hierarchical clustering and read a dendrogram to decide where to cut
  • Use DBSCAN to find arbitrarily shaped clusters and label noise points
  • Reduce dimensionality with PCA, interpret explained variance and reconstruct data
  • Visualise embeddings and high-dimensional data with t-SNE and UMAP without over-reading the plot
  • Build an anomaly detector with Isolation Forest and set a threshold that fits the business cost

About this course

Most of the data in the world has no labels, and unsupervised learning is how you make sense of it. This hands-on course teaches the techniques data scientists reach for when the question is what structure is in here rather than what is the answer. You will segment customers with k-means and hierarchical clustering, find dense regions and outliers with DBSCAN, compress hundreds of features into a few informative components with PCA, visualise high-dimensional embeddings with t-SNE and UMAP, and build anomaly detection systems with Isolation Forest. Every method is implemented in scikit-learn on realistic data, with guidance on choosing the number of clusters, validating results without ground truth and explaining findings to non-technical colleagues. It is for analysts, developers and data scientists who already know basic Python and pandas and want to add customer segmentation, anomaly detection and dimensionality reduction to their toolkit.

Course content

7 lessons
  1. 1Learning Without LabelsWhat unsupervised learning can and cannot tell you, the main task families, and how to prepare data for them.Preview
  2. 2K-Means Clustering and Choosing kRun k-means, understand its assumptions, and pick the number of clusters with elbow and silhouette scores.
  3. 3Hierarchical Clustering and DendrogramsBuild a tree of clusters with agglomerative clustering, read the dendrogram, and compare linkage methods.
  4. 4DBSCAN: Density, Shapes and NoiseFind clusters of any shape and label outliers with DBSCAN, and tune eps with a k-distance plot.
  5. 5Principal Component AnalysisCompress many features into a few components, read explained variance, and use PCA before clustering.
  6. 6Visualising High-Dimensional Data With t-SNE and UMAPProject embeddings and feature vectors into two dimensions for exploration, and avoid the classic misreadings.
  7. 7Anomaly Detection in PracticeDetect outliers with Isolation Forest and Local Outlier Factor, set thresholds and evaluate without full labels.