Concept - Word Likelihood

Definition

The probability of seeing a word given that it occurs in a message of a certain class, (s.37-39). Estimated from a histogram of word counts of the class: count of the word divided by the total number of words in all messages of that class (s.40-41, 55-56). It is the per-word Concept - Likelihood used by Concept - Multinomial Naive Bayes.

Worked example (s.36-60)

Vocabulary: Dear, Friend, Lunch, Money.

WordNormal (total 17)Spam (total 7)
Dear8/17 = 0.472/7 = 0.29
Friend5/17 = 0.291/7 = 0.14 (slide 58 prints “0.29”, a typo)
Lunch3/17 = 0.180/7 = 0
Money1/17 = 0.064/7 = 0.57

Each class is divided by its own total word count. The 0 for Lunch in spam illustrates the Concept - Zero Probability Problem.

Concept - Prior Probability, Concept - Additive Smoothing, Concept - Naive Bayes, Concept - Bag of Words

Source chunk: 03 Text Classification - Chunk 02 (s.31-60)