Zigzag & Fibonacci Levels: Indicator for Detecting Key Market Levels

Zigzag & Fibonacci Levels: Indicator for Detecting Key Market Levels

The Zigzag & Fibonacci Levels indicator is a powerful tool that combines the identification of market reversal points through the Zigzag and the projection of Fibonacci levels to anticipate possible support and resistance zones.

This article explores in detail how this indicator works, how to configure it, and how it can benefit traders in their technical analysis.

Description of the Zigzag Indicator

The Zigzag indicator is fundamental in technical analysis for identifying trend changes by eliminating market “noise.” This indicator draws lines that connect significant high and low points, filtering minor movements based on a percentage variation or absolute highest or lowest value.

Key Parameters:

  • ZZpercent: Defines the method of Zigzag calculation (percentage or value).
  • prd: Period for calculating high and low values.
  • percent: Percentage change for Zigzag in percentage mode.

Calculation of Pivots High & Low

The indicator identifies high (pivots high) and low (pivots low) points in two ways:

  • Percent Mode: Uses percentage variation to determine pivots.
  • Value Mode: Uses the highest and lowest values over a specified period (prd).

Calculation of Direction and Direction Changes

Once the pivots are identified, the indicator determines the current trend direction:

  • dir = 1 indicates an uptrend.
  • dir = -1 indicates a downtrend.

Arrays for Each Pivot

The indicator stores the pivots and their direction in arrays, allowing precise tracking of the Zigzag points:

Drawing Zigzag Segments and Fibonacci Levels

The indicator draws the Zigzag segments and calculates the Fibonacci levels based on the trend direction:

Visualization Configuration

The indicator allows customizing the visualization of past Fibonacci levels and adjusting the colors and styles of the lines for better visual interpretation.

Conclusion

The Zigzag & Fibonacci Levels indicator combines two powerful tools of technical analysis to provide a clear view of key market levels. By using this indicator, traders can more accurately identify reversal points and anticipate possible support and resistance zones.

ZigZag & Fibonacci Levels Code:

Share this

Risk disclosure:

No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.

ProRealTime ITF files and other attachments : How to import ITF files into ProRealTime platform?

PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials

  1. Fgats • 13 hours ago #

    Ivan can you please explain a line of code that is puzzling me. This is line 37 . As I understand, either the value of dir is updated on line 33 or 35 or it remains unchanged so what can line 37 be used for? Thank you for your explanations and thank you for all the codes that you share here with us. Gabriel

avatar
Register or

Likes

avatar avatar avatar avatar avatar
Related users ' posts
philippe59139 Bravo super travail
gidien
5 months ago
gidien Thanks for the hint. I think i know now, why this happen. The "settings" block was added by ...
LucasBest Thank you for sharing your work, both original and very disconcerting. When I went through t...
gidien Hello LucasBest, thanks for your comment. Point 1: Yes your are right. The Zigzag ve...
Nicolas Il doit y avoir impérativement plus d'unités affichées que le paramètre "BarsLimit". Ceci ét...
steffen_burat Hello Nicolas, I have a cumulative histogram update problem, the indicator often updates ...
taklause Hello Nicolas, if I try to use your indicator in a trading system, the error on prc pops up ...
jonpt88 hI . THIS LOOKS GOOD. Thanks. Just one doubt: is this kind of impulse indicator - does it sh...
effegi
1 year ago
effegi A good alternative solution, even I had thought of the variant that uses high and low (proba...
Seb did you automate that 1-2-3 strategy? how is that working for you?
effegi Not yet, I'm busy developing other strategies/indicators at the moment, but it's on my to-do...
StephFor //ind1 = ZigZagPoint[2*averagetruerange[200]](close) avr = 3 //3% ind1 = ZigZag[avr](close...
Manu L. @Steph un grand merci pour ton aide mais :-( J'ai copier le code tel quel mais cependant j...
AlphaMauss Je n'ai pas réussi à faire fonctionner l'indicateur avec le code fourni en commentaire sur P...
Meta Signals Pro Pleasure ! Please let us know if you make good trades with it and if you see improvements we...
francis59 Bonjour, Bonjour, comment puis-je créer un screener basé sur cet indicateur, qui affiche le...
Trader Sab I am curious to try it how, however I get an error message for line 47 and 48 - drawsegment,...
datageek How do I change the thickness of the line or change it too dashed lines? Kind regards
lkiklkik NE fonctionne pas ( ou plus ... )
Nicolas il faut modifier toutes les références à top par itop et bottom par ibottom. Ces mots étant ...
teddy58 Ich habe es mit N= 1,5 und N=2,5 getestet mit 200000 Einheiten. Es funktioniert leider erst ...
Matriciel I use this indicator to help me make a decision when there is a divergence. The divergences ...
Jan Wind Hi, I personnaly am not a big fan of ZIGZAG indicator, as it repaints itself during time. ...
Nicolas Sure, I suggest you open a new topic in the forum to discuss about your ideas.
hdgm Bonjour Nicolas, est ce que l'on peut en faire une stratégie de trading automatisée ?
Nicolas Non, pas en utilisant l'indicateur zigzag traditionnel de la plateforme.
TACBOLSA
6 years ago
Tradingrob Hi Tac Bolsa, thanks for the information. But after carefully ready all the material i still...
TAC Bolsa Hello, the indicator creates the support depending on the volume and is dynamic.
carlvan Not working on PRT 11.1. And the site https://www.tiburonesdealetacorta.com does not exist....
rama I want to use this indicator in trading system, it says zig zag is obsolete and not supported
Nicolas Right, due to its repainting behavior, the zigzag is not allowed in automated trading with r...
rama I noticed it changes as time progress, I am 7 as the average, how many period it wont chang...
Vonasi The indicator code can easily be adapted for use as a filter in strategies as well. For exam...
AVT Tested today in manual DAX trading (transcripted to MT and changed look into aka oszillator)...
Vonasi I think that short time frame charts will be too noisy for this indicator. One blue bar real...
Vonasi I forgot to mention in the description that Sunday pivot lines are ignored and Monday's pivo...
AVT Like that, simple and clear!
Vonasi Thanks AVT. I like simple - some people would say that I do simple very well! Sometimes you ...
Paul Thanks for posting. I was currently searching how to improve day-trading based on support an...
Jessar Könntest du im Forum etwas öffnen und später darüber zu sprechen?
arahussein Hi All, I am new to trading and i find this indicator very logicail! Hence my (dumb?) quest...
zilliq Be careful, It works only if you are in daily timeframe, and on your graphic you are on hou...
DerPat I guess you are right, like always. If you change n to 24 you have at least the hours of a d...
gabri DerPat, you can also change line1 to read as follow to adapt this script to hourly timefram...
Nicolas
8 years ago
Nicolas add it on price chart, change the cp parameter according to the period you want to observe f...
Robert22 hola buenos días: yo estoy buscando una cosa parecida para realizar con ello un indicador de...
Nicolas https://www.prorealcode.com/prorealtime-indicators/rsi-classical-hidden-divergences-indicator/

Top