Trend Lines Pro Hello Traders!
We need to make things better & better to solve the puzzle and I try to do my best on this way. now I am here with my new Trend Lines Pro script.
As you know, Trend Lines is very subjective and many people (even professionals) draw different Trend Lines on the same chart. This is confusing and there must be an automation to make the life easer. with this tool I tried to automate it.
The idea in this script is different from my previous trend lines scripts. In this, I use channel idea so it can check number of pivot points it contains, it checks H/L/C in the channels as well. it also checks the angle while choosing trend lines. then we get stronger and useful Trend Lines automatically.
There are some option in the script, let see one by one:
Pivot Period: The Length to calculate Pivot Highs/Lows
Source : Option to use "High/Low" or "Close" as the source for Pivot Points
Threshold Rate : This rate is used for channel width. it you give bigger numbers then you get bigger channels. it's 4 by default
Minimum Angle Rate for new Trendline: if there are different trend lines, there must be an angle between them to choose best trend lines. you can set the angle with this option.
Minimum Strength: there can be many trend lines but we need to choose/use stronger ones. with this option you can set the number of pivot points a trend channel have to contains.
Maximum Loopback Length: by default the script can check 40 pivot highs and 40 pivot lows but to make the script faster and useful I needed to add a limitation for the number of bars that the script can go back.
Show Trendlines as: you can see trend lines as "Trendline", "Channel", "Trend Channel". you can see examples below.
Enable Weak Trend Lines: if there is no trend lines strong enough (as defined in "Minimum Strength" option) you have option to see a weak trend line. that is useful sometimes. if you enable this option weak lines are shown as dotted lines.
Show Price Labels on Trendlines: the script can show the price levels to break trend lines. the examples are below
Line Style: trend lines can be Solid or Dashed as you wish
Color theme: colors of the Up/Down Trend lines can be set. 'Red', Lime, Blue, White, Black, Olive, Gray
you can see the Trend Lines as channels:
you can see Trend Channels to see the big picture.also there is dotted trend line as weak trend line defined above.
you can set color/width of trend lines as you wish.
the script is fast enough to run on 1sec chart:
you can use this script on any chart, fx pairs, stocks, indices etc
I made a short video to explain how to use it and some options:
Please PM for access.
Enjoy!
DISCLAIMER: No sharing, copying, reselling, modifying, or any other forms of use are authorized for our documents, script / strategy, and the information published with them. This informational planning script / strategy is strictly for individual use and educational purposes only. This is not financial or investment advice. Investments are always made at your own risk and are based on your personal judgement. I am not responsible for any losses you may incur. Please invest wisely. Harmonic Patterns Pro Hello All,
We need to make things better & better to solve the puzzle and I try to do my best on this way for the community. now I am here with my Harmonic Patterns Pro script.
Harmonic Pattern recognition is the basic and primary ability any trader develops in technical analysis. Harmonic pattern recognition takes extensive practice and repetitive exposure. in general chart patterns are categorized into “continuous” and “reversal” patterns. Harmonic patterns construct geometric pattern structures using Fibonacci sequences. These harmonic structures identified as specified harmonic patterns provide unique opportunities for traders, such as potential price movements and key turning or trend reversal points. This script is developed to find following patterns by using the options you set. I have to say that this is not a strategy and you should not use this script blindly, instead, I strongly recommend you to create your own strategy using this script with other tools/indicators, such moving averages, Support/Resistance levels, volume indicators, sentiment indicators etc.
- Following Harmonic Patterns are available in this version:
-->Gartley
-->Butterfly
-->Bat
-->Crab
-->Shark
-->Cypher
-->Alternate Bat
-->Deep Crab
-->5-0
-->3-Drive
-->AB=CD
-->Descending Triangle
-->Ascending Triangle
-->Symmetrical Triangle
-->Double Top
-->Double Bottom
How the script works and finds harmonic patterns:
- It uses zigzag like other harmonic pattern script but there is a difference. this scripts searches up to 200 bars, finds/creates up to 200 XABCD using zigzag waves and searches predefined harmonic patterns
- It can find multiple harmonic patterns on a candles with different sizes and lengths
- Each pattern is shown using its own color (you can set 8 different colors)
- it shows Entry, Target1, Target2 and Stop-loss levels for each found Patterns
- It shows pattern validation zones for each found pattern
- it has all-in-one alerts. you set the alerts you want in the indicator options and you create only 1 alert for each symbol.
- it has prediction future and it can show many predicted patterns at the same time, each predicted patterns validations zones are shown separately
- While on real-time bar it searches and shows patterns for the visible area
it has followng alerts: . these in all-in-one alerts. it means that you choose the alerts in the options and enables any of them and then create only one for each symbol. and you get eany alert you choose. (" Any alert() function call "). in this version "Any alert() function call" alert is only alert you can use, if I get some requests I can try to other alerts as well.
New Pattern Found
Pattern Updated
Entered Position
Reached Target
Stop-loss
Validation zone is calculated using XABC points any pattern by using Y-Axis error rate. so if you increase Y-Axis error rate then the script can find much more Harmonic patterns.
X-Axis Error Rate is used for a few pattern such AB=CD for the distance of AB wave and CD wave.
The script can show Recommended Entry, Target 1, Target 2 and stop-loss levels for each active patterns. of course you can use these levels or you can set your own levels. you can see the screenshot below.
The script can show statistics panel. when statistic panel is enabled then no pattern is shown on the chart, the script shows ONLY statistics panel. This was done because of complexity of the script.
If you enables Prediction then pattern checks all possible XABC formations in the last 200 bars and finds/shows predicted patterns if there is any.
if you "replaying" then the script searches patterns only for last bar (if any update on zigzag on last bar), not for historical ones. you should take care while you use "Replay" feature of Tradingview
Now lets see the options:
Minimum ZigZag Period: this is minimum Zigzag Period to create new Zigzag wave. default value is 10 and minimum value is 4
Y-Axis Error Rate %: this is the error rate to create validation zones for each pattern, there is almost no perfect pattern, so we try to create a zone using error rate
X-Axis Error Rate % : this is used for a few pattern (such AB=CD) to check wave lengths on time basis
Minimum Pattern Length: This is Minimum Length for the Patterns to be searched. in Number of Bars
Maximum Pattern Length : This is Maximum Lengths for the Patterns to be searched. in Number of Bars
Max Number of XABCD to search: Maximum Number of ABCD to search pattern on each move, there are many possible XABCDs on the chart, this limitation is the number for how many of them will be searched
Find Patterns for: is the option about taking position. there are three options: "Long and Short", "Only Long", "Only Short"
Max Patterns on Each Bar: Maximum Number of Patterns that can be found on each bar, by default it's 3
Keep Pattern Until: you have two option "Target1" and "Target2". when a pattern found and if it reach any of these targets it is accepted as it's reached target and removed. this is also used inthe statictics panel!
Show Recommended Entries & Targets: if enabled then the script can show "Recommended" Entry, target1, target2 and stop-loss leves. you can use these levels or you can use your own calculation for each pattern
Entry = % of Target 2 : Entry Level for each pattern is calculated using the distance between D positon of the pattern and target 2. by default it's 16%, you can set it as you wish
Entry&Target Line Style: you can set line style for entry/target/stop-loss levels
Show Pattern Validation Zones: as explained above, for each pattern validation zone is created using error rate (Y-axis error rate). you can see it for each pattern
Source for Invalidation: this source is used for validation zones. there is two options: Close or High/Low. this source is used while invalidated the pattern. by default it used "close" price as source
Line Style: this is line style for validation zones, solid, dashed or dotted
Pattern Prediction/Possible Patterns: if you enable this option then the script calculates/searches possbile patterns and shows their levels in a label if there is one or more
Show Label & Zone: this is about how you want to see predictions, there are two choices: "Show Only Label", "Show Label & Zone"
Show Statistics Panel : if you enable this option then the script starts searching all harmonic patterns from the first bar for the last bar and keeps statistics for all of them and the shows in a table. you can see screenshot below
Panel Position: you can set panel location of statistics panel using this option
Show Rates Between Waves: if you enable this option then rate between the waves are shown. by default it's enabled
Keep Last Pattern on the Chart : if you enable this option then even if pattern is invalidated/reach target/stop-loss it stays on the chart until new pattern is found. by default it's enabled
Line Style : line style for the last pattern on the chart
Patterns to Search: you have options to enable/disable the patterns listed above to find&show, you can enable/disable any pattern in the list. by default all patterns are enabled except AB=CD pattern
in the ALERTS menu you have many options to enable/disable the alerts you want. Alerts contain Symbol name, Pattern name, Direction as Long/Short, Recommended Entry, Targets, SL levels.
- New Pattern Found
- Pattern Updated
- Entered Position
- Reached Target
- Stop-loss
Show Zig Zag: if you want to see Zig Zag then you should enable this option, and you can set the colors for the Zig zag. by default it's disabled.
and some other options for coloring and line styles of the patterns..
This is how XABCD points found using zigzag waves, I tried to explain it in the video below:
Validation zones and Entry, Target1, Target2 and Stop-loss levels:
Each pattern has its own color, you can see which levels, letters, lines etc belongs to which pattern:
Pattern prediction: you can enable it and change its background color:
How Statistics panel looks like. if there is active pattern then it's shown in different color in the table
This screenshot shows how the script finds and shows multiple patterns on a candle:
And some examples for triangles and Double top/bottom patterns:
Symmetrical triangle:
Ascending triangle:
Double bottom
and many others..
While using different time frames the script can find same patterns, in the following screenshots you can see how same patterns found on 5 and 10 min chart. of course this depends on the Zigzag Period
in this video, the idea and the indicator options is explained:
I can say that this is very complex script and it takes very long time to develop. I used my all programming ability and Pine ability to develop it. I hope you like it and make a lot of profit.
DISCLAIMER: No sharing, copying, reselling, modifying, or any other forms of use are authorized for the documents, script / strategy, and the information published with them. This informational planning script / strategy is strictly for individual use and educational purposes only. This is not financial or investment advice. Investments are always made at your own risk and are based on your personal judgement. I am not responsible for any losses you may incur. Please invest wisely.
Enjoy!
Trend Lines Pro for Indicators Hello Traders!
We need to make things better & better to solve the puzzle and I try to do my best on this way. now I am here with my new Trend Lines Pro for Indicators script.
As you know, Trend Lines is very subjective and many people (even professionals) draw different Trend Lines on the same chart. This is confusing and there must be an automation to make the life easer. with this tool I tried to automate it.
The idea in this script is different from my previous trend lines scripts. In this, I use channel idea so it can check number of pivot points it contains. it also checks the angle while choosing trend lines. then we get stronger and useful Trend Lines automatically.
There are some option in the script, let see one by one:
Indicator: the indicator on which you want to see Trend lines, Predefined Indicators are: RSI, CCI(Commodity Channel Index), OBV(On-Balance Volume), Momentum, MACD, CMF(Chaikin Money Flow), External Indicator
External Indicator: with this option you can use other indicators as input and get trend lines for them.
- First add an indicator (such as MFI)
- in "Indicator" option select "External Indicator"
- click "External Indicator" option
- and choose the indicator from the list
Pivot Period: The Length to calculate Pivot Highs/Lows
Threshold Rate: This rate is used for channel width. it you give bigger numbers then you get bigger channels. it's 4 by default
Minimum Angle Rate for new Trendline: if there are different trend lines , there must be an angle between them to choose best trend lines . you can set the angle with this option.
Minimum Strength: there can be many trend lines but we need to choose/use stronger ones. with this option you can set the number of pivot points a trend channel have to contains. default value is 2
Maximum Loopback Length : by default the script can check 40 pivot highs and 40 pivot lows but to make the script faster and useful I needed to add a limitation for the number of bars that the script can go back.
Show Trendlines as: you can see trend lines as "Trendline", "Channel", "Trend Channel". you can see examples below.
Enable Weak Trend Lines : if there is no trend lines strong enough (as defined in "Minimum Strength" option) you have option to see a weak trend line . that is useful sometimes. if you enable this option weak lines are shown as dotted lines.
Show Price Labels on Trendlines: the script can show the price levels to break trend lines . the example
Line Style: trend lines can be Solid or Dashed as you wish
Color theme: colors of the Up/Down Trend lines can be set. Red, Lime, Blue, White, Black, Olive, Gray
Indicator color: colors of the Up/Down Trend lines can be set. Red, Lime, Blue, White, Black, Olive, Gray and Yellow
and last options are for length options for RSI, CCI, Momentum, MACD, CMF
There are many alerts such: Support/Resistance Broken, Price in Support/Resistance channel, Support/Resistance line broken but still in a channel that means it broke S/R but there is another trend lines to break.
Below an example how the script uses external indicator as input and draws trend lines on it. in this example chaikin ossilator was added to the chart and get trend lines for it. (I am going to make a short video about it)
An example of Trend Channel is below. when you use trend channel option you can get "big picture" of whats going on
An example for trend lines in channels, that is the idea behind this trend lines script
An axample for trend lines for CCI:
Trend lines on OBV:
Trend lines on Momentum:
Trend lines on MACD:
Trend lines on CMF:
Different colors and line styles:
Please send me message for access and do not hesitate to ask your questions about this tool.
Enjoy!
DISCLAIMER: No sharing, copying, reselling, modifying, or any other forms of use are authorized for our documents, script / strategy, and the information published with them. This informational planning script / strategy is strictly for individual use and educational purposes only. This is not financial or investment advice. Investments are always made at your own risk and are based on your personal judgement. I am not responsible for any losses you may incur. Please invest wisely.
Smart Money Pro Hello All ,
Smart Money Pro is a professional analysis tool that algorithmically synthesizes Smart Money Concepts. It dynamically tracks Swing and Internal Break of Structure (BOS), Change of Character (CHoCH), and Liquidity sweeps without desynchronization or lag. It detects institutional patterns such as Order/Breaker/Mitigation/Rejection Blocks, Fair Value Gaps, Inverse Fair Value Gaps, Balanced Price Ranges, and High/Low Resistance Liquidity Runs (HRLR/LRLR) and more. All market data is processed through a 4-tier hierarchical Multi-Timeframe Synthesis Engine, cross-referencing the execution chart with three Higher Timeframes (HTFs). Also the engine finds and projects institutional Imbalances and Blocks from a designated HTF. It features an advanced alert system in JSON format and includes strict filtering options such as market direction and Premium/Discount (PD) zones.
Let's check the settings and analyze how each part works step by step.
Main Period: This is core lookback period for dynamic zigzag generation. The zigzag is used while searching Swing/Internal Break-of-Structure (BOS), Change of Character (CHoCH) for the chart time frame and 3 Higher time frames. It's also used to search Order/Breaker/Mitigation/Rejection Blocks.
Maximum Loopback Bars: Maximum calculation depth for MTF structural arrays. Restricts historical processing on Chart and HTFs to optimize execution efficiency.
Swing Break of Structure (BOS) and Change of Character (CHoCH):
Break of Structure (BOS):
This is a confirmation of structural continuation in the direction of the main trend. Its algorithmic logic involves the breaking—via a candle body—of the last confirmed Swing High (in a bullish trend) or Swing Low (in a bearish trend) level.
Change of Character (CHoCH):
This is the signal for the first major directional shift in order flow (Order Flow Shift). Its algorithmic logic involves the breaking—via a candle body and in the opposite direction—of the last valid Swing point (Swing Low in a bullish structure, Swing High in a bearish structure) that was responsible for the most recent BOS or CHoCH.
Swing BOS/CHoCH:
The diagram below illustrates how the Swing structure operates and how Swing High/Low levels are determined. For instance, in the event of a bullish BOS, the new Swing Low is the lowest point between the candle that caused the break and the previous Swing High, while the new Swing High is the level where the current zigzag wave turns. Until a confirmed Swing High/Low level is broken by a candle body, any intervening price action consists entirely of internal movements.
Internal BOS/CHoCH:
The initial pullback wave that begins immediately after a Swing extreme point (High/Low) is locked in is not a structural change of direction, but rather a process of creating a liquidity pool or inducement. The wave that follows is the first wave of the internal structure, and its initial direction runs counter to the main trend. In other words, that first wave is not the start of the internal structure itself, but the fuel for that structure. Same as Swing structure, in the event of a bullish internal BOS, the new internal low is the lowest point between the candle that caused the break and the previous internal high, while the new internal high is the level where the current zigzag wave turns. Following diagram shows how internal structure works.
Hierarchical Structure Matrix:
Hierarchical Structure Matrix: Real-time synthesis of multi-fractal market structure. Correlates Macro directional bias with localized execution boundaries and mitigation zones.
This dashboard is a status matrix that simultaneously processes market structure, internal order flow, and pricing zones across multiple timeframes. f price is in an active expansion phase, the Highest/Lowest values and Premium/Discount zone data are nullified (displayed as "-"), as they have not yet been established. The "Event" field indicates the specific structure currently occurring—such as "sBOS."
Boundary breaches occurring on the current (live) candle are tagged with a (Live) suffix . It remains mathematically uncertain whether the move represents a genuine breakout or an institutional liquidity sweep. The state is confirmed after the bar close.
Synthesis Engine
The Synthesis Engine is a hierarchical master filter that cross-references multi-timeframe order flow, Wyckoff phases, and Premium/Discount (PD) matrices. It operates based on strict bar-close confirmation protocols and does not engage in predictive execution.
If the Chart TF or Macro structure (HTF 3) breaches a structural boundary and enters an active Expansion Phase (active BOS/CHoCH), that layer's Swing High/Low values are reclassified as mathematically unconfirmed and "floating." To avoid generating spurious institutional zones based on unconfirmed data, the engine dynamically suspends the synthesis process for that timeframe and outputs the following message:
"Swing Expansion active. Premium/Discount boundaries floating. Synthesis suspended."
This mechanism serves as an algorithmic safeguard. Synthesis for the relevant timeframe resumes only once the expansion impulse has concluded, a new structural high/low has been locked in, and the fractal boundary has been fully confirmed.
You can change the table size and position anywhere on the chart.
Some examples:
BOS/CHoCH: if the price is on active BOS/CHoCH wave:
Chart time frame live event:
Swing Structure : It handles Break of Structure (BOS) and Change of Character (CHoCH) events triggered by confirmed Swing High/Low breaks. It is the primary layer that determines the hierarchical directional bias. You can customize the colors and line style as desired.
Internal Structure : It tracks internal structure breaks (iBOS/iCHoCH/iCHoCH+) within an active swing leg. This is necessary to distinguish between price impulses in the direction of the main trend and phases of retracement or liquidity engineering. Both iCHoCH and iCHoCH+ describe changes in market structure, but CHoCH+ requires a failed continuation before the break and considered as high-probability algorithmic variation. Bullish CHoCH+ occurs when price first fails to form a new lower low, then breaks the protected lower high. A bearish CHoCH+ occurs when price fails to form a new higher high, then breaks the protected higher low.
Next settings to show Liquidity or Swing Points
Liquidity:
Liquidity with High and Low Resistance
HRLR — High Resistance Liquidity Run
This is liquidity located with significant resistance before it can be taken. HRLR is the opposite scenario: price encounters major difficulty expanding and accessing this liquidity. To reach this liquidity, price must exert maximum effort, often resulting in longer trades. These formations are observed within market structure: A low that breaks the previous low and then reverses is called a High Resistance Low.
A high that breaks the previous high and then reverses is called a High Resistance High.
It's important to understand that HRLR is a zone where few or no orders exist at the moment, making these areas unattractive for price.
LRLR — Low Resistance Liquidity Run
This is liquidity located with minimal resistance, making it easy to capture. LRLR represents the most favorable trading conditions in the market. Always aim for targets with low resistance. Focusing on low-resistance liquidity gives a significantly higher probability of success. These trades feel straightforward, fast, and easy — almost like a "knife through butter." Price movement requires minimal effort to access this liquidity.
These formations can also be observed based on structure:
Bearish failure swing — a high that fails to break the previous high. We want to see it where we are bullish.
Bullish failure swing — a low that fails to break the previous low. We want to see it where we are bearish.
Swing Points
Trend Continuity (HH/HL, LL/LH): In an uptrend structure, the algorithmic engine sequentially locks in Higher Highs and Higher Lows. Conversely, in a downtrend structure, Lower Lows and Lower Highs are formed. These labels confirm that the trend is extending by creating structural breaks in the respective direction.
Trend Reversal ("High / Low"): Points labeled simply as "High" or "Low" are state machine flags indicating that the previous trend has been broken.
Equal Highs/Lows (EQH/EQL):
These are coordinates representing two or more fractal highs (EQH) or lows (EQL) aligned within the same narrow tolerance range or one determined by an algorithm. Within an Equal Highs formation, each subsequent high must be lower than the preceding one; similarly, within an Equal Lows formation, each subsequent low must be higher than the preceding one.
Retail investors view these levels as strong, unbreakable boundaries and place their stop-loss orders just beyond these coordinates. This creates pools of Buy-Side Liquidity (BSL) above the EQH and Sell-Side Liquidity (SSL) below the EQL. Generally, a downward breach of the EQL corresponds to the "Spring" move in Wyckoff theory (a liquidity sweep during the accumulation phase), while an upward breach of the EQH corresponds to the "Upthrust" move (a liquidity sweep during the distribution phase). These levels are intentionally breached before the primary directional impulse begins.
Max Length: Determines the maximum number of bars within which the equal highs/lows channel can occur.
Sensitivity: This value is used to determine the width of the equal highs/lows search channel. Lower values find fewer but more accurate equal highs/lows.
You can change color, line style, label size as you wish.
SHOW IMBALANCES / BLOCKS:
"Show Imbalances / Blocks" is the main menu for the Imbalances and Blocks. The indicator has an option to show "Imbalances", "Blocks", "Both", "None".
Max POI Count: The number of imbalances/blocks to display on the chart
"Mitigation Threshold %": Defines the penetration depth ratio for institutional mitigation. Increases the transparency of the zone to indicate institutional mitigation once this threshold is reached.
Mitigation Transparency: Sets the transparency level for mitigated zones. Higher values visually fade depleted liquidity pools.
Next option is "Higher Time Frame" that is used to show Imbalances/Blocks for Higher time frame at the right side of the chart.
The indicator can show Imbalances/Blocks for Higher time frame.
You can set the higher time frame or let the indicator choose suitable high time frame for you. "Auto HTF" option choose the higher time frame automatically. Please disable it if you want to set higher time frame.
Max HTF POI count: is the Number of nearest HTF imbalances/blocks to show. For example if you set it 3 then 3 bullish 3 bearish POI shown (if exist)
IMBALANCES
Imbalance is a gap in the market’s fair value that appears when one side — bulls or bears — gains a clear dominance.Such movements are formed by large capital — institutional players. The main things to understand are:
Imbalance is the footprint of a large player on the chart.
It is a zone of interest for institutional capital to buy or sell.
Imbalances act like magnets for price: very often the market returns to them for a retest.
Imbalances on higher timeframes are more significant than those on lower timeframes. In an uptrend or downtrend, price often completes corrective moves within the imbalance zone.
You can enable/disable FVG/TFVG/IFVG/BPR and change the colors. Also you can set the direction as "Both", "Bullish", "Bearish".
ATR Filtering: This option is used to disable inefficient Imbalances
Ratio %: FVG/IFVG/BPR sizes should be at least in this ratio of the average candle size
Fair Value Gap:
An imbalance is a three-candle model where there is a gap between a swing high and a swing low. On the other hand, If the "Merge" option is enabled, consecutive fair value gaps are merged and treated as a single FVG a shown in the following diagram.
After price enters the imbalance, three possible outcomes may follow:
Price closes with the candle body below the imbalance range (for a bearish imbalance) or above the imbalance range (for a bullish imbalance) or respects the zone.
As price exits, a new imbalance forms in the opposite direction. In this case, a Balanced Price Range (BPR) structure emerges: essentially a zone where two imbalances overlap.
Balanced Price Range (BPR) is a zone of interest from which a price reaction is expected. Algorithmically, a BPR is not a new drawing; it is the intersection array of a bullish and a bearish FVG. The engine calculates the overlapping price coordinates to isolate the true mitigation zone.
Balanced Price Range:
Inverse Fair Value Gap:
A previously formed price-to-value (FVG) zone is completely crossed (without imbalances overlap) by the closing price, reversing the original bias. In algorithmic terms, this is a polarity flip and a state update. It is the zone of interest from which a price reaction is expected
IFVG:
The screenshot below shows how the mitigated zones appear more transparent:
Higher Time Frame (HTF) imbalances:
The screenshot below shows how Higher time frame imbalances/blocks are shown
BLOCKS:
You can enable/disable Order/Breaker/Mitigation/Rejection Blocks and change their colors. Also you can set the direction as "Both", "Bullish", "Bearish".
Definitions and examples:
Order Block:
1. Bullish Order Block — a bearish candle followed by an impulsive bullish expansion upward, formed in a liquidity zone, imbalance, or another order block.
2. Bearish Order Block — a bullish candle followed by an impulsive bearish expansion downward, formed in a liquidity zone, imbalance, or another order block.
The body of an opposite-direction candle fully covers the body of the order block candle and closes beyond its boundaries.
Order Block may be engulfed by one or several candles (1 to 3). Formation restriction — an order block cannot be formed inside the range of the previous candle
It is necessary to create two variants for marking the blocks:
ICT methodology — an order block is defined using candle bodies only, wicks are ignored, and the block is considered valid only in the direction of the higher-timeframe context.
Example: Forex OB
Smart Money methodology — an order block is defined using candle bodies and wicks and may form both with and against the trend, while validation requires body or bodies of candles to engulf the block including its wick.
You can "Methodology" option under "Blocks" menu to choose one of these variants.
Order Block invalidation: an order block is considered invalid when a candle body closes beyond its boundaries. It becomes Breaker block or Mitigation block
The following 3 order blocks are valid (engulfed by 1, 2, 3 candles)
In the first of the two examples below, the order block is considered valid because sell-side liquidity was taken. In the second example, it is a valid order block because it formed in conjunction with an imbalance.
Breaker Block:
An Order Block that was validated and later broken by an impulsive candle body close with range expansion and the presence of a CHoCH.
Breaker Block examples:
Mitigation block:
An invalidated Order Block resulting from a failed liquidity sweep. Price fails to purge the preceding fractal extreme (forming a Lower High or Higher Low), subsequently breaching the original OB with a full-body close. This triggers a polarity flip, converting OB into a Mitigation Block without a change in market structure.
Example:
Rejection Block:
An order block with a pronounced long wick, formed at the moment of a liquidity sweep. Rejection Block validation Must be formation of a long wick during the liquidity grab (Wick length ≥ 2× the candle body (minimum)
Higher Time Frame Blocks:
PREMIUM/DISCOUNT ZONES:
Type: Wave/Trend
Wave: The algorithmic calculation locks exclusively onto the coordinates between the most recently confirmed Swing High and Swing Low. It isolates institutional mitigation points within the current structural wave (BOS-to-BOS).
Trend: The matrix encompasses the total price displacement between the initial CHoCH node—where the trend begins—and the terminal CHoCH point—where the trend breaks. By filtering out noise from lower timeframes (LTF), it identifies the macro discount and premium zones of the primary institutional cycle.
Extrem Zone %: Calculates the extreme Premium/Discount bands. It is used to isolate high-probability POIs (Points of Interest) for strategies involving deep liquidity sweeps (Sweep / Wyckoff Spring-Upthrust) or Optimal Trade Entry (OTE).
Equilibrium Zone %: A mathematical tolerance band defined around the 50% median (Equilibrium) axis. From an institutional perspective, this area represents the "Fair Value" zone.
Wave Example:
Trend Example:
ALERTS
Before moving on to the alarms, let's examine the alert filtering options.
Master Filtering: Alarm & Execution Conditions
This module ensures the mathematical validation of micro-structure entry signals (LTF) against macro order flow and institutional pricing zones (Premium/Discount Zones) from higher time frames (HTF). It rejects signals based on speculation.
Condition Operators:
Required: Strict algorithmic lock. If this condition is not met, execution is rejected, even if all other data in the matrix is positive.
Any: Flexible intersection filter. It is sufficient for at least one of the timeframes marked as 'Any' to satisfy the specified condition. If only a single timeframe is left as 'Any', the architecture automatically upgrades it to 'Required' status.
Off: Completely ignored. The status of the relevant timeframe is completely excluded from the analysis.
1. Zone Filters (Premium/Discount Zone Filters)
This filter matrix applies solely to Internal Structure (Internal BOS/CHoCH) events. Major Swing breaks bypass this zone restriction, as they inherently initiate a new macro expansion phase.
Auto: An automated algorithmic edge protocol. If the generated internal structure signal is Bullish, the system requires the price to be within the 'Discount' zone. If the signal is Bearish, it mandates that the price be within the 'Premium' zone for execution. The signal is rejected if the price is at the equilibrium point.
Premium / Discount: Allows the user to statically lock the execution target. This is used in custom strategies—for instance, to filter for internal structure signals generated only when the price is in the 'Premium' zone.
Example 1: Chart TF = Required (Auto). HTF 1 = Any (Auto). HTF 2 = Any (Auto). HTF 3 = Off. A Bullish iBOS has formed on the Chart TF.
Algorithmic Behavior: Since the signal is Bullish, the "Auto" parameter mandates—as an algorithmic requirement—that the price be within the Discount zone. If the price is in the Discount zone on the Chart TF, the first condition is met. Subsequently, due to the "Any" condition, the system checks whether the price is within the Discount matrix of at least one of the HTF 1 or HTF 2 timeframes. If these conditions are met then "Bullish iBOS" alert is triggered.
Example 2: Chart TF = Required (Premium). HTF 1 = Required (Premium). HTF 2 and HTF 3 = Off. A bearish iCHoCH has formed on the Chart TF.
Algorithmic Behavior: The user has overridden the algorithm's "Auto" logic and locked execution to the absolute Premium zone. Regardless of the signal direction, it is mandatory for the price to be within the Premium Zone of both the Chart TF and HTF 1. In short, the alert is triggered if the price is in the Premium Zone for both the Chart TF and HTF 1.
2. Direction Filters
Checks the hierarchical alignment of the order flow. It evaluates the relationship between the macro trend and the micro impulse.
Aligned: The direction of the potential signal (Bullish/Bearish) must match the primary structural direction of the selected timeframe exactly.
Opposite: The signal direction must be contrary to the primary trend of the selected timeframe. This is used to explicitly execute macro pullbacks or liquidity sweep setups during Wyckoff Accumulation/Distribution phase.
Example 1:
Scenario: Chart TF = Required (Aligned). HTF 1 = Any (Aligned). HTF 2 = Any (Aligned). HTF 3 = Off. A Bullish Internal Structure (iBOS/iCHoCH) signal is generated in Chart TF.
Algorithmic Behavior: The system first checks the Swing direction of Chart TF. If it is in an uptrend, the Required lock is unlocked. Then, if only one of HTF 1 or HTF 2 has a bullish main direction, it is sufficient to trigger the alert. HTF 3 is completely ignored. If the chart time frame Swing direction is bearish or both HTF 1 and HTF 2 swing directions are bearish, then the alert is not triggered.
Example 2:
Chart TF = Required (Opposite). HTF 1 = Required (Aligned). HTF 2 and HTF 3 = Off. A Bearish iCHoCH has formed on the Chart TF.
Algorithmic Behavior: The "Opposite" filter mandates that the internal structure impulse on the Chart TF runs counter to the direction of the main structure. This condition is met if the Chart TF main trend is Bullish. However, since HTF 1 is set to "Aligned" and "Required," the HTF 1 macro trend must be Bearish. In short, the alert is triggered if the Chart TF is Bullish and HTF 1 is Bearish.
All alerts are generated in JSON format, making them easy to integrate with virtually any automation platform or trading bot. Also You are able to customize alert messages, the indicator has many placeholders such as closing price, interval, break_level, Higher time frame premium/discount zones and directions etc.
STRUCTURE ALERTS:
The alert settings give you complete control over which events you want to monitor.
For BOS and CHoCH events, you can choose the signal direction.
If you're only interested in long setups, you can enable bullish signals only.
If your strategy focuses exclusively on short positions, simply enable bearish signals.
Or, if you prefer, you can receive both.
The next setting is Structure Type.
This determines which market structure the alerts are based on.
You can receive notifications from the External Structure, the Internal Structure, or both.
BOS Alerts: "Off", "All", "Only Bullish", "Only Bearish"
CHoCH Alerts: "Off", "All", "Only Bullish", "Only Bearish"
Structure Type: "All", "Swing", "Internal"
"Remove Line Breaks": Enable this option to send the alert message as a single continuous line.
Swing: Signals the expansion or reversal of the primary hierarchical trend (Macro Bias).
Internal: Tracks sub-fractal corrections (pullbacks) or liquidity engineering within the macro impulse (displacement).
IMBALANCES & BLOCKS ALERTS:
This section allows you to configure alerts for every Point of Interest generated by the indicator.
That includes Fair Value Gaps, Inverse Fair Value Gaps, Balanced Price Ranges, Order Blocks, Breaker Blocks, Mitigation Blocks, and Rejection Blocks.
First, you can choose which type of POI you'd like to monitor. You can receive alerts for Imbalances, Blocks, both, or disable POI alerts entirely.
Next, select which market structure the alerts should be based on: External Structure, Internal Structure, or both.
You can then specify exactly which events should trigger a notification. For example, when a new zone is formed, when price enters the zone, when the zone is respected, or when it becomes invalid.
Just like the Market Structure alerts, POI alerts include a fully customizable message template.
Every alert is generated in JSON format, making it easy to integrate with trading bots, webhooks, or your own automation systems.
Target Structures: "Off", "All", "Imbalances Only", "Blocks Only"
Events: Formed, Within, Respected, Invalidated
Formed: A new isolated POI (FVG/OB) was created.
Within: Price touched the boundaries of the relevant zone.
Respected: Price used the zone as liquidity fuel and retraced without breaching the zone boundaries (or merely by making a wick touch). Confirmation of a successful mitigation.
Invalidated: The institutional zone was breached in the opposite direction with a full-body bar close. This is not an error but a Polarity Flip signal (transformation of OB -> Breaker/Mitigation Block, or FVG -> iFVG/BPR).
LIQUIDITY ALERTS:
Here you can configure notifications related to liquidity sweeps.
First, choose the direction of the signals: bullish, bearish, both, or off.
Target Direction: "Off", "All", "Bullish", "Bearish"
Liquidity Taken Method:
Off: Disables module.
All: Scans both sides.
Bullish Only: Only scans for bullish setups.
Bearish Only: Only scans for bearish setups.
Liquidity Taken Method:
Wick Only (Sweep): Price pierces the liquidity pool but fails to sustain a close beyond it. This represents a high-probability reversal setup.
Candle Close: A candle body closes beyond the pool with significant volume. This is not a liquidity sweep but a confirmation of trend continuation following an Inducement.
Min Rejection Size (ATR %): A dynamic volatility filter. It measures the length of the rejection wick formed after the liquidity pool is breached. It protects the system against "fake" institutional sweeps by filtering out lackluster breaches that occur in low-volatility markets. (e.g., Sweeps that do not leave a wick of at least 20% of the ATR are disregarded).
PLACEHOLDERS:
{{open}} Bar Opening Price
{{high}} Bar Highest Price
{{low}} Bar Lowest Price
{{close}} Bar Closing Price
{{volume}} Bar Traded Volume
{{interval}} Chart time frame
{{exchange}} Prefix of current symbol name (i.e. for 'CME_EOD:TICKER' prefix is 'CME_EOD')
{{ticker}} Symbol name without exchange prefix
{{tickerid}} Symbol ticker id (e.g., "NASDAQ:AAPL")
{{bar_index}} Bar index of the current candle
{{timestamp}} UNIX Timestamp (e.g., 1718285400000)
{{time_utc}} ISO 8601 UTC datetime string (Requires quotation marks). Ex: "2026-06-14T17:33:00Z"
{{time_exchange}} Formatted Exchange Datetime string (Requires quotation marks). Ex: "2026-06-13 10:29:24"
{{timezone}} IANA Timezone Identifier for the Exchange (Requires quotation marks). Ex: "America/New_York"
Values: Premium, Ext-Premium, Equilibrium, Discount, Ext-Discount
{{chart_pd_zone}}
{{htf1_pd_zone}}
{{htf2_pd_zone}}
{{htf3_pd_zone}}
Values: Bullish, Bearish
{{chart_dir}}
{{htf1_dir}}
{{htf2_dir}}
{{htf3_dir}}
For BOS/CHoCH events:
{{event}} BOS, CHoCH, CHoCH+
{{direction}} Bullish, Bearish
{{break_level}} broken last swing/internal high/low level
{{structure}} Swing, Internal
For imbalances and blocks events:
{{event}} Formed, Invalidated, Respected, Within
{{type}} FVG, BPR, IFVG, Order Block, Breaker Block, Mitigation Block, Rejection Block
{{direction}} Bullish, Bearish
{{higher}} Top/Upper price boundary of the formed Block or Imbalance (Float).
{{lower}} Bottom/Lower price boundary of the formed Block or Imbalance (Float).
For Liquidity events:
{{event}} Liquidity Taken, Breakout
{{type}} Buy Side Liquidity, Sell Side Liquidity
{{direction}} Bullish, Bearish
{{liquidity_level}} Swept Liquidity Price Level. The exact price coordinate of the most recently purged structural liquidity pool (BSL/SSL). In the event of cascading sweeps, only the terminal (latest) swept coordinate is kept in memory.
A comprehensive visual breakdown of the algorithmic execution protocols, settings, multi-timeframe synthesis engine and master filtering logic for Smart Money Pro will be available on my YouTube channel soon.
Please drop a message below if you have any questions.
Enjoy!