in the above diagramwe have two features hence we first need to plot these two variables in two dimensional space where each point has two co-ordinatescalled support vectors the line splits the data into two different classified groups this line would be the classifier naive bayes it is also classification technique the logic behind this classification technique is to use bayes theorem for building classifiers the assumption is that the predictors are independent in simple wordsit assumes that the presence of particular feature in class is unrelated to the presence of any other feature below is the equation for bayes theoremp( |bp( |ap(ap(bthe naive bayes model is easy to build and particularly useful for large data sets -nearest neighbors (knnit is used for both classification and regression of the problems it is widely used to solve classification problems the main concept of this algorithm is that it used to store all the available cases and classifies new cases by majority votes of its neighbors the case being then assigned to the class which is the most common amongst its -nearest neighborsmeasured by distance function the distance function can be euclideanminkowski and hamming distance consider the following to use knncomputationally knn are expensive than other algorithms used for classification problems the normalization of variables needed otherwise higher range variables can bias it in knnwe need to work on pre-processing stage like noise removal -means clustering as the name suggestsit is used to solve the clustering problems it is basically type of unsupervised learning the main logic of -means clustering algorithm is to classify the data set through number of clusters follow these steps to form clusters by -meansk-means picks number of points for each cluster known as centroids now each data point forms cluster with the closest centroidsi clusters