23
Integrating a Piecewise Linear Representation Method and a Neural Network Model for Stock Trading Points Prediction Pei-Chann Chang, Chin-Yuan Fan, and Chen-Hao Liu TSMCC.2008 Presenter: Yu Hsiang Huang Date: 2011-12-30

Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Embed Size (px)

Citation preview

Page 1: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Integrating a Piecewise Linear Representation Method and a Neural Network Model for

Stock Trading Points Prediction

Pei-Chann Chang, Chin-Yuan Fan, and Chen-Hao Liu

TSMCC.2008

Presenter: Yu Hsiang Huang

Date: 2011-12-30

Page 2: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Outline

• Introduction

• IPLR Model

– Piecewise Linear Representation

– Stepwise Regression Algorithm

– Genetic Algorithm

– Back-propagation Network

• Experimental results

• Conclusion

Page 3: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Introduction

• Stock market– Highly nonlinear dynamic system

• Interest rates, inflation rate, economic environments, political issues…

• Most resent research– Derive accurate models

– Predict the future price of stock movement

• In this paper– Trading decision

• Buy/Sell points

– Critical role to make a profit

Page 4: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Expect output input

no

yes

IPLR ModelCandidate Stocks Screening

GA

SRA

PLR

BP(train)

Related input variable

Turning point Trading signal

Trading decision

Selected stock

Reach number of

generation ? Test Calculate

profit

BP Buy/sell

End

Related input variables

Related input variables

Technical indexes

Page 5: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Genetic Algorithm

Initialization

Selection

Reproduction

Termination

1 0 … 0 1

Randomly generate initial population

50

10

0.8

0.1

Fitness function roulette-wheel selection

Tournament selection

Crossover MutationTwo-point

genetic diversity

# of generation , reach the best fitness value , …

Page 6: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

IPLR ModelCandidate Stocks Screening

GA

PLR Turning point Trading signal

Selected stock

Page 7: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Piecewise Linear Representation

Stock price

datesegment1

Turning point

Turning point

t1 t2 t3 t4 t5

Page 8: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Piecewise Linear Representation

Page 9: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Get trend of time series data

Calculate trend Only in turning point

Piecewise Linear Representation

Page 10: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Derive the trading signal

Tradition

Up Down : 1 [sell]Down UP : 0 [buy]

Not quite related to the price variation

Piecewise Linear Representation

Page 11: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Derive the trading signal

Redefine the trading signals

Piecewise Linear Representation

Page 12: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

IPLR ModelCandidate Stocks Screening

GA

SRA

PLR

Related input variable

Turning point Trading signal

Selected stock

Technical indexes

Page 13: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Stepwise Regression Algorithm

Page 14: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Stepwise Regression Algorithm

X2X3

X4

YX1

X5Xp

Calculate the significant value S

Last X ?

Output

yes no

no

yes

Apply by SPSS (Statistic Package for Social Science)

Page 15: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

IPLR Model

Expect output input

Candidate Stocks Screening

GA

SRA

PLR

BP(train)

Related input variable

Turning point Trading signal

Selected stock

Technical indexes

Page 16: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Back-propagation Network

Page 17: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

IPLR Model

Expect output input

Candidate Stocks Screening

GA

SRA

PLR

BP(train)

Related input variable

Turning point Trading signal

Trading decision

Selected stock

Test

BP Buy/sellRelated input variables

Technical indexes

Page 18: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Back-propagation NetworkTrading decision

Change of the trading signal pass through the boundary value:Change is upward sellChange is downward buy

Boundary value : 0.508

Test data input to BP

Page 19: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

IPLR Model

Expect output input

no

yes

Candidate Stocks Screening

GA

SRA

PLR

BP(train)

Related input variable

Turning point Trading signal

Trading decision

Selected stock

Reach number of

generation ? Test Calculate

profit

BP Buy/sell

End

Related input variables

Related input variables

Technical indexes

Page 20: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Experimental results

Historic data : from 2004/01/02 to 2006/04/12Training data : 2004/01/02 to 2005/09/30Testing data : 2005/10/1 to 2006/04/12

Up-trend : 30-day moving average cross over 90-day moving averageDown-trend : 30-day moving average cross down 90-day moving averageSteady : no major tendency of 30-day moving average with 90-day moving average

Page 21: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Experimental results

Up

Steady

Down

Page 22: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Experimental resultsS&P500 : four years data [2000-2003]

Page 23: Integrating a piecewise linear representation method and a neural network model for stock trading points prediction

Conclusion• Trading decision > determine stock price itself

• IPLR

– PLR : find turning point

– GA : improve the threshold value for PLR

– BPN : train the connection of the model

– Significant amount of profit

• Clustering of financial time series data

• A different forecasting model

– SVM , FNN,…

• A similar training pattern