From the course: Machine Learning with Data Reduction in Excel, R, and Power BI
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Determining k
From the course: Machine Learning with Data Reduction in Excel, R, and Power BI
Determining k
- [Instructor] We can create an elbow chart visual like the one we see on the screen to determine the number of clusters we want to use in our KMeans algorithm. On the X axis, we see the number of clusters K and on the Y axis, we see the change in SSE or the standard square distance between each iteration of K clusters in the model. We can see there's a kink in the elbow chart where the rate of changing variants gets substantially lower. This is the ideal number of clusters we want to use in our model. In our studio, let's start by creating an elbow chart by first creating a new vector we'll call K and will assign the values from one to 20 within it. This new vector contains K values from one to 20 but notice we're not going up to 25 which is the limit of the number of clusters with 25 cities. We're not going up to 25 because that doesn't work in the algorithm. And we'll also see the kink occurs before then. Let's also…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
(Locked)
Calculating distances7m 50s
-
(Locked)
Hierarchical clustering9m 6s
-
Heatmaps and dendrograms6m 30s
-
(Locked)
K-means clustering in one dimension9m 55s
-
(Locked)
K-means clustering in two dimensions5m 37s
-
(Locked)
Determining k9m 8s
-
(Locked)
Challenge: Clustering44s
-
(Locked)
Solution: Clustering8m 57s
-
(Locked)
-
-
-
-