ZhongJunJimmy / Basic-K-means

This is a basic k-means sample code.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Basic-K-means

This is a basic k-means sample code.
When you run this code, you need to install numpy and matplotlib.

Introduce

Step 1:
    Clustering by Vertical bisector.
Step 2:
    Clustering by Euler's formula in while loop. When centroid points stop to update the position, break the loop.
Step 3:
    Print the result.

Result Figure

image

About

This is a basic k-means sample code.


Languages

Language:Python 100.0%