The document presents a Python script that performs K-means clustering on the Iris dataset using the scikit-learn library. It scales the data, fits a K-means model with three clusters, and visualizes the results with scatter plots showing the clusters and their centroids. The plots illustrate the relationship between sepal length and width for the different iris species.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
5 views2 pages
Kmeans
The document presents a Python script that performs K-means clustering on the Iris dataset using the scikit-learn library. It scales the data, fits a K-means model with three clusters, and visualizes the results with scatter plots showing the clusters and their centroids. The plots illustrate the relationship between sepal length and width for the different iris species.