SlideShare une entreprise Scribd logo
1  sur  33
Télécharger pour lire hors ligne
Case Study of Rule Data
Mining for the S&P 500
Data Mining Bias and Rule Evaluation
• Data mining is a process in which the profitability of many rules is compared so
that one or more superior rules can be selected.
• The observed performance of the best rule(s) in the back test overstates its
(their) expected performance in the future.
• This bias complicates the evaluation of statistical significance and may lead a
data miner to select a rule with no predictive power
• This problem can be minimized by using specialized statistical-inference tests.
The case study illustrates the application of two such methods: an enhanced
version of White's reality check and Masters' Monte-Carlo permutation
method.
Data Mining Bias and Rule Evaluation
Avoidance of
Data Snooping
Bias
Analyzed Data
Series
Technical
Analysis
Themes
Performance
Statistic:
Average Return
No Complex
Rules Were
Evaluated
Avoidance of Data Snooping Bias
• The data snooping bias is a statistical bias that appears when exhaustively searching
for combinations of variables, the probability that a result arose by chance grow with
the number of combinations tested.
• In order to minimize the probability that our results occurred simply by chance, we
can divide that data that we used in the back testing process into 2 samples.
• The first one is called the in-sample and it is the data sample that will be used to back
test all the combinations that result from the initial trading rules.
• The second one is called out-of-sample and it is used as a way to test the best
performing rules (the one that were picked from the in-sample back testing) on new
data.
The Case Study Defined in Statistical Terms
• The case study in terms of the key elements of a statistical study
• The Population: The population at issue is the set of daily returns that would be earned by a rule if
its signals were to be applied to the S&P 500 over all possible realizations of the immediate practical
future
• Population Parameter : The population parameter is the rule's expected average annualized return in
the immediate practical future.
• The Sample : The sample consists of the daily returns earned by a rule applied over the back-test
period
• Sample Statistic (Test Statistic) : The sample statistic is the average annualized return earned by a
rule when applied
• The Null Hypothesis (H0): The null hypothesis states that all 6,402 rules tested are without predictive
power. This implies that any observed profits in a back test were due to chance (sampling variability).
• The Alternative Hypothesis : alternative hypothesis asserts that a rule's back-tested profitability
systems from genuine predictive power
• The Statistical Significance Level: A 5 percent level of significance was chosen as a threshold for
rejection of the null hypothesis. This means there was a 0.05 probability of rejecting the H0
hypothesis when the H0 was, in fact, true.
• Practical Significance : practical significance relates to the economic value of the observed rule
return.
Rules: Transforming Data Series into Market Positions
• A rule is an input/output process.
• Transforms input(s), consisting of one or more time series, into an output, a
new time series consisting of +1's and −1's that indicate long and short
positions in the market being traded (i.e., S&P 500).
TA Rule Transforms Input into Output.
Raw Market Time Series as Rule Input.
Rules: Transforming Data Series into Market Positions
• Other rules utilize input series that have
been derived from one or more raw
market series by applying various
transformations to the market data.
• These preprocessed inputs are referred to
as constructed data series or indicators.
• An example of an indicator is the negative
volume index. It is derived from
transformations of two raw data series;
S&P 500 closing price and total NYSE daily
volume
• The transformations used in the creation
of the negative volume index and other
indicators used in the case study are
described in the following section.
Time-Series Operators
Channel Breakout
Operator (CBO)
Moving-Average
Operator (MA)
Channel-
Normalization
Operator
(Stochastics): CN
Indicator Scripting
Input Series to Rules: Raw Time Series and Indicators
Price and
volume
functions
Market-
Breadth
Indicators
Prices-of-
debt
instruments
Interest-rate-
spread
indicators
Price and Volume Functions
• Technical analysis practitioners have suggested a number of price and volume
functions: on-balance volume, accumulation distribution volume, money flow,
negative volume, and positive volume.
• The price-volume functions were used to create two types of indicators:
• (1) Cumulative Sums : Cumulative sum is the algebraic sum of all prior daily
values of the price-volume function. The daily value of a price-volume function
can either be a positive or negative quantity. Thus, an indicator defined as the
cumulative sum of the on-balance volume
• (2) Moving Averages : Moving average of a price-volume function will be a
stationary time series. Moving average only considers the observations within
the look-back span. Since price and volume functions can assume both positive
or negative values, a moving average will tend to remain within a relatively
confined range near zero.
Price and Volume Functions
Cumulative On-
Balance Volume
Moving Averages
of On-Balance
Volume
Cumulative
Accumulation-
Distribution
Volume (CADV)
Moving Averages
of Accumulation
Distribution
Volume
Cumulative Money
Flow (CMF)
Moving Averages
of Money Flow
Cumulative
Negative Volume
Index (CNV)
Moving Averages
of Negative
Volume Index
Cumulative
Positive Volume
Index (CPV)
Moving Averages
of Positive Volume
Market Breadth Indicators
• Market breadthrefers to the spread or difference between the number of
stocks advancing and the number declining on a given day, week, or other
defined time interval.
• Breadth indicators are of two forms: cumulative sums of daily figures and
moving averages of daily figures
• Breadth indicators that are cumulative sums display long-term trends,
whereas moving-average breadth indicators tend to have reasonably stable
mean values and fluctuation ranges.
Market Breadth Indicators
Cumulative
Advance-Decline
Ratio (CADR)
Moving Averages
of Advance-
Decline Ratio
Cumulative Net
Volume Ratio
(CNVR)
Moving Averages
of Net Volume
Ratio
Cumulative New
Highs-Lows Ratio
(CHLR)
Moving Averages
of New Highs/New
Lows Ratio (HLR1
and HLR30)
Prices-of-Debt Instruments from Interest Rates
• Interest rates and stock price levels move inversely.
• Taking the reciprocal (1/interest rate) interest rates can be transformed into
price-like time series that are, in general, positively correlated with stock
prices.
• This reciprocal series can be multiplied by a scaling factor such as 100. Thus, a
rate of 6.05 percent would be equivalent to a price of 15.38 (1/6.05 × 100).
• Case study and was performed on four interest rate series: threemonth
treasury bills, 10-year treasury bonds, Moody's AAA corporate bonds, and
Moody's BAA corporate bonds.
Interest Rate Spreads
• An interest-rate spread is the difference between two comparable interest
rates.
• Two types of interest-rate spreads were constructed for the case study;
• The durationspread : The duration spread, also known as the slope of the yield
curve, is the difference between yields on debt instruments having the same
credit quality but having different durations (i.e., time to maturity). The
duration spread used in the case study was defined as the yield on the 10-year
treasury note minus the yield on the three-month treasury bills (10-year yield
minus 3-month yield).
• The qualityspread: A quality spread measures the difference in yield between
instruments with similar durations but with different credit qualities (default
risk). The quality spread for the case study was based on two of
Moody's38long-term corporate bond series: AAA,39which are the highest
rated corporate debt, and BAA,40a lower rated grade of corporate debt. The
quality spread is defined here as AAA yield −BAA yield.
The Rules
Trends
Extremes and
transitions
Divergence.
Trends
• Foundational principle of TA is that prices and yields move in trends that can
be identified in a sufficiently timely manner to generate profits.
• Most widely used are moving averages, moving-average bands, channel
breakout, and Alexander filters also known as zigzag filters.
• CBO operator transformed the input time series into a binary valued time series
consisting of +1 and −1.
• When the trend of the input series was in an uptrend, as determined by the
CBO, the rule's output was +1.
• Conversely, when the analyzed series was determined to be in a downtrend,
the output was −1.
• The identification of trend reversals in the input series by CBO is subject to lag.
• All trend indicators necessarily incur lag—a delay between the time the input
series experiences a trend reversal and the time the operator is able to detect
it. Lag can be reduced by making the indicator more sensitive
Extreme Values and Transitions
• “Extreme Values and Transitions” or Erules is based on
the notion that a time series conveys information when
it assumes an extreme high or low value or as it makes
the transition between extremes.
• High and low extremes can be defined in terms of
fixed value thresholds if the time series has a relatively
stable mean and fluctuation range (i.e., is stationary).
All input series used for E rules were made stationary
by applying the CN operator.
• E rules is given by the expression:=CN (LMA (Input
Series, 4), N-days)Where:CN is the channel
normalization operatorLMA is a linearly weighted
moving-average operator
Extreme Values and Transitions
• E-rule signals were generated when the channel
normalized smoothed series crossed a threshold.
• Given that there are two thresholds, an upper and
lower, and given that there are two directions in
which a crossing can occur (up or down)
• Four possible threshold-crossing events:
• 1.Lower threshold is crossed in the downward
direction.
• 2.Lower threshold is crossed in the upward direction.
• 3.Upper threshold is crossed in the upward direction.
• 4.Upper threshold is crossed in the downward
direction.
• Each E rule was defined in terms of two threshold-
crossing events:
• one specifying the long entry/short exit and the other
specifying the short entry/long exit
Extreme Values and Transitions
Types 1
Types 2 Types 4
Types 3 Types 5
Extreme Values and Transitions
Types 9
Types 7 Types 8
Types 10
Types 11
Types 6
Types 12
Divergence Rules
• A divergence is said to occur when one
member of the pair departs from their
shared trend.
• A divergence manifests itself as follows:
both series have been trending in the
same direction, but then one series
reverses its prior trend while its
companion continues its prior trend.
• Divergence analysis, is a potential signal
that the prior shared trend has weakened
and may be about to reverse.
Divergence Rules
• The Dow theory is based on divergence analysis , if one series begins to
diverge, it is taken as preliminary evidence that the trend is weakening and
may reverse.
• Types of Divergence :
Trend Coherence and Divergence
Positive (bullish) Divergence:
Troughs Compared
Negative Divergence (peaks compared)
Divergence Rules
• The Dow theory is based on divergence analysis , if one series begins to
diverge, it is taken as preliminary evidence that the trend is weakening and
may reverse.
• Types of Divergence :
Trend Coherence and Divergence
Positive (bullish) Divergence:
Troughs Compared
Negative Divergence (peaks compared)
Divergence Rules
• The Dow theory is based on divergence analysis , if one series begins to
diverge, it is taken as preliminary evidence that the trend is weakening and
may reverse.
• Types of Divergence :
Trend Coherence and Divergence
Positive (bullish) Divergence:
Troughs Compared
Negative Divergence (peaks compared)
Divergence Indicator
• Where:
• CN= Channel normalization operator
• n= Look-back span of the channel normalization
• the channel normalized value of each series can vary between 0 and 100, this
divergence indicator has a potential range of −100 to +100.
• Limitations of the Proposed Divergence Indicator
• When the indicator registers a value of zero, it indicates that there is no divergence;
both series have the same channel normalized values and can be presumed to be
trending together.
• However, there can be cases for which a value of zero does not indicate that the two
series are in phase.
• A value of zero would be an erroneous indication that the two series are trending
together. This is clearly a limitation of the proposed divergence indicator.
Divergence Indicator
Double Channel Normalization
- The fluctuation range of the divergence indicator would vary considerably from one
pair to the next. This would make it -impractical to use the same threshold for all
pairings.
- The high threshold displacement that would be -suitable for a -companion -series
with a low degree of co-movement with the S&P 500 would never produce a signal
for a companion series with a high degree of co-movement to the S&P 500.
- For this reason, the initial formulation of the divergence indicator was deemed
impractical.
Double Channel Normalization
Divergence Indicator (Double Channel Normalization)
Where:
CN= Channel normalization operator
Series 1 = Companion series
n= Look-back span of the first channel normalization
- The modified version of the divergence indicator will have roughly the same
fluctuation range irrespective of the particular pair of time series being used,
making it practical to use uniform thresholds.
- If the channel normalization used a look-back span of 60 days, the second layer of
channel normalization used a look-back span of 600 days.
- It was assumed that a 10fold look-back span would be sufficient to establish the
fluctuation range of the basic divergence indicator.
Double Channel Normalization
Divergence Indicator (Double Channel Normalization)
Where:
CN= Channel normalization operator
Series 1 = Companion series
n= Look-back span of the first channel normalization
- The modified version of the divergence indicator will have roughly the same
fluctuation range irrespective of the particular pair of time series being used,
making it practical to use uniform thresholds.
- If the channel normalization used a look-back span of 60 days, the second layer of
channel normalization used a look-back span of 600 days.
- It was assumed that a 10fold look-back span would be sufficient to establish the
fluctuation range of the basic divergence indicator.
Double Channel Normalization
Divergence Rule Types :
- Upper and lower threshold were applied to the
modified divergence indicator to generate signals.
- A positive or bullish divergence was in effect when
the divergence indicator was above its upper
threshold.
- A negative or bearish divergence existed when the
divergence indicator was below the lower
threshold.
- A bullish divergence rule, which would call for long
positions in the S&P 500 when the divergence
indicator was above the upper threshold
- A bearish divergence rule, which would call for
short positions in the S&P 500 when the divergence
indicator was below its lower threshold.
Double Channel Normalization
- These 12 rule types are exactly the
same set used for the extreme value
and transition rules.
- This makes sense because the
modified divergence indicator is
similar to the indicator used for the E
rules because it has a fluctuation
range of 0 to 100 and has two
thresholds.
- The 12 divergence rule types,
presented , include the basic bullish
divergence (type 6), the bearish
divergence (type 7) and their
inversions (types 12 and 1).
Parameter Combinations and Naming Convention for
Divergence Rules
- Each divergence rule is defined by four parameters: type, companion
series, threshold displacement, and channel normalization look-back
span.
- There are 12 types of the divergence rules (see Table 31.4), 38
companion data series, 2 threshold displacement values—10 and 20,
and 3 look-back spans—15, 30, and 60 days. This gives a total of 2,736
divergence rules (12 × 38 × 2 × 3).
- Divergence rule, type 3, companion series 23 (positive volume index 30-
day moving average), threshold displacement = 10 (upper threshold =
60, lower threshold = 40), 30-day channel normalization look-back span.

