Keep the long line and the short judgment separate
The visible blue line is the long depth only. Short ZigZag lines and horizontal lines for the reference price are not shown.
Organizes direction with a long ZigZag and records price changes with marks after a short swing is confirmed. Arrows and opposite-direction dots together come to 1 mark for every 1 short swing.
Read the long segments with the blue lineIt connects peaks and troughs confirmed with the long depth. A point's price is the extreme; its horizontal position is the bar where it could later be confirmed.
Short turns are used internallyThe short ZigZag itself is not drawn. When a short trough or peak is confirmed, the mark's reference is updated and the following bars are checked.
Distinguish green, red and orangeGreen is a mark along the long upward direction, red is a mark along the long downward direction. Orange dots are movement opposite to the long direction. They do not specify trade orders.
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.
The visible blue line is the long depth only. Short ZigZag lines and horizontal lines for the reference price are not shown.
No mark is output on the bar where the short turn is confirmed. The condition must be met on the next bar or later. No mark appears while the long direction is not yet confirmed either.
For a swing where an orange dot appeared first, no arrow is added even if the long direction changes later. Once the next short turn is confirmed, 1 mark can be output again.
A display that organizes 2 confirmed swings, long and short, and changes in a blended price. It does not directly measure future price movement, trading advantage, or overbought/oversold conditions.
After a trough is confirmed with the long depth, the direction is treated as upward; after a peak is confirmed, as downward. The direction is not confirmed just because the first candidate exists.
While rising, updating the high takes priority. A peak is confirmed when a bar that does not update makes the lowest low within the depth, the difference from the candidate high exceeds Deviation, and at least Backstep bars have passed since the candidate. While falling, it is the reverse.
Stores the blended price (5×close + 2×open + high + low) ÷ 9 of the bar where the short extreme occurred. It is neither the extreme price itself nor the close of the confirmation bar.
If the long direction is up after a short trough, green appears when the current blended price rises by Mark Gap or more from the reference. If the long direction is down after a short peak, red appears when it falls by the same width or more.
If the long direction is down after a short trough, orange appears when the blended price goes above the reference. If the long direction is up after a short peak, orange appears when it goes below the reference. Mark Gap is not used for these dots.
Green arrows are placed at the low 1 bar earlier and red arrows at the high 1 bar earlier. Orange dots are at the current blended price. In every case, the horizontal position is the bar where the condition was judged.
Long 55, short 17, Deviation 10, Backstep 3, Gap 10, closed bars only true. Sufficient history and turn conditions are required.
Points are on the later confirmation bar, not on the bar where the extreme occurred. Do not mistake the slope of the line for the actual price path.
Green and red are with-direction, orange is opposite-direction. Across the 3 types together, there is 1 for every 1 short swing.
Short depth and Gap are separate conditions. If you want fewer dots, increasing Gap alone does not change the orange condition.
| Included file | Purpose / location |
|---|---|
| TRI_Two_Depth_ZigZag_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 10 inputs. Change them in the Inputs tab of the properties window. The English item names and input names defined in the source are shown together.
InpLongDepthInpShortDepthInpDeviationInpBackstepInpGapInpClosedBarsOnlyInpTriBrandShowInpTriBrandCornerInpTriBrandXInpTriBrandYWhen bars are added with the same history and settings, confirmed dots and marks on closed bars are not later deleted and reselected. Adding to or correcting the history or changing settings changes recalculated results.
The blue line connects points only after 2 confirmation points have formed. The whole line in the completed picture was not visible from intermediate times.
Widths are in the symbol's points and are not automatically linked to spread or pips. If point=0.00001, 10 point=0.00010. If the digits change, the same input gives a different price width.
There is no short zigzag display, no notifications or sounds, no automatic orders, no account authentication and no license file.
The display is a record of calculation results. It does not direct trading decisions and does not guarantee future price movements.
A confirmed short turn, a price change from the reference, and an unused swing are required. Marks do not necessarily appear just because the blue line is visible.
This is normal with Closed Bars Only=true. Changing it to false also shows changes on the forming bar, but these cannot be treated as confirmed marks.
The orange Counter Mark does not use Gap. It is only a strict comparison of going above or below the reference.
They are small dots of width 1. Zoom in or check the colors in the properties. They are not the same size as the arrows.
Green and red are the previous bar's low and high. The confirmation points of the long line are also past extreme prices, so they may not match the high/low of the bar where they are shown.
Check: long depth 3 to 1000, short depth at least 2 and less than the long depth, Deviation and Gap 0 to 100000, Backstep 0 to 1000.
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.
On each bar, the long turn is updated first, then the short turn is checked. If there is a short turn, only the reference is updated and no mark is judged on that bar. If not, the mark is judged with the long direction updated this time and the stored short reference.
The highest high and lowest low within the depth include ties, but updating the candidate extreme requires a strict new high or new low. If both are met in the initial state, the upward candidate takes priority.
The reference is the blended price of the short extreme's bar. Arrows and the Counter Mark share a common used state; it is not re-enabled when the long direction changes and is reset only by the next short turn.
Points and marks are not erased afterward; they are recorded on the bar where they can be confirmed. The width is specified in fixed points, and the long points are drawn at the extreme prices. There are no notifications.
M1 is the timeframe display at the time the display examples were made; the price series is mainly at 30-minute intervals, with 1-minute intervals at the end. It is not the frequency of occurrence on actual 1-minute bars. The published images are screens from before the brand display was added. The on-screen display of the product with the brand display has not yet been verified.