This indicator is intended for trend, support and resistance lines formation based on ZigZag extremums traversal.
Indicator builds straight lines passing through latest ZigZag extremums and detects their crossing with future prices generating a buy or sell breakout signal. One of built-in ZigZag indicators can be used as an engine.
- Parameter1 - the first parameter passed to a selected ZigZag engine; default value - 7, suitable for 0th default engine AlexSTAL_ZigZagProf;
- Parameter2 - the second parameter passed to a selected ZigZag engine; default value - 5, suitable for 0th default engine AlexSTAL_ZigZagProf;
- Shift - number of bar to take signal from; default value - 0 (current bar, which may not be finished yet and continue updating); set to 1 to use the 1st (finished) bar's close price;
- Last_Bars - number of bars to process; default value - 1 000;
- EngineSelector - a number to select one of available ZigZag engines: 0 (default) - AlexSTAL_ZigZagProf; 1 - HZZM;
- Conservative - enable/disable conservative mode of signal generation (find details below); default - true.
The indicator shows straight lines between the latest stable extremums: dark blue dashed lines are upper trend line, and dark red dashed lines are bottom trend lines. They continue in future as dark blue and dark red bulleted lines. When price crosses these lines, a breakout signal can be generated depending from Conservative parameter setting. In the conservative mode, price should be above both blue and red trends to generate buy signal, and price should be below both red and blue trends to generate sell signal. The signals are shown as blue and red arrows. If conservative mode is disabled, buy signal is generated when price is above blue trend and ZigZag direction is up, and sell signal is generated below red trend when ZigZag direction is down.
When AlexSTAL_ZigZagProf is selected as an engine, two first parameters are ExtPeriod and MinAmplitude of this indicator - please consult with its description for details. Default values are 7 and 5, correspondingly.
When HZZM is selected as an engine, the first two parameters are H and MinBars of this indicator - please consult with HZZM description for details. Values 0 and 0 are OK to test.