This research investigates the use of Long Short-Term Memory (LSTM) networks for predicting stock prices and optimizing investment portfolios. Utilizing a dataset comprising the top 30 U.S. companies by market capitalization from 2009-12-31 to 2021-12-31, excluding AbbVie, Meta, and Tesla due to their later market listings, we demonstrate that LSTM models outperform conventional Recurrent Neural Networks (RNN) and Convolutional Neural Networks (CNN) in generating accuracy and portfolio returns. By efficiently capturing long-term dependencies within stock price data, LSTMs offer more reliable predictions, which are crucial for optimizing investment portfolios. Our methodology involves data collection and preprocessing, model building using LSTM architecture, and evaluating performance using metrics such as mean absolute error (MAE), mean squared error (MSE), root mean squared error (RMSE), mean absolute percentage error (MAPE), and mean percentage error (MPE). The results indicate that LSTM models not only enhance prediction accuracy but also improve portfolio returns compared to equally weighted and market capitalization weighted portfolios. This research provides significant insights into the benefits of using advanced deep learning techniques like LSTMs for financial market predictions and portfolio management.
Read full abstract