K-nearest neighbors algorithm and Perceptron algorithm for classification implemented from scratch in Java. Selected on the basis of given parameters. 1 argument - K-nearest neighbors algorithm, the argument transfers the k parameter (number of nearest objects of observations from the training set). 2 arguments - Perceptron algorithm, the arguments are threshold and rate. Tested on an iris dataset. At the output we get assignment accuracy.
This dataset consists of samples from each of three species of Iris(Iris setosa, Iris virginica and Iris versicolor). Each sample has four features: sepal length, sepal width, petal length and petal width.