Unsupervised Machine Learning (KMeans Clustering) with Scikit-Learn

Machine learning can be divided into two main categories, supervised machine learning and unsupervised machine learning. In supervised machine learning, we initially provide the data with it's corresponding label to train the model, with the trained model we can find the label for new data. But in unsupervised machine learning, we throw the data to the model without any labeling, the model will find patterns in the data. In Unsupervised machine learning we can't find the class of the data, but instead, we can group the data points that are similar, this process is known as clustering. There are number of clustering algorithms, in this article I will talk about KMeans Clustering . How KMeans Clustering work ? Let's understand this step by step, with the below image. Step (a) - Unsupervised Initial Data Step (b) - Choose random initial centroids (centroids are the center of the clusters.) , In this example we need to separate the data set into ...