Do not make trading decisions on color alone
Orange represents agreement between the periods. It is not an assessment that the trade is more favorable than blue or red.
Checks whether a fractal confirmed on 5 bars is also the highest high or lowest low over the specified number of bars. The results for the 2 periods are color-coded, and a round dot is placed on the confirmation bar 2 bars after the center.
Orange: both in the same directionPoints where Depth 1 and Depth 2 both met the high-side condition or both met the low-side condition.
Red and blue: one-sided resultsRed adopts the Depth 2 result; blue means Depth 2 has no result and only Depth 1 has one. Red also includes the special case where the two directions conflict.
Dot position is measured from the center priceOn the low side the dot is Distance below the center bar's low; on the high side it is above the center bar's high. It is not based on the high/low of the confirmation bar where it is output.
Compares the default settings and a settings change example on a screen with only this product applied.
Example shown: M1. This is an example for explaining the display. The published images are screens from before the brand display was added. The calculation and drawing conditions are the same, and the packaged version has display settings for the brand text and the QR code. The settings change example is not a recommended value. Details can be checked in the full-size view. Please also check the price scale of the main chart and the positions of the candlesticks.
Orange represents agreement between the periods. It is not an assessment that the trade is more favorable than blue or red.
A fractal needs 2 bars on each side. By default, output goes to the confirmation bar after the 2nd bar on the right has closed.
Depth is the number of bars used in the calculation; Distance is a display value that offsets the dot from the price.
Combines the extreme over the past Depth bars including the center bar with a strict fractal that uses 2 bars on each side. It is not a product that reproduces ZigZag lines or forming candidates.
If the center low is lower than all the lows of the 2 bars on each side, it is the low side; if the high is higher than all of them, it is the high side. If it equals a surrounding value, it is not a fractal on that side.
Checks whether the center is the lowest low or highest high over the past Depth bars ending at the center. This extreme check allows ties. The 2 bars after it are used to confirm the fractal and are not included in the Depth range.
Orange if both periods agree in direction. Otherwise red if Depth 2 has a result. Otherwise blue if Depth 1 has a result. Each bar outputs only one color.
Adds or subtracts Distance × the symbol's point to or from the price. A point is the smallest display unit and is not necessarily a pip. The multiplier does not change automatically when you change the timeframe.
See the color differences with Depth 1=6 and Depth 2=24.
The fractal center is 2 bars before the dot's bar. Check the reference price used for placing the dot above or below.
Depth 2=0 disables check 2, and only the blue dots of check 1 are used.
Compare with the example where Depth is set to 3 and 48. You can also set them so that their sizes are swapped, but the colors are still read by input number.
| Included file | Purpose / location |
|---|---|
| TRI_ZigZag_Fractal_Marks.ex5 | The MT5 main file. Place it in MQL5/Indicators. |
The ZIP contains only 1 item, the main file. The manual is opened from the product page on the site. Source code is not included. MT5 only; registration, account authentication and placing a license file are not required. Use it without changing the file name.
Extract the ex5 main file rather than leaving it in the compressed file.
In MT5, open MQL5/Indicators from 'File → Open Data Folder' and place the included ex5 there.
Refresh the Navigator or restart MT5, and apply it to the target chart. When comparing different settings, using separate charts makes checking easier.
First check with the default values. Changes and removal are done from the chart's 'Indicators List'.
Using this product does not require allowing DLLs. When removed, this product's drawings are cleared.
There are 8 inputs. Change them on the Inputs tab of the properties. The English item names and input names defined in the source are shown together.
InpDepth1InpDepth2InpDistanceInpClosedBarsOnlyInpTriBrandShowInpTriBrandCornerInpTriBrandXInpTriBrandYThe statement that confirmed output is not moved is limited to cases where new bars are added with the same history and the same settings. It does not guarantee the same results after history corrections, additional loading or input changes.
With Closed Bars Only=false, whether a fractal forms changes with the high and low of the latest bar, and the latest dot can change or disappear.
If Depth 1 and Depth 2 are the same, evaluations in the same direction are combined into orange. Red and blue are not always shown.
The match with ZigZag candidates that are redrawn later is replaced with a condition that the center is the extreme within the period. There is no Deviation, Backstep or automatic display distance per timeframe.
The display is a record of calculation results. It does not direct trading decisions and does not guarantee future price movements.
Both a strict fractal with 2 bars on each side and an extreme within Depth are required. Check the history and settings.
Normally it is a check-2-only result, but when the same center has both a high and a low fractal and the two periods differ in direction, check 2 also takes priority and it becomes red.
The price difference between the center price and the output bar, or Distance, can be the cause. Adjust the vertical axis and the display range.
Use integers: Depth 1 from 2 to 1000, Depth 2 either 0 or 2 to 1000, and Distance 0 to 100000.
If the first display does not appear, check history loading and the input ranges. If an earlier display has stopped updating, first check the price feed and the terminal's connection status.
If the center in the time series is c, the output is at t=c+2. The low side is low[c]−Distance×point and the high side is high[c]+Distance×point. By default it also requires bar t to have closed.
Within each Depth, the low side is checked first, and if it is met it is adopted. If the low side is not met, the high side is checked. If the adopted direction differs between the periods, Depth 2 takes priority.
0 is Both Depths (orange), 1 is Depth 2 Only (red), 2 is Depth 1 Only (blue). An empty value is not a zero value.
The M1 on the screen is the timeframe shown when the display example was made. The main interval of the fixed data is 30 minutes, so the image does not show the frequency of marks or the waiting time on actual 1-minute bars.
Identical output to the standard ZigZag or the original MT4 indicator is not guaranteed. Performance over long histories and frequency across all symbols are not yet verified. There are no notifications or automated trading.