Understanding the naive Bayes classifier