Implements k-nearest neighbors algorithm