Save this video free

UUtah Fall 2026 | Data Mining | L4 - Metric Distances

UofU Data Science · 1:19:35 · Watch on YouTube

Part of University of Utah CS 5140/6140 Data Mining. See all 21 lectures and search them

These notes were made with YouTube Collector. Paste any YouTube link and get the same: a summary, chapters and a searchable transcript.

Overview

Metric distances are modeling choices in data mining: they define which data points count as close, affect algorithm behavior, and can change project outcomes. The lecture develops the metric axioms and the Lp family (including Euclidean L2, Manhattan L1, and maximum-coordinate L∞), then introduces Mahalanobis distance for feature weighting and cosine-based measures for embeddings, distinguishing cosine distance from the angular metric.

Key takeaways

Chapters

0:00 Why Distance Is a Data-Mining Modeling Choice
3:42 Representing Data and Defining a Distance Function
8:00 Euclidean Distance Between Two-Dimensional Points
11:04 The Four Axioms of a Metric
16:42 Relaxed Metrics: Collisions and Directional Travel Costs
22:32 The Lp Distance Family and Its General Formula
25:39 L2 Euclidean and L1 Manhattan Distances
28:28 L∞ Distance as the Largest Coordinate Difference
32:12 Distance Units and Lp Balls in Two Dimensions
37:22 Lp Ball Geometry and Why p Below 1 Fails
48:21 Why Feature Units Matter: Height and Weight
53:56 Mahalanobis Distance for Feature Scaling and Weighting
57:41 Identity, Diagonal Weights, and Correlated Features
1:05:21 Cosine Distance and Cosine Similarity for Embeddings
1:08:39 Why Angular Distance Is a Metric on the Unit Sphere

Keep these chapters and the full searchable transcript in your own library.

Transcript excerpt

0:20 That's great. Let's get started. Um, so today we'll be talking about distances and so specifically like metric distances. Um so the main point of this lecture is that the the um when you're doing data mining and you can't do supervised machine learning the distance is part of the input or something like the distance. All right. So and so that means this choice this distance is going to be a choice. >> Okay. So you will get to choose the distance. Um so sometimes in the modeling part so this will be one of your tools for modeling will be the choice of the

1:08 distance. Now we'll usually default to a fairly standard distance and so we will mostly talk about um so those things today. There are some very common choices. This is often implicit. It's not often said but you should be conscious of this choice. and then we'll see throughout the semester uh ways to make this choice. Um so just to get started, we're starting we're in like the similarity and distance part of the semester. We'll also talk about notions called similarities instead of distances. This is a very similar concept. It's kind of like the inverse, but it's another modeling choice. And the next

1:58 kind of um two lectures in this space will be about how to compute quickly with these distances. how what are some very basic things to do with them. Um but it'll kind of be a lot of modeling in this section and we'll see some algorithms uh but it won't um yeah but this is I think it often underated and under kind of uh um emphasized part of data mining and we're going to in this class we're going to make sure that we emphasize it. It's coming. It's kind

This is the start of the transcript. Save this video free for the whole transcript, searchable and time-coded.

In this course

Related notes

Summary, takeaways, and chapters were generated by AI from the video's transcript and may contain errors. The video belongs to its creator, UofU Data Science.

Want the full transcript?

Save this video in YouTube Collector to get its complete searchable transcript, your own AI summaries, and a library that keeps every video you collect in one place.