Submitted:
29 October 2023
Posted:
31 October 2023
You are already at the latest version
Abstract
Keywords:
1. Introduction
2. Related Work
3. Data Collection and Preprocessing
3.1. Data Source and Collection Process
3.2. Preprocessing Steps
3.2.1. Data Cleaning
3.2.2. Handling Missing Values
3.2.3. Feature Engineering
3.3. Normalization Technique: Min-Max Scaling
- -
- (X) represents the original feature values.
- -
- (Xmin)istheminimumvalueofthefeature.
- -
- (Xmax)isthemaximumvalueofthefeature.
4. Methodology
4.1. Types of Hybrids
4.1.1. LSTM + Reinforcement Learning + Linear Regression
4.1.2. LSTM + GRU + Conv1D

4.1.3. Linear Regression + SVM
4.1.4. MLPRegressor + GradientBoostingRegressor
4.1.5. XGBRegressor + Linear Regression
4.2. Experimental Setup
4.2.1. Data Splitting
- -
- Training Set: This subset comprises the historical stock price data up to August 18, 2023. It serves as the foundation for training our hybrid models, allowing them to learn patterns, relationships, and trends in the data. The training set is vital for optimizing model parameters and ensuring predictive accuracy.
- -
- Testing Set: The testing set includes the stock price data from August 19, 2023, to September 6, 2023. This segment of the data is kept separate from the training set and is used exclusively for model evaluation. It allows us to assess how well our hybrid models generalize to unseen data, providing a robust measure of their predictive capabilities.
4.2.2. Hyperparameter Tuning and Model Selection
4.2.3. Training the Models
- -
- Number of Epochs: Each model was trained over 200 epochs. This choice of epoch count balances training time with convergence to optimal weights and biases.
- -
- Batch Sizes: We utilized batch sizes of 32 for training the models. This batch size facilitates efficient weight updates during the training process and prevents excessive memory usage.
4.3. Hardware and Software Specifications:
4.3.1. Hardware
4.3.2. Software
5. Results
5.1. Visualization





