Ham is email that is not spam or otherwise unwanted. In spam detection, it is the class contrasted with junk email. section 8.2 section 1.3
A spam-detection model estimates whether an email is spam or ham. For example, among 100 emails, 80 ham messages give an estimated ham prior of 0.8. section 8.2
Figure 8.5 We have removed (grayed out) the emails that don’t contain the word lottery. All of a sudden, our probabilities change. Among the emails that contain the word lottery, there are 15 spam emails and 5 ham emails, so the probability that an email containing the word lottery is spam, is 15/20 = 0.75.
Among 20 emails containing “lottery,” five are ham and 15 are spam; the figure illustrates how a word changes the class proportions. section 8.2
A familiar comparison
In a history of 10 emails from Bob, four are ham and six are spam. The two labels provide the counts used to form a simple prediction rule. section 1.3
