This indicator will automatically calculate fib ratios for the 4-segment harmonic patterns and display them on the chart.
How it works:
1) Draw trend lines (uncheck ray option) to represent the XA,AB,BC,CD segments of the pattern.
**Make sure the segments are drawn from left to right
**Make sure the vertices are properly positioned in the pattern (eg. vertex A cannot be to the left of vertex X)
**Make sure the vertices are properly connected (the best way is to have them stick to candle's high,low,open,close)
2) Edit and rename the segments as XA_#,AB_#,BC_#,CD_#, where # is a unique integer to represent this pattern (Harmonic_Pattern_No)
3) Insert the indicator (if not already inserted) and set the parameter (Harmonic_Pattern_No.) to the value #, and parameter (Active) to true
The indicator will draw and label the ratios and dotted lines. The indicator refreshes at every tick received from broker. During weekend, the indicator must be refreshed manually.
If you modify the segments, the indicator will update the ratios as soon as it confirms that the segments are drawn properly as mentioned above. Otherwise, error message appears in upper right corner.
If you draw another harmonic pattern with another unique #, then just change the Harmonic_Pattern_No. parameter in order to calculate and label the new pattern.
Vertices do not have to be attached to candlesticks. They can be moved around and the ratios will be updated at every tick, as long as the segments are properly connected. Otherwise, error message appears in upper right corner.
Minor Bug: the candles for the weekend are truncated and therefore, some of the ratio labels may not be positioned properly.
Future plans:
**modify the indicator to sweep the chart and update all harmonic patterns without specifying the value # in the indicator parameters.
How it works:
1) Draw trend lines (uncheck ray option) to represent the XA,AB,BC,CD segments of the pattern.
**Make sure the segments are drawn from left to right
**Make sure the vertices are properly positioned in the pattern (eg. vertex A cannot be to the left of vertex X)
**Make sure the vertices are properly connected (the best way is to have them stick to candle's high,low,open,close)
2) Edit and rename the segments as XA_#,AB_#,BC_#,CD_#, where # is a unique integer to represent this pattern (Harmonic_Pattern_No)
3) Insert the indicator (if not already inserted) and set the parameter (Harmonic_Pattern_No.) to the value #, and parameter (Active) to true
The indicator will draw and label the ratios and dotted lines. The indicator refreshes at every tick received from broker. During weekend, the indicator must be refreshed manually.
If you modify the segments, the indicator will update the ratios as soon as it confirms that the segments are drawn properly as mentioned above. Otherwise, error message appears in upper right corner.
If you draw another harmonic pattern with another unique #, then just change the Harmonic_Pattern_No. parameter in order to calculate and label the new pattern.
Vertices do not have to be attached to candlesticks. They can be moved around and the ratios will be updated at every tick, as long as the segments are properly connected. Otherwise, error message appears in upper right corner.
Minor Bug: the candles for the weekend are truncated and therefore, some of the ratio labels may not be positioned properly.
Future plans:
**modify the indicator to sweep the chart and update all harmonic patterns without specifying the value # in the indicator parameters.
Attached File(s)
Harmonic_Ratios.mq4
17 KB
|
2,707 downloads