Contenu connexe

Tendances

Forecasting exchange rates
Forecasting exchange ratesForecasting exchange rates
Forecasting exchange rates
Jaswinder Singh
 
RRN-0808 Society of Actuaries article (stock compensation) (1)
RRN-0808 Society of Actuaries article (stock   compensation) (1)RRN-0808 Society of Actuaries article (stock   compensation) (1)
RRN-0808 Society of Actuaries article (stock compensation) (1)
Michael Burgess
 

Tendances (14)

Theories of nonrandom price motion
Theories of nonrandom price motionTheories of nonrandom price motion
Theories of nonrandom price motion
 
Cmt learning objective 4 trend system part i
Cmt learning objective 4   trend system part iCmt learning objective 4   trend system part i
Cmt learning objective 4 trend system part i
 
Managing Non-Modellable Risk Factors
Managing Non-Modellable Risk FactorsManaging Non-Modellable Risk Factors
Managing Non-Modellable Risk Factors
 
Basic Concepts Valuing Earn-outs: Part II
Basic Concepts Valuing Earn-outs: Part IIBasic Concepts Valuing Earn-outs: Part II
Basic Concepts Valuing Earn-outs: Part II
 
price forecasting of diesel
price forecasting of dieselprice forecasting of diesel
price forecasting of diesel
 
