RCSAN residual enhanced channel spatial attention network for stock price forecasting
Abstract This study proposes a stock price prediction model based on the Residual-enhanced Channel-Spatial Attention Network (R-CSAN), which integrates channel-spatial adaptive attention mechanisms with residual connections to effectively capture the multidimensional complex patterns in financial ti...
Saved in:
| Main Authors: | , , , , , |
|---|---|
| Format: | Article |
| Language: | English |
| Published: |
Nature Portfolio
2025-07-01
|
| Series: | Scientific Reports |
| Online Access: | https://doi.org/10.1038/s41598-025-06885-y |
| Tags: |
Add Tag
No Tags, Be the first to tag this record!
|
| Summary: | Abstract This study proposes a stock price prediction model based on the Residual-enhanced Channel-Spatial Attention Network (R-CSAN), which integrates channel-spatial adaptive attention mechanisms with residual connections to effectively capture the multidimensional complex patterns in financial time series. The R-CSAN adopts an encoder-decoder architecture, where the encoder extracts feature correlations from historical data through multiple layers of channel-spatial attention modules, and the decoder incorporates a masking mechanism to prevent future information leakage and introduces a cross-attention mechanism to model inter-market correlations. Experiments conducted on four cross-market stock datasets, including Amazon, Maotai, Ping An, and Vanke, demonstrate that R-CSAN significantly outperforms not only traditional baseline models such as ARIMA, LSTM, and CNN-LSTM, but also recent Transformer-based approaches like Informer, Autoformer, and iTransformer on metrics including RMSE, MAE, MAPE, $$R^2$$ , and return on investment. The model reduces RMSE by 17.3–49.3% compared to traditional methods and 6.2–11.6% compared to Transformer variants, with the highest $$R^2$$ reaching 93.17% and an increase in return on investment to 482.64%. Ablation experiments confirm the critical contributions of each component, with the temporal module removal causing an average increase of 38.6% in RMSE and channel-spatial attention removal resulting in a 21.3% increase. Moreover, the model provides an interpretative analysis of features and temporal dimensions through attention weight visualization, offering insights into both indicator importance and critical time periods for prediction. In practical applications, R-CSAN’s outputs can be integrated into quantitative trading strategies including breakout trading, moving average crossover signals, and portfolio allocation optimization, providing a new paradigm for robust prediction in highly volatile markets. |
|---|---|
| ISSN: | 2045-2322 |