Abstract
The k-nearest neighbors algorithm (kNN) is renowned for solving classification tasks. The notion of kNN is to seek similar data instances in the dataset as prediction reference, for which the similarity between instances is ordinarily measured by Euclidean distance. Recently, some studies propose problem-tailored distance metrics to improve the classification performance of kNN. In this paper, we utilize genetic programming to learn the transformation function, which interprets the relationship of two data instances into a scalar differential. The differential of data pairs indicates the dissimilarity between two instances. This study considers two forms of transformation functions. Experimental results show the transform functions learned by GP can effectively enhance the performance of kNN.