Forecasting exchange rates
Forecasting exchange ratesForecasting exchange rates
Forecasting exchange rates
 
RRN-0808 Society of Actuaries article (stock compensation) (1)
RRN-0808 Society of Actuaries article (stock   compensation) (1)RRN-0808 Society of Actuaries article (stock   compensation) (1)
RRN-0808 Society of Actuaries article (stock compensation) (1)
 
Technical analysis, market efficiency, and behavioral finance
Technical analysis, market efficiency, and behavioral financeTechnical analysis, market efficiency, and behavioral finance
Technical analysis, market efficiency, and behavioral finance
 
Statistical Arbitrage
Statistical Arbitrage Statistical Arbitrage
Statistical Arbitrage
 
Security analysis
Security analysisSecurity analysis
Security analysis
 
Emh teach
Emh teachEmh teach
Emh teach
 
IRMC2016- Keynote Speech - Giovanni Barone Adesi - Lecture title: “Crude Oil ...
IRMC2016- Keynote Speech - Giovanni Barone Adesi - Lecture title: “Crude Oil ...IRMC2016- Keynote Speech - Giovanni Barone Adesi - Lecture title: “Crude Oil ...
IRMC2016- Keynote Speech - Giovanni Barone Adesi - Lecture title: “Crude Oil ...
 
