We need to somehow measure the similarity or dissimilarity of two vectors in feature space. In the previous section we defined a feature vector. By comparing the distance of two feature vectors we will have one possible solution for measurement.
The choice of error function could have significant impact on the classification rate. We will utilize Euclidean distance error function and also show Earth Mover's Distance algorithm.
Error function is a transformation from a vector space to real numbers:
where is a vector space of dimension
.