Some wonderful javascript tutorials

Tutorial format: description on the left, explaining the code on the right.


A brief high-level description

npm - download the library for use
tutorial - explaining how the code works.
github repository - in case you want to contribute!


Groups data into clusters, calculates the center of the cluster, and then reclusters the data based upon least distance from each newly computed center. Repeat until it converges (centers barely move).

npm -
tutorial -
github -


This algorithm is used by google to determine the prestige of pages. This algorithm can be used for determining areas of influence in a graph. Such as determining the person who is most influential in a social media network. Like Kmeans, this algorithm relies of values converging.

npm -
tutorial -
github -

ignore the following

// Example can be run directly in your JavaScript console

// Create a function that takes two arguments and returns the sum of those arguments

var adder = new Function("a", "b", "return a + b");

// Call the function

adder(2, 6);
// > 8