Скачать презентацию Applications Of Genetic Algorithms On Stock Market Prediction Скачать презентацию Applications Of Genetic Algorithms On Stock Market Prediction

b6a1d08f6eec4f4e43d1448e198683ea.ppt

  • Количество слайдов: 37

Applications Of Genetic Algorithms On Stock Market Prediction Applications Of Genetic Algorithms On Stock Market Prediction

How to analyze stock market? Classified by scale Technical analysis Financial statement of companies How to analyze stock market? Classified by scale Technical analysis Financial statement of companies Outlook of different industries Future economics of a country Future economics of the World In most research, only technical analysis is used for predicting stock market

Yung-Keun Kwon and Byung-Ro Moon 2003 GECCO Daily Stock Prediction Using Neuro-genetic Hybrids Yung-Keun Kwon and Byung-Ro Moon 2003 GECCO Daily Stock Prediction Using Neuro-genetic Hybrids

Data Operation Normalize Closing price 1 x(t) Highest price Lowest price xh(t) xl(t) 2 Data Operation Normalize Closing price 1 x(t) Highest price Lowest price xh(t) xl(t) 2 Technical Indicator X 2 3 …… Technical Indicator X 1 Transaction Volume v(t) …… Technical Indicator X 64 64

The recurrent neural network (1) Technical Indicator X 1 Backpropagation Training Train with 1993, The recurrent neural network (1) Technical Indicator X 1 Backpropagation Training Train with 1993, 1994 data 1 1 2 2 3 3 …… Technical Indicator X 64 64 Input Layer 20 Hidden Layer Output Layer

The recurrent neural network (2) Technical Indicator X 1 Test with 1995 data 1 The recurrent neural network (2) Technical Indicator X 1 Test with 1995 data 1 1 2 2 If (Price tomorrow will be higher) sell some stocks 3 If (Price tomorrow will be lower) buy some stocks 20 After testing one year, fitness of this RNN is calculated: 3 …… Technical Indicator X 64 64 Input Layer Hidden Layer Output Layer Fitness = (Cn+Sn) / (C 1+S 1)

Parallel GA architecture (1) Initialize population RNN Selection RNN Crossover and Mutation initial parameter Parallel GA architecture (1) Initialize population RNN Selection RNN Crossover and Mutation initial parameter Replacement …… return fitness RNN Server Client

Parallel GA architecture (2) Initialize population RNN parameters are encoded as a 20 x(64+20+1) Parallel GA architecture (2) Initialize population RNN parameters are encoded as a 20 x(64+20+1) matrix. Selection Roulette-wheel selection Crossover and Mutation 2 D geographical crossover Replacement Replace the most similar parent to it GA stops if no improved solution is found.

Compared with Buy-and-Hold Genetic Algorithm Test with 1996 Train with 1993, 1994 Verify with Compared with Buy-and-Hold Genetic Algorithm Test with 1996 Train with 1993, 1994 Verify with 1995 Compare P-value Test with 1996 Recurrent Neural Network Buy-and-Hold Strategy

Experiment Data 36 companies in NYSE and NASDAQ 10 years from 1992 to 2001 Experiment Data 36 companies in NYSE and NASDAQ 10 years from 1992 to 2001 average of 20 independent trials 359 cases in total Up case (230): the closing price has risen over the year’s starting price by 5% or more Down case (86): the closing price has fallen over the year’s starting price by 5% or more NC case (43): other cases

GA Experimental Results Better Worse Even Total Up 79 76 75 230 Down 66 GA Experimental Results Better Worse Even Total Up 79 76 75 230 Down 66 2 18 86 NC 28 2 13 43 Total 173 80 106 Transaction cost isn’t considered!! 359 If the stock performs well, GA performs as well as random choices If the stock performs inferior, GA performs better than the stock If the stock price doesn’t change much, GA profits from capital gains

Yung-Keun Kwon and Byung-Ro Moon 2004 GECCO Evolutionary Ensemble for Stock Prediction Yung-Keun Kwon and Byung-Ro Moon 2004 GECCO Evolutionary Ensemble for Stock Prediction

Important Changes The transaction cost is considered (0. 3%) More technical indicators are used Important Changes The transaction cost is considered (0. 3%) More technical indicators are used (75) Ensemble technique is used

Data Operation Normalize Closing price 1 x(t) Highest price Lowest price xh(t) xl(t) 2 Data Operation Normalize Closing price 1 x(t) Highest price Lowest price xh(t) xl(t) 2 Technical Indicator X 2 3 …… Technical Indicator X 1 Transaction Volume v(t) …… Technical Indicator X 75 75

Parallel GA architecture Initialize population RNN Selection RNN Crossover and Mutation initial parameter Replacement Parallel GA architecture Initialize population RNN Selection RNN Crossover and Mutation initial parameter Replacement …… return fitness RNN Server Client

Instance-Based Ensemble Model Training Years Verify Year Test Year For each test day, select Instance-Based Ensemble Model Training Years Verify Year Test Year For each test day, select K training days that are most similar to the test day. Final Population Training day 1 …… Training day K test Tomorrow Action BUY KEEP … Training day 2 RNN 1 Majority Decision KEEP RNNn SELL RNN 2 RNN 3 Today

Compared with Buy-and-Hold Genetic Algorithm Test with 1996 Train with 1993, 1994 Verify with Compared with Buy-and-Hold Genetic Algorithm Test with 1996 Train with 1993, 1994 Verify with 1995 Compare P-value Test with 1996 Recurrent Neural Network Buy-and-Hold Strategy

