Skip to content

Utwo/K-Means

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

K-Means implementation in javascript es6

Here are the steps:

  1. Initialization: Create N nodes (circle) and randomly put initial K cluster (cross).
  2. Assignment step: Assign each node (circle) to the nearest cluster (cross).
  3. Update step: Each cluster (cross) move to the centroid of its nodes.
  4. Go to step 2.

Run

For running this project, just download the repo and open index.html in your browser. No npm install needed, no node involved.

This project make use of bootstrap from CDN for theming and babel-standalone CDN for transpiling javascript es6 to es5.

Config

Check out index.js for configuration variables.

NUM_CLUSTERS = Number of clusters

NUM_POINTS = Number of points

MULTIPLY = Multiply results for better view in html

About

K-Means implementation in javascript es6

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors