*3.3. K-Nearest Neighbors*

The kNN classifier is one of the simplest non-parametric classification methods. Using the distance measure, k examples from the dictionary closest to the classified feature vector are found. The analyzed example is assigned to the categories supported by the majority of *k* voting vectors. The hyperparameters include the value of *k*, voting strategy, and the distance measure selection. This is the only one of the applied classifiers not extracting knowledge from data during the machine learning process. The problem here is determining the significance of available features, for example, by using the information capacity or correlation methods. In the presented research the DT was used to preselect them for the Euclidean measure calculation between each pair of examples*l*1and*l*2:

$$d\_{\rm EULID,l\_1,l\_2} = \sqrt{\left(\mathbf{S}\_{l\_1,\mathbf{pp}} - \mathbf{S}\_{l\_2,\mathbf{pp}}\right) \left(\mathbf{S}\_{l\_1,\mathbf{pp}} - \mathbf{S}\_{l\_2,\mathbf{pp}}\right)^T},\tag{6}$$

where*S* denotes the signature array and*p*DT is the number of the signature features selected by DT.