Experiment Data 36 companies in NYSE and NASDAQ 11 years from 1992 to 2002 Experiment Data 36 companies in NYSE and NASDAQ 11 years from 1992 to 2002 394 cases in total Up case (235): the closing price has risen over the year’s starting price by 5% or more Down case (112): the closing price has fallen over the year’s starting price by 5% or more NC case (47): other cases

The effect of transaction cost Without Cost Better Worse Even Total Up 79 76 The effect of transaction cost Without Cost Better Worse Even Total Up 79 76 75 230 Down 66 2 18 86 NC 28 2 13 43 Total 173 80 106 359 With Cost Better Worse Even Total Up 45 125 65 235 Down 57 16 39 112 NC 14 12 21 47 Total 116 153 125 394

A-Ensemble vs. Buy-and-Hold Better Worse Even Total Up 56 87 92 235 Down 58 A-Ensemble vs. Buy-and-Hold Better Worse Even Total Up 56 87 92 235 Down 58 9 45 112 NC 15 3 29 47 Total 129 99 166 394 A-Ensemble performs worse than buy-and-hold

Yung-Keun Kwon, Sung-Soon Choi and Byung-Ro Moon 2005 GECCO Stock Prediction Based Financial Correlation Yung-Keun Kwon, Sung-Soon Choi and Byung-Ro Moon 2005 GECCO Stock Prediction Based Financial Correlation

Data Operation Normalize Closing price 1 x(t) Highest price Lowest price xh(t) xl(t) 2 Data Operation Normalize Closing price 1 x(t) Highest price Lowest price xh(t) xl(t) 2 Technical Indicator X 2 3 …… Technical Indicator X 1 Transaction Volume v(t) …… Technical Indicator X 75 75

Financial Correlation Let xi(i) be the closing price at day t of a company Financial Correlation Let xi(i) be the closing price at day t of a company I The return of the stock-price after a time interval Δt is defined as The cross-correlation between company I and j is given by

Cross-Correlation Example Samsung Electronics Samsung Electro-Mechanics: PCB boards Dong. Bua. Nam Semiconductor Samsung Techwin: Cross-Correlation Example Samsung Electronics Samsung Electro-Mechanics: PCB boards Dong. Bua. Nam Semiconductor Samsung Techwin: semiconductor systems Samsung SDI: LCD, Li-ion battery TRIGEM Computer: personal computers

Feature Selection To predict a company, K companies having the highest absolute value of Feature Selection To predict a company, K companies having the highest absolute value of cross-correlation are selected There are 75 x. K input variables GA selects a set of salient variables among them

Parallel GA architecture Initialize population RNN Selection RNN Crossover and Mutation feature selection Replacement Parallel GA architecture Initialize population RNN Selection RNN Crossover and Mutation feature selection Replacement …… return fitness RNN Server Client

Experiment Data 91 companies in Korea Stock Exchange 4 years from 2000 to 2003 Experiment Data 91 companies in Korea Stock Exchange 4 years from 2000 to 2003 Only tested from 2001 to 2003 Average results over 10 trials K=5

Experimental Results RNN Better Worse Even Total Up 38 100 33 171 Down 59 Experimental Results RNN Better Worse Even Total Up 38 100 33 171 Down 59 6 13 78 NC 7 4 13 24 Total 104 110 59 273 GA Better Worse Even Total Up 62 75 34 171 Down 61 5 12 78 NC 13 3 8 24 Total 136 83 54 273

Kyoung-Jae Kim Expert Systems with Applications 2006 Artificial Neural Networks with Evolutionary Instance Selection Kyoung-Jae Kim Expert Systems with Applications 2006 Artificial Neural Networks with Evolutionary Instance Selection for Financial Forecasting

Instance Selection In general, quality of data mining is improved with additional instances However, Instance Selection In general, quality of data mining is improved with additional instances However, the number of instances may tend to increase the complexity of solution In order to avoid excessive storage and time complexity, and to improve generalizability by avoiding noise and overfitting, we should decide which instances to use

GA architecture Initialize population Selection Crossover and Mutation initial parameter and instance selection n GA architecture Initialize population Selection Crossover and Mutation initial parameter and instance selection n days data ANN fitness = k/n Replacement k correct predictions

Representation 1 0 0 hidden connection weights 1 1 0 input connection weights generate Representation 1 0 0 hidden connection weights 1 1 0 input connection weights generate an ANN 1 0 0 1 instance selection the inputs of ANN

Experimental Results Korean Stock Price Index from 1991 to 1998 For each year, 80% Experimental Results Korean Stock Price Index from 1991 to 1998 For each year, 80% used for training 20% used for validation and testing Average predictive hit ratio 65. 5%

Sam Mirmirani and H. C. Li Computational Economics 2004 Gold Price, Neural Networks and Sam Mirmirani and H. C. Li Computational Economics 2004 Gold Price, Neural Networks and Genetic Algorithms

Neuro. Genetic Optimizer(NGO) A software package GA determines the node-type in NN logistic, linear, Neuro. Genetic Optimizer(NGO) A software package GA determines the node-type in NN logistic, linear, tanh, … The maximum number of inputs to NN is 32 Inputs are gold prices in 32 days

Conclusion Conclusion

Conclusion Choosing a good company is more important than using a good tool We Conclusion Choosing a good company is more important than using a good tool We need more than technical analysis