Naive Bayes is the method of supervised learning. It is a classification algorithm which is used to predict the class of a given data points. Naive Bayes is based on Bayes Theorem in which the probability of event which is based on previous knowledge and event.

Example: If the vehicles is long width and high height then it is a truck or if it has short width and height then it can be classified has a car.

The existence of these features are dependent of other features. However, these features can contributes to the probabilities of vehicles independently.

Bayes theorem is calculating of posterior probability P(c|x) which is equal to

P(x|c).P(c)/ P(x).

Where P(x|c) is the likelihood, P(c) is the prior probability of and P(x) is the prior probability of features.

By the help of Machine Learning Mastery I had written simple Gaussian Naive Bayes classifier using probability distributive function. Code can be found here. I have used Abalone data However, sklearn library provides the great implementation of different type of Naive Bayes classifier.

Other type of Naive Bayes classifier can be

- Multinomial Naive Bayes
- Bernoulli Naive Bayes

**Application of Naive Bayes**

These simple classification can come in handy when building a classification applications. Following can be possible applications build using Naive Bayes classification

- Recommendation System
- Real time predication
- Spam Filtering
- Text classifications
- Sentiment analysis

### Like this:

Like Loading...

*Related*