Presentation is loading. Please wait.

Presentation is loading. Please wait.

N-tuple S&P Patterns Across Decades, 1950s to 2011

Similar presentations


Presentation on theme: "N-tuple S&P Patterns Across Decades, 1950s to 2011"— Presentation transcript:

1 N-tuple S&P Patterns Across Decades, 1950s to 2011
A. G. (Tassos) Malliaris Mary Malliaris LOYOLA UNIVERSITY CHICAGO The Korea Institute of Finance and The Athenian Policy Forum Conference Seoul, Korea June 16-18, 2013

2 Purpose To investigate the Up and Down movements of the S&P 500 from 1950 through 2011 And to use that information to forecast the direction tomorrow of the S&P 500

3 Data Daily closing prices from 1/3/1950 to 7/19/2011
Over 15,000 observations were transformed into Up [U] or Down [D] by comparing today’s value to yesterday’s Up and Down movements were recorded from 1 up to 7 days

4 Up [U] and Down [D] movements per decade, 1950 through 2011.

5 Two-Day Patterns Across Decades

6 Three-Day Patterns

7 Four to Seven-Day patterns
Strings were formed, for example, UDDU through DUDUDDU From 16 to 128 patterns [too many to display on a slide] Columns also created counting the number of Up movements within a string

8 Number of Ups in Two Days

9 Number of Ups in Three Days

10 Number of Ups in Four Days

11 Number of Ups in Five Days

12 Forecasting Training set: data from January 1950 through December 2009 [15,087 rows]. Validation set: January 2010 through mid-September 2011 [387 rows] Training set patterns were used as inputs for models that were then used to predict the Validation set

13 Forecasting Methodologies
Pattern Forecasts with 1 to 7 Days Decision Tree Neural Network Random Forecasts

14 The Forecast Decision by Pattern, an Example
Training set 4-day patterns Count DDUD 760 DDUU 1050 Validation Set Pattern Up through Today Most Likely Move Tomorrow DDU U Suppose that DDU has occurred. Past history tells us that, for the next day, DDUU is more likely to occur than DDUD. So, for tomorrow, we will forecast Up when the three days before tomorrow have the pattern DDU.

15 Decision Tree Forecasts
Decision Tree Methodology: C5.0 Software Package: SPSS Modeler Target: Tomorrow’s Direction Inputs: : the up-down patterns from one to seven days, the number of up days in 1 to five days, and the closing value today

16 Decision Tree Variable Importance
This Modeler technique also ranks the input variables in terms of importance, with more important variables occurring higher up on the tree. The variables ranked highest in importance to the forecast were the direction today the closing value today the 7-day pattern [for example UDUUDDU] number of Up movements in the last three days.

17 Neural Network Forecasts
Neural Network Methodology: Back Propagation; two hidden layers Software Package: SPSS Modeler Target: Tomorrow’s Direction Inputs included: the up-down patterns from one to seven days, the number of up days in 1 to five days, and the closing value today

18 Neural Network Variable Importance
SPSS Modeler also ranks the input variables in terms of their importance to the neural network The variables ranked highest in importance with this methodology were the patterns in the 4 day through 7 day strings the number of Ups in the past three days the closing value

19 Comparing Methods by Calculating Gain or Loss Daily Gain/Loss Summed Over 387 Days
Change in Index Actual Direction Predicted Direction Amount of Gain/Loss -5 Down 5 Up

20 Random Forecast A random number was generated for each day in the validation set If the random value was less than .5 then Down was predicted, otherwise the forecast was Up. The amount of gain/loss was calculated over the Validation set This was repeated 100,000 times

21 RANDOM WALK SIMULATIONS Total gains/losses for 100,000 simulated random forecasts for 387 days

22 Number of correct directional forecasts for each methodology
Down Up Number Correct 2 Day String 72 123 195 3 Day String 41 164 205 4 Day String Decision Tree 43 168 211 5 Day String 45 167 212 7 Day String 48 6 Day String 40 178 218 1 Day String 219 Neural Net 61 161 222

23 Total amount gained or lost per strategy, and comparison to the random simulations
Type of Forecast Total Amount Gained/Lost Amount as Std Deviations in the Random Distribution 2 Day String -21.08 -0.087 Decision Tree 168.16 0.715 3 Day String 174.34 0.742 4 Day String 1 Day String 193.96 0.825 7 Day String 306.92 1.303 5 Day String 307.22 1.305 6 Day String 335.84 1.426 Neural Net 393.4 1.67

24 Conclusions The number of up movements is greater than down movements across the decades. Patterns of Up and Down movement from the past can be useful for forecasting future movement The highest gain from simple patterns came from using the 6-day strings The neural network, a more complex methodology, yielded the greatest gain


Download ppt "N-tuple S&P Patterns Across Decades, 1950s to 2011"

Similar presentations


Ads by Google