Skip to content

Naive Bayesian probability based spam classifier. Created as python implementation for the taugh octave classifier in Machine Learning Course by Andrew Ng.

License

Notifications You must be signed in to change notification settings

akhilesh-k/Spam-Classifier

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

Spam-Classifier


Naive Bayesian probability based spam classifier.
Created it as python implementation for the taugh octave spam classifier in Machine Learning Course by Andrew Ng.

Working

            Probability that a message containing a given word is spam
                             P(W|S) * P(S)
             P(S|W) = ----------------------------- 
                      P(W|S) * P(S) + P(W|H) * P(H)
                      
                      
                      
                      
           
             Probability that a given message is spam
                                       p1 p2 ... pN
              p  =  ------------------------------------------------------
                            p1 p2 ... pN + (1 - p1)(1 - p2) ... (1 - pN)

**The classifier takes a body of known spam and ham (non-spam) emails to evaluate.(Just Like training)**
Then, it evaluates each email in a test body of emails as spam or ham, with the difference between ham and spam only known to the classifier for the purpose of calculating the success rate.

Several parameters can be changed to optimize the effectiveness of the classifier. By tweaking these parameters, rates in the upper 90% range for both spam and ham classification can be reached.

Usage

  • Updating soon.......

About

Naive Bayesian probability based spam classifier. Created as python implementation for the taugh octave classifier in Machine Learning Course by Andrew Ng.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages