|
A machine learning approach to forecasting blue-chip stocks: a case study of the Thai stock market |
|---|---|
| รหัสดีโอไอ | |
| Title | A machine learning approach to forecasting blue-chip stocks: a case study of the Thai stock market |
| Creator | Jirawit Kwamman |
| Contributor | Warut Pannakkong, Advisor |
| Publisher | Thammasat University |
| Publication Year | 2568 |
| Keyword | Stock price forecasting, Thai stock market, Machine learning, Time- series forecasting |
| Abstract | This study investigates how machine learning techniques can be used to forecast stock prices in the Thai stock market. The main goal is to develop and assess regression-based machine learning models that estimate the behavior of historical daily closing prices using structured time-series features. Three major Thai stocks, CPALL, SCB, and AOT, are chosen to represent different price fluctuation patterns. This choice enables the study to compare how well the models perform with various stock behavior patterns in the Thai market. Historical daily closing price data collected over about a year uses Python-based tools for data extraction. The structured variables are constructed time-series input variables from this historical price data. These variables include moving averages (MA_7, MA_14, and MA_30) and lag variables (T-1 to T-7). They convert sequential stock price data into structured inputs suitable for regression modeling. By splitting the dataset chronologically into training, validation, and testing subsets to maintain temporal order and minimize the risk of data leakage. We also evaluate two training configurations: non-validation training and training that includes validation. This study examines how the range of training data affects forecast performance. The machine learning models assessed in this study include Decision Tree regression and Artificial Neural Networks (ANNs). Additionally, a Hybrid prediction result is calculated by averaging the output predictions from both the Decision Tree and ANNs models. This helps determine if combining the predictions improves performance compared to the individual models. We evaluate model performance using three regression-based error metrics: Mean Absolute Percentage Error (MAPE), Mean Absolute Error (MAE), and Mean Squared Error (MSE). These metrics offer insights into forecasting accuracy from percentage-based, absolute-error, and square-error viewpoints. The results show that model performance varies among different stocks and evaluation metrics. ANNs deliver the best overall performance for AOT and SCB, while Decision Tree regression is most effective for CPALL. The Hybrid average prediction result does not surpass the top individual model, indicating that simple averaging does not necessarily enhance forecasting accuracy in this study. The findings also suggest that including validation in training can boost prediction performance in several cases, highlighting the significance of training data range in time-series stock price forecasting. Overall, this study adds to machine learning-based financial modeling by comparing regression-based forecasting models, assessing performance across various Thai blue-chip stocks, and looking at how training data setup affects results. The findings offer valuable insight into using machine learning techniques for estimating next available trading-day closing prices using historical price-based features in the Thai stock market. |