Technical analysis Fundamentals
Technical analysis FundamentalsTechnical analysis Fundamentals
Technical analysis Fundamentals
 
Efficient market hypothesis
Efficient market hypothesisEfficient market hypothesis
Efficient market hypothesis
 

Similaire à Case study of s&p 500

need to realize in r studio (regression).pptx
need to realize in r studio (regression).pptxneed to realize in r studio (regression).pptx
need to realize in r studio (regression).pptx
SmarajitPaulChoudhur
 
Module 3 Identifying fraud in forensic analysis.pptx
Module 3 Identifying fraud in forensic analysis.pptxModule 3 Identifying fraud in forensic analysis.pptx
Module 3 Identifying fraud in forensic analysis.pptx
IqbalAli61
 

Similaire à Case study of s&p 500 (20)

SECTION VII - CHAPTER 41 - Objective Rules & Evaluation
SECTION VII - CHAPTER 41 - Objective Rules & EvaluationSECTION VII - CHAPTER 41 - Objective Rules & Evaluation
SECTION VII - CHAPTER 41 - Objective Rules & Evaluation
 
2. Module II (1) FRM.pdf
2. Module II (1) FRM.pdf2. Module II (1) FRM.pdf
2. Module II (1) FRM.pdf
 
need to realize in r studio (regression).pptx
need to realize in r studio (regression).pptxneed to realize in r studio (regression).pptx
need to realize in r studio (regression).pptx
 
Section I - CH 3 - System Evaluation and Testing.pdf
Section I - CH 3 - System Evaluation and Testing.pdfSection I - CH 3 - System Evaluation and Testing.pdf
Section I - CH 3 - System Evaluation and Testing.pdf
 
Risk Management - CH 3 - System Evaluation and Testing | CMT Level 3 | Charte...
Risk Management - CH 3 - System Evaluation and Testing | CMT Level 3 | Charte...Risk Management - CH 3 - System Evaluation and Testing | CMT Level 3 | Charte...
Risk Management - CH 3 - System Evaluation and Testing | CMT Level 3 | Charte...
 
Demand forecasting
Demand forecastingDemand forecasting
Demand forecasting
 
Capital Budgeting decision-making in telecom sector using real option analysis
Capital Budgeting decision-making in telecom sector using real option analysisCapital Budgeting decision-making in telecom sector using real option analysis
Capital Budgeting decision-making in telecom sector using real option analysis
 
Poster marcindecyieldcurves
Poster marcindecyieldcurvesPoster marcindecyieldcurves
Poster marcindecyieldcurves
 
AN ANALYSIS OF THE FINANCIAL PERFORMANCE EFFECT OF SHARIA COMPANIES ON STOCK ...
AN ANALYSIS OF THE FINANCIAL PERFORMANCE EFFECT OF SHARIA COMPANIES ON STOCK ...AN ANALYSIS OF THE FINANCIAL PERFORMANCE EFFECT OF SHARIA COMPANIES ON STOCK ...
AN ANALYSIS OF THE FINANCIAL PERFORMANCE EFFECT OF SHARIA COMPANIES ON STOCK ...
 
IRJET- Overview of Forecasting Techniques
IRJET- Overview of Forecasting TechniquesIRJET- Overview of Forecasting Techniques
IRJET- Overview of Forecasting Techniques
 
جعفر منصور
جعفر منصورجعفر منصور
جعفر منصور
 
Ch1_slides.ppt
Ch1_slides.pptCh1_slides.ppt
Ch1_slides.ppt
 
Ch1 slides
Ch1 slidesCh1 slides
Ch1 slides
 
Econometrics
EconometricsEconometrics
Econometrics
 
Ch1_slides.ppt
Ch1_slides.pptCh1_slides.ppt
Ch1_slides.ppt
 
