From the course: Data Science Foundations: Data Mining in R

Unlock the full course today

Join today to access over 22,400 courses taught by industry experts or purchase this course individually.

Challenge: K-means

Challenge: K-means

From the course: Data Science Foundations: Data Mining in R

Start my 1-month free trial

Challenge: K-means

(upbeat music) - [Instructor] Now that we've covered several ways of clustering data, I want to give you a challenge and invite you to do some clustering of your own. The method we're going to use is K means. And so this is the one where you specify in advance how many clusters you're looking for. And for this example we're going to use an extremely well-known dataset that comes from the R built in datasets package. So let's load all of these including datasets, and then we'll use the Iris dataset. It's been used millions of times. Let's get a little bit of information on this. And what this is is Edgar Anderson's or Ronald Fisher's Iris Data. It's the measurement in centimeters of several different species of Iris flowers. We can take a look at the first few lines. What we have are the sepal length and sepal width, the petal length and the petal with, and then the species. And we can get the entire summary statistics.…

Contents