8 Using probability to its maximum: The naive Bayes model

 

In this chapter

  • what is Bayes theorem
  • dependent and independent events
  • the prior and posterior probabilities
  • calculating conditional probabilities based on events
  • using the naive Bayes model to predict whether an email is spam or ham, based on the words in the email
  • coding the naive Bayes algorithm in Python

Naive Bayes is an important machine learning model used for classification. The naive Bayes model is a purely probabilistic model, which means the prediction is a number between 0 and 1, indicating the probability that a label is positive. The main component of the naive Bayes model is Bayes’ theorem.

Sick or healthy? A story with Bayes’ theorem as the hero

 

Use case: Spam-detection model

 
 
 

Building a spam-detection model with real data

 

Summary

 

Exercises

 
 
sitemap

Unable to load book!

The book could not be loaded.

(try again in a couple of minutes)

manning.com homepage