课程: R for Data Science: Lunch Break Lessons

免费学习该课程!

今天就开通帐号,24,100 门业界名师课程任您挑!

Understanding silhouette graphs

Understanding silhouette graphs

- [Instructor] Last week, I mentioned the silhouette graph and said I would come back to it to explain it in more detail, and so let's spend some time this week talking about this very useful graph in the clustering world. The functions in the cluster library provide the silhouette graph, and it measures the quality of the cluster that's created. So using a silhouette graph, you can adjust your parameters to come up with tighter clusters. Let's take a look at this. The first thing you'll need to do is bring in the cluster library, and you can see I've done that in line two. I'll hit run. And then, I've created a vector called simpleQuakes, which is a sampling of quakes. It's only 25 observations long, but for the sake of demonstration here, it makes things much easier. So I'm going to go ahead and run that and create simpleQuakes. Let's create a silhouette graph. S-I-L-H-O-U-E-T-T-E. And we're going to…

内容