In tutorial 60 I demonstrated how to create an EasyLanguage program that looked for consecutive CCI high or low pivots, drew a trend line and then flagged when the trend line was broken by the CCI.
A member of the Markplex Gold Pass membership requested that I create a tutorial that showed how to add a component that looked for divergence to the tutorial 60 program.
I demonstrate how to create a TradeStation EasyLanguage program to look for, what I have called, simple divergence (in other words we just look at the prices at the CCI pivots, which may not necessarily be price pivots, check out tutorial 4 for more information about this methodology). If consecutive CCI pivots make a higher lows and the prices at the same bars as the CCI pivots make lower lows then we say that we have a potential ‘bullish’ divergence. If consecutive CCI pivots make a lower high and the prices at the same bars as the pivots make higher highs then we say that we have a potential ‘bearish’ divergence. I explain this in the video below. Remember that pivots are not confirmed until RightStrength bars after the pivot, and so divergence is confirmed RightStrength bars after the second pivot as well.
Since the CCI trend line break may not necessarily occur on the same bar as the bullish or bearish divergence is confirmed, I show how to create a counter such that the trend line breaks are only highlighted by the thicker line and the ‘X’ drawn on the chart if the break occurs within a user input number of bars after a divergence is confirmed.
The program described in this tutorial is available for immediate download for $49.95. The downloaded program has additional comments added and has been formatted. It was created in TradeStation 9.0 and will work on this version or higher. Click on the following button:
If you need to know how to apply the indicator to a sub chart so that the trend lines are visible see the third video on the tutorial 60 page.
Video demonstrating adding divergence detection to CCI trend line break program
The program described in this tutorial is available for immediate download for $49.95. The downloaded program has additional comments added and has been formatted. It was created in TradeStation 9.0 and will work on this version or higher version numbers. Click on the following button:
Please email me at martyn.whittaker@markplex.com if you spot any bugs or errors.
TO THE BEST OF MARKPLEX CORPORATION’S KNOWLEDGE, ALL OF THE INFORMATION ON THIS PAGE IS CORRECT, AND IT IS PROVIDED IN THE HOPE THAT IT WILL BE USEFUL. HOWEVER, MARKPLEX CORPORATION ASSUMES NO LIABILITY FOR ANY DAMAGES, DIRECT OR OTHERWISE, RESULTING FROM THE USE OF THIS INFORMATION AND/OR PROGRAM(S) DESCRIBED, AND NO WARRANTY IS MADE REGARDING ITS ACCURACY OR COMPLETENESS. USE OF THIS INFORMATION AND/OR PROGRAMS DESCRIBED IS AT YOUR OWN RISK.
ANY EASYLANGUAGE OR POWERLANGUAGE TRADING STRATEGIES, SIGNALS, STUDIES, INDICATORS, SHOWME STUDIES, PAINTBAR STUDIES, PROBABILITYMAP STUDIES, ACTIVITYBAR STUDIES, FUNCTIONS (AND PARTS THEREOF) AND ASSOCIATED TECHNIQUES REFERRED TO, INCLUDED IN OR ATTACHED TO THIS TUTORIAL OR PROGRAM DESCRIPTION ARE EXAMPLES ONLY, AND HAVE BEEN INCLUDED SOLELY FOR EDUCATIONAL PURPOSES. MARKPLEX CORPORATION. DOES NOT RECOMMEND THAT YOU USE ANY SUCH TRADING STRATEGIES, SIGNALS, STUDIES, INDICATORS, SHOWME STUDIES, PAINTBAR STUDIES, PROBABILITYMAP STUDIES, ACTIVITYBAR STUDIES, FUNCTIONS (OR ANY PARTS THEREOF) OR TECHNIQUES. THE USE OF ANY SUCH TRADING STRATEGIES, SIGNALS, STUDIES, INDICATORS, SHOWME STUDIES, PAINTBAR STUDIES, PROBABILITYMAP STUDIES, ACTIVITYBAR STUDIES, FUNCTIONS AND TECHNIQUES DOES NOT GUARANTEE THAT YOU WILL MAKE PROFITS, INCREASE PROFITS, OR MINIMIZE LOSSES.