This chapter introduces the most common and simple generative classifiers—Naïve Bayes. As mentioned earlier, generative classifiers are supervised learning algorithms that attempt to fit a joint probability distribution p(X,Y) of two X and Y events, representing two sets of observed and hidden (or latent) variables, x and y.
In this chapter, you will learn, and hopefully appreciate, the simplicity of the Naïve Bayes technique through a concrete example. Then, you will learn how to build a Naïve Bayes classifier to predict the stock price movement, given some prior technical indicators in the analysis of financial markets.
Finally, you will learn how to apply Naïve Bayes to text mining by predicting stock prices using financial news feed and press releases.