Module 3 Identifying fraud in forensic analysis.pptx
Module 3 Identifying fraud in forensic analysis.pptxModule 3 Identifying fraud in forensic analysis.pptx
Module 3 Identifying fraud in forensic analysis.pptx
 
Pillar III presentation 2 27-15 - redacted version
Pillar III presentation 2 27-15 - redacted versionPillar III presentation 2 27-15 - redacted version
Pillar III presentation 2 27-15 - redacted version
 
WACC. Mng. Fin
WACC. Mng. FinWACC. Mng. Fin
WACC. Mng. Fin
 
Statistical process control
Statistical process control Statistical process control
Statistical process control
 
Economics cvp analysis
Economics cvp analysisEconomics cvp analysis
Economics cvp analysis
 

Plus de Professional Training Academy

Plus de Professional Training Academy (20)

Chapter D - Knowledge Domains and Weightings
Chapter D - Knowledge Domains and WeightingsChapter D - Knowledge Domains and Weightings
Chapter D - Knowledge Domains and Weightings
 
Lecture F - Standard VI Conflicts of Interest
Lecture F - Standard VI Conflicts of InterestLecture F - Standard VI Conflicts of Interest
Lecture F - Standard VI Conflicts of Interest
 
Lecture E - Standard V Investment Analysis, Recommendations, and Actions
Lecture E - Standard V Investment Analysis, Recommendations, and ActionsLecture E - Standard V Investment Analysis, Recommendations, and Actions
Lecture E - Standard V Investment Analysis, Recommendations, and Actions
 
Lecture D - Standard IV Duties to Employers
Lecture D - Standard IV Duties to EmployersLecture D - Standard IV Duties to Employers
Lecture D - Standard IV Duties to Employers
 
Lecture C - Standard III Duties to Clients
Lecture C - Standard III Duties to ClientsLecture C - Standard III Duties to Clients
Lecture C - Standard III Duties to Clients
 
Lecture B - Standard II Integrity of Capital Markets
Lecture B - Standard II Integrity of Capital MarketsLecture B - Standard II Integrity of Capital Markets
Lecture B - Standard II Integrity of Capital Markets
 
Lecture A - Standard I Professionalism
Lecture A - Standard I ProfessionalismLecture A - Standard I Professionalism
Lecture A - Standard I Professionalism
 
SECTION VII - CHAPTER 44 - Relative Strength Concept
SECTION VII - CHAPTER 44 -  Relative Strength ConceptSECTION VII - CHAPTER 44 -  Relative Strength Concept
SECTION VII - CHAPTER 44 - Relative Strength Concept
 
SECTION VII - CHAPTER 43 - Model Building Process
SECTION VII - CHAPTER 43 - Model Building ProcessSECTION VII - CHAPTER 43 - Model Building Process
SECTION VII - CHAPTER 43 - Model Building Process
 
SECTION VII - CHAPTER 42 - Being Right or making money
SECTION VII - CHAPTER 42 - Being Right or making moneySECTION VII - CHAPTER 42 - Being Right or making money
SECTION VII - CHAPTER 42 - Being Right or making money
 
SECTION VI - CHAPTER 40 - Concept of Probablity
SECTION VI - CHAPTER 40 - Concept of ProbablitySECTION VI - CHAPTER 40 - Concept of Probablity
SECTION VI - CHAPTER 40 - Concept of Probablity
 
SECTION VI - CHAPTER 39 - Descriptive Statistics basics
SECTION VI - CHAPTER 39 - Descriptive Statistics basicsSECTION VI - CHAPTER 39 - Descriptive Statistics basics
SECTION VI - CHAPTER 39 - Descriptive Statistics basics
 
SECTION V- CHAPTER 38 - Sentiment Measures from External Data
SECTION V- CHAPTER 38  - Sentiment Measures from External  DataSECTION V- CHAPTER 38  - Sentiment Measures from External  Data
SECTION V- CHAPTER 38 - Sentiment Measures from External Data
 
SECTION V - CHAPTER 37 - Sentiment Measures from Market Data
SECTION V - CHAPTER 37 - Sentiment Measures from Market DataSECTION V - CHAPTER 37 - Sentiment Measures from Market Data
SECTION V - CHAPTER 37 - Sentiment Measures from Market Data
 
SECTION V - CHAPTER 36 - Market Sentiment & Technical Analysis
SECTION V - CHAPTER 36 - Market Sentiment & Technical AnalysisSECTION V - CHAPTER 36 - Market Sentiment & Technical Analysis
SECTION V - CHAPTER 36 - Market Sentiment & Technical Analysis
 
SECTION V - CHAPTER 35 - Academic Approaches to Technical Analysis
SECTION V - CHAPTER 35 - Academic Approaches to Technical AnalysisSECTION V - CHAPTER 35 - Academic Approaches to Technical Analysis
SECTION V - CHAPTER 35 - Academic Approaches to Technical Analysis
 
SECTION V - CHAPTER 34 - Noise Traders as technical Traders.pdf
SECTION V - CHAPTER 34 - Noise Traders as technical Traders.pdfSECTION V - CHAPTER 34 - Noise Traders as technical Traders.pdf
SECTION V - CHAPTER 34 - Noise Traders as technical Traders.pdf
 
