| As China’s financial markets continue to mature,investors are faced with unprecedented opportunities for growth.At the same time,risks in the market are intensifying and risk control is becoming an extremely serious reality.Faced with the massive and ever-growing amount of financial data,it is a challenging issue in stock investment to identify risks in stocks quickly and accurately,and to detect and identify abnormal conditions in stock quotes as early as possible to help avoid risks and reduce financial losses in advance.Relevant studies in behavioural finance point out that the Chinese A-share market has a high proportion of individual investors,that diversified investment philosophies increase the volatility of stock prices,and that irrational bubbles lead to frequent asset mispricing,which in severe cases trigger stock price crashes.Therefore,starting from the findings of behavioural finance,combined with advanced data mining models,is the idea of this thesis to solve the above problems.In the process of bubble identification,there are two main aspects that need to be addressed.On the one hand,considering that existing studies have found multiple indicators related to bubbles,how to use these indicators to reflect the degree of stock bubbles more accurately and select appropriate bubble indicators;on the other hand,since online detection methods are needed to react in a timely manner,this may face the problem of conceptual drift of stock data,which affects the accuracy of detection and the reliability of investment strategies.In this paper,we deal with the limitations of a single bubble indicator by using the Attention mechanism to learn the bubble indicator Attention Abnormal Turnover Ratio(AATR)from indicators such as turnover rate,deviation rate and Baidu information index as a measure of the degree of stock bubble;to cope with the uncertainty of data distribution,we use the To cope with the uncertain data distribution,the non-parametric threshold method based on LSTM is used for anomaly detection,and the length of the sliding window is automatically selected by dynamic sliding window.To address the special case of serial anomalies in stocks,the algorithm also enhances its detection performance by sequence learning.Since the parameters of the algorithm in this paper are adaptive based on stock data,no other parameter adjustments are required for the detection method described in this paper when setting the model parameters,except for individual cases such as determining the window size,where parameter adjustments need to be considered.The stock bubble detection algorithm proposed in this paper uses a variety of variables reflecting stock bubbles to train more accurate bubble indicators that can timely reflect the current degree of risk in stocks,and can adaptively detect abnormalities in bubble indicators through nonparametric dynamic thresholds to reduce the impact of conceptual drift of stock data on accuracy,enabling online detection of bubbles in Chinese A-shares.Effective bubble detection facilitates timely implementation of stock risk control,thus reducing the damage caused by its bursting and preventing infinite bubble expansion.Viewing the dynamics of assets from the perspective of bubbles and anomalies provides a novel way of thinking for stock price trend prediction and asset risk control. |