Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

horaceheqi/k-means

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

6 Commits

Repository files navigation

K-Means

K-Means Clustering Algortihm

General description

This code is a Python implementation of k-means clustering algorithm.

Input

A list of points in the plane where each point is represented by a latitude/longitude pair.

Output

The clusters of points.

Technical details

This project is an implementation of k-means algorithm. It starts with a random point and then chooses k-1 other points as the farthest from the previous ones successively. It uses these k points as cluster centroids and then joins each point of the input to the cluster with the closest centroid. Next, it recomputes the new centroids by computing the means of obtained clusters and repeats the first step again by finding to which cluster each point belongs. The program repeats these two steps until the clusters converge and do not change anymore. View the following link to read more about this project and see some real examples of running k-means algorithm:

http://www.kazemjahanbakhsh.com/codes/k-means.html

About

A Python implementation of k-means clustering algorithm.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

Contributors

Languages

  • Python 100.0%

AltStyle によって変換されたページ (->オリジナル) /