Font Size: a A A

Research On China’s Commodity Futures Investment Strategy Based On The Attention-LSTM And Ensembled Mechanism Of XGBoost

Posted on:2023-05-08Degree:MasterType:Thesis
Country:ChinaCandidate:J J DengFull Text:PDF
GTID:2530306821466164Subject:Finance
Abstract/Summary:PDF Full Text Request
Since entering the second decade of the 21 st century,the rapid development of computer technology,especially big data,artificial intelligence and large-scale cluster technology,has injected a strong scientific and technological force into finance,and financial technology has also developed to a higher level.stage.The most direct means of applying technology to finance is automated and intelligent financial transactions,and quantitative trading is a financial technology that integrates various cutting-edge computer technologies.In recent years,quantitative trading has developed rapidly in China,and its application in the futures market has received extensive attention.It has the characteristics of rapid response,high accuracy and automation,and can replace the traditional manual order trading mode in the secondary market and derivatives market.In addition,in order to quantify the performance of intelligent models in trading and show the advantages and disadvantages compared to traditional trading strategies,this paper studies a composite model of machine learning and deep learning.First of all,considering the activity of varieties,14 commodities were selected from all commodity futures varieties,and the collected commodity futures index data from 2016 to 2022 were characteristic analyzed,and 5 types of input features and 10 time steps constructed finally.Secondly,in order to enhance the long-term memory ability of the deep learning model,this paper uses the LSTM model with an attention mechanism to study commodity futures.At the same time,in addition to the technical index calculation of various variety index data,the VMD decomposition of the closing price sequence is also carried out.This decomposition can reduce the impact of noise and capture short-term and long-term trends in the market.In order to reduce the model complexity,while speeding up model training and avoiding outfitting,this paper only conducts Attention-LSTM modeling on the decomposed data of VMD,which combines the LSTM network with long and short-term memory capability with the attention mechanism.In addition to this,this paper also applies dropout and batch normalization to avoid the problem of vanishing or exploding gradients.After the model construction is completed,the 10 component data obtained by decomposing will construct training set according to the time step and ups and downs labels,and use this dataset to train the Attention-LSTM model.In addition to deep learning,this paper also applies the XGBoost machine learning algorithm to trading.The algorithm inputs the prediction results of Attention-LSTM,closing price series,SMA,RSI and low-frequency components in the decomposition data into 500 decision tree classifiers for training.Applying the model to commodity futures index data from 2021 to 2022 shows that among the 14 selected varieties,11 varieties had positive returns,and the remaining three varieties suffered a slight loss.Among the varieties with positive returns,asphalt bu The annualized returns of and PVC v are as high as 172.86% and110.44%,the Sharpe ratios are 2.2 and 1.47,and the maximum drawdown is 25.39%and 26.37%.Except for these two varieties,the other varieties with positive returns obtained higher yields.In addition to the back-testing for the constructed model,this paper also compares four classic strategies in quantitative research and the model before the strategy combination.The results show that the classic strategy either has negative returns on most varieties,or even the returns are positive,the drawdown,as well as the volatility are huge,the effect of the strategy before the combination is also far lower than that of the combination strategy.Therefore,the model constructed in this paper is much better than the classical quantitative trading strategy and a single model on the whole in terms of annualized rate of return,Sharpe ratio,drawdown level and volatility level,so it has a high reference value.In addition,the equal weight of each variety can only obtain about 43% of the income,but the drawdown has reached 42%.Based on this,in order to reduce the investment risk and control the drawdown ratio in the trading process,this paper optimizes the investment portfolio,and the optimization goal is to maximize the Sharpe ratio.It can be seen from the optimization results that the portfolio has achieved an annualized return of61.38% since 2021,a Sharpe ratio of 1.71,and a win rate of over 55%,with maximum drawdown and volatility,respectively It is only 17.42% and 1.95%,and the return drawdown ratio is more than 3.5,which shows the investment reference value of the model in commodity futures after portfolio optimization.
Keywords/Search Tags:Commodity Futures, Investment Strategy, Deep Learning, Attention Mechanism, Ensemble Learning
PDF Full Text Request
Related items