SECTION V - CHAPTER 33 - Noise Traders & Law of One Price
SECTION V - CHAPTER 33 - Noise Traders & Law of One PriceSECTION V - CHAPTER 33 - Noise Traders & Law of One Price
SECTION V - CHAPTER 33 - Noise Traders & Law of One Price
 
SECTION V - CHAPTER 32 - Forerunners to Behavioural Finance.pdf
SECTION V - CHAPTER 32 - Forerunners to Behavioural Finance.pdfSECTION V - CHAPTER 32 - Forerunners to Behavioural Finance.pdf
SECTION V - CHAPTER 32 - Forerunners to Behavioural Finance.pdf
 
SECTION V - CHAPTER 31 - EMH Basics
SECTION V - CHAPTER 31 - EMH BasicsSECTION V - CHAPTER 31 - EMH Basics
SECTION V - CHAPTER 31 - EMH Basics
 

Dernier

1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
kauryashika82
 

Dernier (20)

Micro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdfMicro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdf
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptx
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
 
ICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptxICT Role in 21st Century Education & its Challenges.pptx
ICT Role in 21st Century Education & its Challenges.pptx
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan Fellows
 
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
Explore beautiful and ugly buildings. Mathematics helps us create beautiful d...
 
Asian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptxAsian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptx
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
 
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POS
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
Spatium Project Simulation student brief
Spatium Project Simulation student briefSpatium Project Simulation student brief
Spatium Project Simulation student brief
 
psychiatric nursing HISTORY COLLECTION .docx
psychiatric  nursing HISTORY  COLLECTION  .docxpsychiatric  nursing HISTORY  COLLECTION  .docx
psychiatric nursing HISTORY COLLECTION .docx
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdf
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptx
 