5.2. Model Comparison
5.3. Interpretation of R-Squared (R2)
5.4. Target Date Prediction
5.5. Procedure for Predicting Stock Prices
5.6. Prediction Results
6. Conclusion
7. Future Work
References
- Strader, Troy J.; Rozycki, John J.; ROOT, THOMAS H.; and Huang, Yu-Hsiang John (2020) ”Machine Learning Stock Market Prediction Studies: Review and Research Directions,” Journal of International Technology and Information Man- agement: Vol. 28: Iss. 4, Article 3. Available at: https://scholarworks.lib.csusb.edu/jitim/vol28/iss4/3. [CrossRef]
- Himanshu H Shrimalve and Sopan A Talekar. Comparative Analysis of Stock Mar- ket Prediction System using SVM and ANN. International Journal of Computer Applications 182(1):59-64, July 2018.
- ”Stock Market Prediction Using Machine Learning Techniques,” ACI’22: Work- shop on Advances in Computation Intelligence, its Concepts Applications at ISIC 2022, May 17-19, Savannah, United States.
- TY - JOUR AU - Talekar, Sopan PY - 2020/07/16 SP - 6 T1 - Comparative Analysis of Stock Market Prediction System using SVM and ANN VL - 182 JO International Journal of Computer Applications ER -.
- Machine Learning Approaches in Stock Price Prediction: A Systematic Review Journal of Physics: Conference Series 2161 (2022) 012065 IOP Publishing. [CrossRef]
- Stock Market Prediction Using Machine Learning Techniques ACI’22: Workshop on Advances in Computation Intelligence, its Concepts Applications at ISIC 2022, May 17-19, Savannah, United States.
- Mukherjee, S., et al.: Stock market prediction using deep learn- ing algorithms. CAAI Trans. Intell. Technol. 8(1), 82–94 (2023). [CrossRef]
- Sheth, D., Shah, M. Predicting stock market using machine learning: best and accurate way to know future stock prices. Int J Syst Assur Eng Manag 14, 1–18 (2023). [CrossRef]
- S. Boonpeng and P. Jeatrakul, ”Decision support system for investing in stock market by using OAA-Neural Network,” 2016 Eighth International Conference on Advanced Computational Intelligence (ICACI), Chiang Mai, Thailand, 2016, pp. 1-6. [CrossRef]
- S. Sarvesh, R.V. Sidharth, V. Vaishnav, J. Thangakumar and S. Sathyalak- shmi, ”A Hybrid Model for Stock Price Prediction using Machine Learning Techniques with CNN,” 2021 5th International Conference on Information Sys- tems and Computer Networks (ISCON), Mathura, India, 2021, pp. 1-6. [CrossRef]
- Yadav, K., Yadav, M., Saini, S. (2021). Stock values predictions using deep learning based hybrid models. CAAI Transactions on Intelligence Technology, 7(1), 107-116. [CrossRef]
- Hiransha M, Gopalakrishnan E.A., Vijay Krishna Menon, Soman K.P., NSE Stock Market Prediction Using Deep-Learning Models, Procedia Computer Science, Volume 132, 2018, Pages 1351-1362, ISSN 1877-0509. [CrossRef]
- Latrisha N. Mintarya, Jeta N.M. Halim, Callista Angie, Said Achmad, Aditya Kurniawan, Machine learning approaches in stock market prediction: A sys- tematic literature review, Procedia Computer Science, Volume 216, 2023, Pages 96-102, ISSN 1877-0509. [CrossRef]
- Zahra Fathali, Zahra Kodia Lamjed Ben Said (2022) Stock Market Prediction of NIFTY 50 Index Applying Machine Learning Techniques, Applied Artificial Intelligence, 36:1. [CrossRef]
- Sonkavde, G.; Dharrao, D.S.; Bongale, A.M.; Deokate, S.T.; Doreswamy, D.; Bhat, S.K. Forecasting Stock Market Prices Using Machine Learning and Deep Learning Models: A Systematic Review, Performance Analysis and Discussion of Implica- tions. Int. J. Financial Stud. 2023, 11, 94. [Google Scholar] [CrossRef]
- Umer, M., Awais, M., Muzammul, M. (2019). Stock Market Predic- tion Using Machine Learning(ML)Algorithms. ADCAIJ: Advances in Dis- tributed Computing and Artificial Intelligence Journal, 8 (4), 97–116. [CrossRef]
- Shen, J., Shafiq, M.O. Short-term stock market price trend prediction using a comprehensive deep learning system. J Big Data 7, 66 (2020). [CrossRef]
- Rouf, N.; Malik, M.B.; Arif, T.; Sharma, S.; Singh, S.; Aich, S.; Kim, H.-C. Stock Market Prediction Using Machine Learning Techniques: A Decade Survey on Methodologies, Recent Developments, and Future Directions. Electronics 2021, 10, 2717. [Google Scholar] [CrossRef]
| Name | Mean absolute error |
Mean square error | Root mean square error |
R-Squared (R2) |
|---|---|---|---|---|
| LSTM+GRU+Conv1D | 0.95 | 2.1222 | 1.52 | 0.9982 |
| LSTM + Reinforcement Learning + Linear Regression |
||||
| 1.91 | 0.0004 | 2.53 | 0.9791 | |
| Linear Regression+ SVM | ||||
| 1.89 | 0.0004 | 2.51 | 0.9794 | |
| MLPRegressor+ GradientBoostingRegressor | ||||
| 3.14 | 0.0010 | 3.93 | 0.9495 | |
| XGBRegressor+LinearRegression | 1.93 | 0.0004 | 2.53 | 0.9791 |
| Name | Actual price(2023-08-18) | Predicted price (2023-08-18) |
Accuracy (%) |
|---|---|---|---|
| LSTM+GRU+Conv1D | 128.11 | 128.90 | 99.82 |
| LSTM + Reinforcement Learning + Linear Regression |
|||
| 128.11 | 130.74 | 97.91 | |
| Linear Regression+ SVM | |||
| 128.11 | 130.44 | 97.94 | |
| MLPRegressor+ GradientBoostingRegressor | |||
| 130.93 | 0.0010 | 94.95 | |
| XGBRegressor + LinearRegression | 128.11 | 130.68 | 97.91 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).