Maximizing Profit Prediction: Forecasting Future Trends with LSTM Algorithm and compared with Loss function and Mean error code using Python

Authors

  • Sindhu Selvaraj SRM Institute of Science and Technology
  • N. Vijayalakshmi Department of Computer Science and Application, SRM Institute of Science and Technology, Ramapuram, Chennai, Tamil Nadu
  • S. Sanjay Kumar Department of Computer Science and Application, SRM Institute of Science and Technology, Ramapuram, Chennai, Tamil Nadu
  • G. Deepan Kumar Department of Computer Science and Application, SRM Institute of Science and Technology, Ramapuram, Chennai, Tamil Nadu

DOI:

https://doi.org/10.12725/mjs.65.2

Keywords:

LSTM, Profit prediction, Evaluation metrics, Financial forecasting

Abstract

Profit prediction is a pivotal task in financial markets, empowering investors and traders to make informed decisions. In recent years, the advent of deep learning techniques has revolutionized the field of financial forecasting, offering the potential to extract intricate patterns and relationships from vast and complex datasets. This paper presents an innovative approach to profit prediction using Long Short Term Memory (LSTM) networks, a specialized type of Recurrent Neural Network{RNN). LSTM’s excel at capturing long term dependencies in sequential data, making them well-suited for modeling the dynamics of the financial markets. The core of the paper lies in the practical application of LSTM model architecture specially tailored for profit prediction. This includes defining the input layer, LSTM layers, fully connected layers and the output layer. The training and validation process is elucidated, covering data splitting, model training, validation techniques and hyper parameter tuning to enter ensure the model performance. The paper also explores the practical application of the LSTM-based profit prediction algorithm through a case study involving real-world financial data. Evaluation metrics such as Root Mean Square Error (RMSE) and Mean Absolute Error (MAE) are employed to assess the algorithm's predictive accuracy and effectiveness. Additionally, the paper addresses risk assessment, a critical aspect of profit prediction in financial markets. It sheds light on the promising potential of LSTM-based profit prediction algorithms as a powerful tool for financial forecasting. It summarizes key findings, acknowledges limitations and challenges, and outlines future directions for improving the algorithm, including incorporating additional data sources and fine-tuning hyper parameters. The presented approach offers a significant advancement in the realm of profit prediction, enabling investors and traders to make more informed and data-driven decisions in an ever-evolving financial landscape.

 

References

S. Saydam, J. Coulton and C. Sammut, "Alternative techniques for forecasting mineral commodity prices", International Journal of Mining Science and Technology, vol. 28, no. 2, pp. 309-322, March 2018, [online] Available: https://doi.org/10.1016/j.ijmst.2017.09.001.

G. Cortazar, I. Kovacevic and E. Schwartz, "Commodity and Asset Pricing Models: An Integration", National Bureau of Economic Research, June 2013, [online] Available: https://doi.org/10.3386/w19167.

A. Sharma, D. Bhuriya and U. Singh, "Survey of stock market prediction using machine learning approach", 2017 International Conference of Electronics Communication and Aerospace Technology (ICECA), 2017, April, [online] Available: https://doi.org/10.1109/iceca.2017.8212715.

M. A. Istiake Sunny, M. M. S. Maswood and A.G. Alharbi, "Deep Learning-Based Stock Price Prediction Using LSTM and Bi-Directional LSTM Model", 2020 2nd Novel Intelligent and Leading Emerging Sciences Conference (NILES), 2020, October 24, [online] Available: https://doi.org/10.1109/niles-50944.2020.9257950.

Eugene F. Fama, "The Behavior of Stock Market Prices", the Journal of Business, vol. 2, no. 2, pp. 7-26, January 1965.

Stock market challenges, [online] Available: http://www.google.com.

A Sheta, "Software Effort Estimation and Stock Market Prediction Using Takagi-Sugeno Fuzzy Models", InProceedings of The IEEE International Conference on Fuzzy Systems, pp. 171-178, 2006.

S. Selvin, R. Vinayakumar, E. Gopalakrishnan, V. K. Menon and K. Soman, "Stock price prediction using lstm rnn and cnn-sliding window model", 2017 international conference on advances in computing communications and informatics (icacci), pp. 1643-1647, 2017.

K. Chen, Y. Zhou and F. Dai, "A lstm-based method for stock returns prediction: A case study of china stock market", 2015 IEEE international conference on big data (big data), pp. 2823-2824, 2015.

M. Roondiwala, H. Patel and S. Varma, "Predicting stock prices using lstm", International Journal of Science and Research (IJSR), vol. 6, no. 4, pp. 1754-1756, 2017.

"Meaning Factors & Advantages", Groww, September 2022, [online] Available: https://groww.in/p/whatis-mcx-trading.

moneycontrol.com, [online] Available: https://www.moneycontrol.com/commodity/.

Commodity Forecast 2022/2023. (n.d.), September 2022, [online] Available: https://tradingeconomics.com/forecast/commodity.

International Monetary Fund, [online] Available: https://www.imf.org/external/pubs/ft/wp/2004/wp0441.pdf.

Understanding LSTM Networks -- colah’s blog. (n.d.-b), September 2022, [online] Available: https://colah.github.io/posts/2015-08-Understanding-LSTMs/.

G. V. Jose, "Predicting Sequential Data using LSTM: An Introduction", Medium, December 2021, [online] Available: https://towardsdatascience.com/time-series-forecasting-withrecurrent-neural-networks-74674e289816.

S. M. L. Club, "Using LSTM’s to Predict Future Stock Prices - Visionary Hub", Medium, January 2022, [online] Available: https://medium.com/visionary-hub/using-lstms-to-predict-futurestock-prices-61f4458fc860.

TensorFlow, September 2022, [online] Available: https://www.tensorflow.org/tutorials/structured_data/time_series.

K. Kuguoglu, "Predicting future values with RNN LSTM and GRU using PyTorch", Medium, January 2022, [online] Available: https://towardsdatascience.com/predicting-future-valueswith-rnn-lstm-and-gru-using-pytorch-d9ef50991ec7.

Investopedia, August 2022, [online] Available: https://www.investopedia.com/terms/c/commodity.asp.

K. Shenmare, "Commodity Market", WallStreetMojo, September 2022, [online] Available: https://www.wallstreetmojo.com/commodity-market/.

5paise.Com, September 2022, [online] Available: https://www.5paisa.com/stockmarket-guide/commodity-trading/how-commodity-market-works-inindia.

G. V. Jose, "Predicting Sequential Data using LSTM: An Introduction", Medium, December 2021, [online] Available: https://towardsdatascience.com/time-series-forecasting-withrecurrent-neural-networks-74674e289816.

Z. He, J. Zhou, H. N. Dai and H. Wang, "Gold Price Forecast Based on LSTM-CNN Model", 2019 IEEE Intl Conf on Dependable Autonomic and Secure Computing Intl Conf on Pervasive Intelligence and Computing Intl Conf on Cloud and Big Data Computing Intl Conf on Cyber Science and Technology Congress (DASC/PiCom/CBDCom/CyberSciTech), 2019, August, [online] Available: https://doi.org/10.1109/dasc/picom/cbdcom/cyberscitech.2019.00188.

Downloads

Published

2023-12-28

How to Cite

Selvaraj, S., N. Vijayalakshmi, Kumar, S. S., & Kumar, G. D. (2023). Maximizing Profit Prediction: Forecasting Future Trends with LSTM Algorithm and compared with Loss function and Mean error code using Python. Ushus Journal of Business Management, 22(4), 15-28. https://doi.org/10.12725/mjs.65.2