The goal of this chapter is to predict the values of near-or long-term equity prices by using machine learning (ML). From an investor's perspective, investments (in equity) across several companies are stocks, while such investments in an individual company are shares. Most investors lean on a long-term investment strategy for the best returns. Investment analysts employ mathematical stock analysis models to help predict future stock prices or price movements in the long term. Such models factor in past equity prices and other indicators to perform a company's financial health evaluation.
The overarching learning objective of this chapter is to implement a Scala solution that will predict stock market prices. Starting from the stock price prediction dataset, we will use the Spark ML library's ML APIs to build a stock price...