Case study of s&p 500

  • 1. Case Study of Rule Data Mining for the S&P 500
  • 2. Data Mining Bias and Rule Evaluation • Data mining is a process in which the profitability of many rules is compared so that one or more superior rules can be selected. • The observed performance of the best rule(s) in the back test overstates its (their) expected performance in the future. • This bias complicates the evaluation of statistical significance and may lead a data miner to select a rule with no predictive power • This problem can be minimized by using specialized statistical-inference tests. The case study illustrates the application of two such methods: an enhanced version of White's reality check and Masters' Monte-Carlo permutation method.
  • 3. Data Mining Bias and Rule Evaluation Avoidance of Data Snooping Bias Analyzed Data Series Technical Analysis Themes Performance Statistic: Average Return No Complex Rules Were Evaluated
  • 4. Avoidance of Data Snooping Bias • The data snooping bias is a statistical bias that appears when exhaustively searching for combinations of variables, the probability that a result arose by chance grow with the number of combinations tested. • In order to minimize the probability that our results occurred simply by chance, we can divide that data that we used in the back testing process into 2 samples. • The first one is called the in-sample and it is the data sample that will be used to back test all the combinations that result from the initial trading rules. • The second one is called out-of-sample and it is used as a way to test the best performing rules (the one that were picked from the in-sample back testing) on new data.
  • 5. The Case Study Defined in Statistical Terms • The case study in terms of the key elements of a statistical study • The Population: The population at issue is the set of daily returns that would be earned by a rule if its signals were to be applied to the S&P 500 over all possible realizations of the immediate practical future • Population Parameter : The population parameter is the rule's expected average annualized return in the immediate practical future. • The Sample : The sample consists of the daily returns earned by a rule applied over the back-test period • Sample Statistic (Test Statistic) : The sample statistic is the average annualized return earned by a rule when applied • The Null Hypothesis (H0): The null hypothesis states that all 6,402 rules tested are without predictive power. This implies that any observed profits in a back test were due to chance (sampling variability). • The Alternative Hypothesis : alternative hypothesis asserts that a rule's back-tested profitability systems from genuine predictive power • The Statistical Significance Level: A 5 percent level of significance was chosen as a threshold for rejection of the null hypothesis. This means there was a 0.05 probability of rejecting the H0 hypothesis when the H0 was, in fact, true. • Practical Significance : practical significance relates to the economic value of the observed rule return.
  • 6. Rules: Transforming Data Series into Market Positions • A rule is an input/output process. • Transforms input(s), consisting of one or more time series, into an output, a new time series consisting of +1's and −1's that indicate long and short positions in the market being traded (i.e., S&P 500). TA Rule Transforms Input into Output. Raw Market Time Series as Rule Input.
  • 7. Rules: Transforming Data Series into Market Positions • Other rules utilize input series that have been derived from one or more raw market series by applying various transformations to the market data. • These preprocessed inputs are referred to as constructed data series or indicators. • An example of an indicator is the negative volume index. It is derived from transformations of two raw data series; S&P 500 closing price and total NYSE daily volume • The transformations used in the creation of the negative volume index and other indicators used in the case study are described in the following section.
  • 8. Time-Series Operators Channel Breakout Operator (CBO) Moving-Average Operator (MA) Channel- Normalization Operator (Stochastics): CN Indicator Scripting
  • 9. Input Series to Rules: Raw Time Series and Indicators Price and volume functions Market- Breadth Indicators Prices-of- debt instruments Interest-rate- spread indicators
  • 10. Price and Volume Functions • Technical analysis practitioners have suggested a number of price and volume functions: on-balance volume, accumulation distribution volume, money flow, negative volume, and positive volume. • The price-volume functions were used to create two types of indicators: • (1) Cumulative Sums : Cumulative sum is the algebraic sum of all prior daily values of the price-volume function. The daily value of a price-volume function can either be a positive or negative quantity. Thus, an indicator defined as the cumulative sum of the on-balance volume • (2) Moving Averages : Moving average of a price-volume function will be a stationary time series. Moving average only considers the observations within the look-back span. Since price and volume functions can assume both positive or negative values, a moving average will tend to remain within a relatively confined range near zero.
  • 11. Price and Volume Functions Cumulative On- Balance Volume Moving Averages of On-Balance Volume Cumulative Accumulation- Distribution Volume (CADV) Moving Averages of Accumulation Distribution Volume Cumulative Money Flow (CMF) Moving Averages of Money Flow Cumulative Negative Volume Index (CNV) Moving Averages of Negative Volume Index Cumulative Positive Volume Index (CPV) Moving Averages of Positive Volume
  • 12. Market Breadth Indicators • Market breadthrefers to the spread or difference between the number of stocks advancing and the number declining on a given day, week, or other defined time interval. • Breadth indicators are of two forms: cumulative sums of daily figures and moving averages of daily figures • Breadth indicators that are cumulative sums display long-term trends, whereas moving-average breadth indicators tend to have reasonably stable mean values and fluctuation ranges.
  • 13. Market Breadth Indicators Cumulative Advance-Decline Ratio (CADR) Moving Averages of Advance- Decline Ratio Cumulative Net Volume Ratio (CNVR) Moving Averages of Net Volume Ratio Cumulative New Highs-Lows Ratio (CHLR) Moving Averages of New Highs/New Lows Ratio (HLR1 and HLR30)
  • 14. Prices-of-Debt Instruments from Interest Rates • Interest rates and stock price levels move inversely. • Taking the reciprocal (1/interest rate) interest rates can be transformed into price-like time series that are, in general, positively correlated with stock prices. • This reciprocal series can be multiplied by a scaling factor such as 100. Thus, a rate of 6.05 percent would be equivalent to a price of 15.38 (1/6.05 × 100). • Case study and was performed on four interest rate series: threemonth treasury bills, 10-year treasury bonds, Moody's AAA corporate bonds, and Moody's BAA corporate bonds.
  • 15. Interest Rate Spreads • An interest-rate spread is the difference between two comparable interest rates. • Two types of interest-rate spreads were constructed for the case study; • The durationspread : The duration spread, also known as the slope of the yield curve, is the difference between yields on debt instruments having the same credit quality but having different durations (i.e., time to maturity). The duration spread used in the case study was defined as the yield on the 10-year treasury note minus the yield on the three-month treasury bills (10-year yield minus 3-month yield). • The qualityspread: A quality spread measures the difference in yield between instruments with similar durations but with different credit qualities (default risk). The quality spread for the case study was based on two of Moody's38long-term corporate bond series: AAA,39which are the highest rated corporate debt, and BAA,40a lower rated grade of corporate debt. The quality spread is defined here as AAA yield −BAA yield.
  • 17. Trends • Foundational principle of TA is that prices and yields move in trends that can be identified in a sufficiently timely manner to generate profits. • Most widely used are moving averages, moving-average bands, channel breakout, and Alexander filters also known as zigzag filters. • CBO operator transformed the input time series into a binary valued time series consisting of +1 and −1. • When the trend of the input series was in an uptrend, as determined by the CBO, the rule's output was +1. • Conversely, when the analyzed series was determined to be in a downtrend, the output was −1. • The identification of trend reversals in the input series by CBO is subject to lag. • All trend indicators necessarily incur lag—a delay between the time the input series experiences a trend reversal and the time the operator is able to detect it. Lag can be reduced by making the indicator more sensitive
  • 18. Extreme Values and Transitions • “Extreme Values and Transitions” or Erules is based on the notion that a time series conveys information when it assumes an extreme high or low value or as it makes the transition between extremes. • High and low extremes can be defined in terms of fixed value thresholds if the time series has a relatively stable mean and fluctuation range (i.e., is stationary). All input series used for E rules were made stationary by applying the CN operator. • E rules is given by the expression:=CN (LMA (Input Series, 4), N-days)Where:CN is the channel normalization operatorLMA is a linearly weighted moving-average operator
  • 19. Extreme Values and Transitions • E-rule signals were generated when the channel normalized smoothed series crossed a threshold. • Given that there are two thresholds, an upper and lower, and given that there are two directions in which a crossing can occur (up or down) • Four possible threshold-crossing events: • 1.Lower threshold is crossed in the downward direction. • 2.Lower threshold is crossed in the upward direction. • 3.Upper threshold is crossed in the upward direction. • 4.Upper threshold is crossed in the downward direction. • Each E rule was defined in terms of two threshold- crossing events: • one specifying the long entry/short exit and the other specifying the short entry/long exit
  • 20. Extreme Values and Transitions Types 1 Types 2 Types 4 Types 3 Types 5
  • 21. Extreme Values and Transitions Types 9 Types 7 Types 8 Types 10 Types 11 Types 6 Types 12
  • 22. Divergence Rules • A divergence is said to occur when one member of the pair departs from their shared trend. • A divergence manifests itself as follows: both series have been trending in the same direction, but then one series reverses its prior trend while its companion continues its prior trend. • Divergence analysis, is a potential signal that the prior shared trend has weakened and may be about to reverse.
  • 23. Divergence Rules • The Dow theory is based on divergence analysis , if one series begins to diverge, it is taken as preliminary evidence that the trend is weakening and may reverse. • Types of Divergence : Trend Coherence and Divergence Positive (bullish) Divergence: Troughs Compared Negative Divergence (peaks compared)
  • 24. Divergence Rules • The Dow theory is based on divergence analysis , if one series begins to diverge, it is taken as preliminary evidence that the trend is weakening and may reverse. • Types of Divergence : Trend Coherence and Divergence Positive (bullish) Divergence: Troughs Compared Negative Divergence (peaks compared)
  • 25. Divergence Rules • The Dow theory is based on divergence analysis , if one series begins to diverge, it is taken as preliminary evidence that the trend is weakening and may reverse. • Types of Divergence : Trend Coherence and Divergence Positive (bullish) Divergence: Troughs Compared Negative Divergence (peaks compared)
  • 26. Divergence Indicator • Where: • CN= Channel normalization operator • n= Look-back span of the channel normalization • the channel normalized value of each series can vary between 0 and 100, this divergence indicator has a potential range of −100 to +100. • Limitations of the Proposed Divergence Indicator • When the indicator registers a value of zero, it indicates that there is no divergence; both series have the same channel normalized values and can be presumed to be trending together. • However, there can be cases for which a value of zero does not indicate that the two series are in phase. • A value of zero would be an erroneous indication that the two series are trending together. This is clearly a limitation of the proposed divergence indicator.
  • 28. Double Channel Normalization - The fluctuation range of the divergence indicator would vary considerably from one pair to the next. This would make it -impractical to use the same threshold for all pairings. - The high threshold displacement that would be -suitable for a -companion -series with a low degree of co-movement with the S&P 500 would never produce a signal for a companion series with a high degree of co-movement to the S&P 500. - For this reason, the initial formulation of the divergence indicator was deemed impractical.
  • 29. Double Channel Normalization Divergence Indicator (Double Channel Normalization) Where: CN= Channel normalization operator Series 1 = Companion series n= Look-back span of the first channel normalization - The modified version of the divergence indicator will have roughly the same fluctuation range irrespective of the particular pair of time series being used, making it practical to use uniform thresholds. - If the channel normalization used a look-back span of 60 days, the second layer of channel normalization used a look-back span of 600 days. - It was assumed that a 10fold look-back span would be sufficient to establish the fluctuation range of the basic divergence indicator.
  • 30. Double Channel Normalization Divergence Indicator (Double Channel Normalization) Where: CN= Channel normalization operator Series 1 = Companion series n= Look-back span of the first channel normalization - The modified version of the divergence indicator will have roughly the same fluctuation range irrespective of the particular pair of time series being used, making it practical to use uniform thresholds. - If the channel normalization used a look-back span of 60 days, the second layer of channel normalization used a look-back span of 600 days. - It was assumed that a 10fold look-back span would be sufficient to establish the fluctuation range of the basic divergence indicator.
  • 31. Double Channel Normalization Divergence Rule Types : - Upper and lower threshold were applied to the modified divergence indicator to generate signals. - A positive or bullish divergence was in effect when the divergence indicator was above its upper threshold. - A negative or bearish divergence existed when the divergence indicator was below the lower threshold. - A bullish divergence rule, which would call for long positions in the S&P 500 when the divergence indicator was above the upper threshold - A bearish divergence rule, which would call for short positions in the S&P 500 when the divergence indicator was below its lower threshold.
  • 32. Double Channel Normalization - These 12 rule types are exactly the same set used for the extreme value and transition rules. - This makes sense because the modified divergence indicator is similar to the indicator used for the E rules because it has a fluctuation range of 0 to 100 and has two thresholds. - The 12 divergence rule types, presented , include the basic bullish divergence (type 6), the bearish divergence (type 7) and their inversions (types 12 and 1).
  • 33. Parameter Combinations and Naming Convention for Divergence Rules - Each divergence rule is defined by four parameters: type, companion series, threshold displacement, and channel normalization look-back span. - There are 12 types of the divergence rules (see Table 31.4), 38 companion data series, 2 threshold displacement values—10 and 20, and 3 look-back spans—15, 30, and 60 days. This gives a total of 2,736 divergence rules (12 × 38 × 2 × 3). - Divergence rule, type 3, companion series 23 (positive volume index 30- day moving average), threshold displacement = 10 (upper threshold = 60, lower threshold = 40), 30-day channel normalization look-back span.