LSTM-Based Time Series Prediction Model: A Case Study with YFinance Stock Data

The goal of this study is to anticipate the time series of stock data that YFinance provides using a Long Short-Term Memory (LSTM) model, with a particular emphasis on the closing prices and daily returns of Apple Inc. (AAPL). The historical closing price data from January 1, 2010, to September 20,...

Full description

Saved in:
Bibliographic Details
Main Author: Yu Yimiao
Format: Article
Language:English
Published: EDP Sciences 2025-01-01
Series:ITM Web of Conferences
Online Access:https://www.itm-conferences.org/articles/itmconf/pdf/2025/01/itmconf_dai2024_03015.pdf
Tags: Add Tag
No Tags, Be the first to tag this record!
Description
Summary:The goal of this study is to anticipate the time series of stock data that YFinance provides using a Long Short-Term Memory (LSTM) model, with a particular emphasis on the closing prices and daily returns of Apple Inc. (AAPL). The historical closing price data from January 1, 2010, to September 20, 2021, was used as the training set, while the data from September 21, 2021, to August 22, 2024, was employed as the validation set to test the model’s predictive capability. The experimental results demonstrate that the LSTM architecture performs excellently in handling data with long-term dependencies and trends, attaining a root mean square error (RMSE) of 5.2129 and a coefficient of determination (R2) of 0.94, thus accurately forecasting the stock price movements of Apple Inc. However, the model exhibits poor performance in predicting high-frequency fluctuations, with an R2 of only -0.1, indicating a weak ability to capture high-frequency volatility.
ISSN:2271-2097