We all face the problem of spam in our inboxes. So I had an idea 💡!

Let’s build a spam classifier program in python which can tell whether a given message is spam or not!

We can do this by using a simple, yet powerful theorem from probability theory called Baye’s Theorem. Mathematically it is expressed as:

Baye’s Theorem

We have a message m = *(w1, w2, . . . . , wn)*, where *(w1, w2, . . . . , wn)* is a set of unique words contained in the message. We need to find

If we assume that the occurrence of a word is independent of all other words, we can simplify the above expression to

In order to classify we have to determine which is greater

#machine-learning #data-science #python #nlp #artificial-intelligence

1.45 GEEK