RSI Divergence Entry Engine [trade_w_samet]🎯 RSI Divergence Entry Engine
RSI Divergence Entry Engine is a pivot-confirmed RSI divergence, optional trend-filtering, ATR-based trade-mapping, historical visualization, alert, and statistics indicator designed to help traders study how regular bullish and bearish RSI divergences can be converted into a structured chart workflow.
The script is built around one central idea:
A confirmed RSI divergence should be treated as analytical context first, and as a tracked trade setup only when the active direction filter and trade-state rules allow it.
The engine identifies regular RSI divergence between confirmed RSI pivots and corresponding price pivots.
When a divergence is confirmed, the script can:
• Display the divergence inside the RSI panel
• Fill the region between the RSI path and its divergence reference line
• Draw a three-layer neon divergence line directly between the corresponding price pivots on the main chart
• Evaluate the active trend-filter mode
• Open one tracked bullish or bearish setup when the signal is eligible
• Calculate an ATR-based Stop Loss
• Calculate TP1, TP2, and TP3
• Extend risk/reward boxes while the trade remains active
• Preserve completed trade boxes and historical TP price labels
• Track TP3 wins, Stop Losses, Win Rate, NET R, Average R, and Profit Factor
• Display a full desktop dashboard or a compact mobile dashboard
• Send separate TradingView alert conditions
• Support one combined “Any alert() function call” workflow
• Apply Dark Mode, Light Mode, or Mobile Theme styling
The indicator includes:
• Fixed RSI 14 calculation using closing prices
• Pivot-based regular bullish divergence detection
• Pivot-based regular bearish divergence detection
• Adjustable Pivot Lookback
• Adjustable Confirmation Bars
• A fixed internal pivot-distance window
• Confirmed-bar divergence acceptance
• RSI-panel bullish and bearish divergence lines
• RSI-panel divergence-area fills
• Main-chart three-layer neon divergence lines
• Adjustable main-chart BULLISH / SELL label size
• Fixed compact RSI-panel labels
• Dark Mode
• Light Mode
• Mobile Theme
• EMA 200 Trend Filter
• Supertrend filter using ATR 10 and factor 3.0
• Higher-timeframe EMA 200 Trend Filter
• Adjustable higher timeframe
• ATR-based Stop Loss
• Adjustable ATR period
• Adjustable ATR Stop Loss multiplier
• Adjustable TP3 target from 1R to 7R
• Automatically calculated TP1 and TP2
• One active tracked trade at a time
• Conservative same-candle TP3 / SL handling
• Permanent historical TP / SL boxes
• Historical TP1, TP2, and TP3 price labels
• Dynamic active-trade price labels
• TP3 TARGET HIT labels
• Stop Loss result labels
• Full desktop statistics dashboard
• Two-row Mobile Theme dashboard
• Static alertcondition() support
• Dynamic alert() support
• “Any alert() function call” compatibility
• Bold-italic visual text
• Pure-white Dark Mode label text
• Hidden status-line input values
• Main-chart overlay visuals from a separate RSI pane
• Loaded-history trade statistics
The purpose of the script is to provide a transparent visual framework for reviewing confirmed RSI divergence, directional context, mapped risk, target structure, and bar-based historical outcomes.
It is not financial advice.
It is not an automated trading system.
It does not execute broker orders.
It does not calculate position size.
It does not guarantee that a divergence will produce a reversal.
It does not guarantee that the displayed Win Rate, NET R, or Profit Factor will continue in future market conditions.
It does not include spread, commission, slippage, latency, financing, or partial fills.
It does not reproduce the exact intrabar path inside historical candles.
━━━━━━━━━━━━━━━━━━━━━━
📌 OVERVIEW
━━━━━━━━━━━━━━━━━━━━━━
At a high level, RSI Divergence Entry Engine does the following:
• Calculates RSI using a fixed 14-period length and closing prices.
• Searches the RSI series for confirmed pivot lows and pivot highs.
• Compares each confirmed RSI pivot with the previous eligible pivot of the same type.
• Compares the corresponding price low or high with the prior price pivot.
• Identifies regular bullish divergence when RSI forms a higher low while price forms a lower low.
• Identifies regular bearish divergence when RSI forms a lower high while price forms a higher high.
• Requires the distance between the two confirmed pivots to remain inside the fixed internal range window.
• Waits for the required right-side confirmation bars before accepting a pivot.
• Displays confirmed divergence inside the RSI panel.
• Draws the same confirmed price-pivot relationship on the main chart with a neon line.
• Evaluates the selected trend-filter mode.
• Rejects a tracked entry when the trend filter does not allow that direction.
• Rejects a tracked entry when an opposite divergence is simultaneously present.
• Rejects a tracked entry while another trade is active.
• Opens a tracked trade at the close of the divergence-confirmation candle.
• Calculates Stop Loss distance from ATR.
• Places TP1 and TP2 at proportional distances inside the final TP3 target.
• Tracks only TP3 as the winning exit.
• Tracks Stop Loss as a -1R loss.
• Extends the active profit and loss boxes until the trade closes.
• Preserves completed boxes as historical trade visuals.
• Preserves historical TP1, TP2, and TP3 price labels.
• Updates the dashboard with bar-based historical statistics.
• Provides separate static alerts and combined dynamic alerts.
The script does not use machine-learning prediction.
It does not claim that RSI divergence predicts the future with certainty.
Its dashboard is not TradingView Strategy Tester.
Its statistics are calculated internally from the script’s own bar-touch rules.
━━━━━━━━━━━━━━━━━━━━━━
🧠 CORE IDEA
━━━━━━━━━━━━━━━━━━━━━━
RSI divergence describes disagreement between price direction and RSI pivot direction.
A regular bullish divergence occurs when:
• price forms a lower low
• RSI forms a higher low
A regular bearish divergence occurs when:
• price forms a higher high
• RSI forms a lower high
The divergence can indicate that momentum is not confirming the newest price extreme.
However, divergence alone does not answer:
• whether the broader trend supports the reversal
• whether price is above or below a long-term directional reference
• whether Supertrend agrees with the signal
• whether the selected higher timeframe agrees with the signal
• where a volatility-adjusted Stop Loss should be mapped
• where intermediate and final targets should be displayed
• whether another tracked trade is already active
• whether historical bar touches reached TP3 or Stop Loss first
• how the signal behaves across Dark, Light, or Mobile layouts
The script therefore combines the divergence calculation with an optional trend filter and a fixed trade-tracking model.
The complete workflow is:
RSI pivot confirmation
→ price-pivot comparison
→ regular divergence confirmation
→ RSI-panel visualization
→ main-chart neon price-divergence line
→ optional trend-filter validation
→ one-active-trade check
→ entry at confirmation-candle close
→ ATR-based Stop Loss
→ TP1 / TP2 / TP3 mapping
→ historical bar-touch tracking
→ TP3 or SL result
→ dashboard statistics
→ static and dynamic alerts
The modules are not intended to operate as unrelated indicators.
Each module supports the same process: identifying a confirmed divergence, deciding whether it is eligible for tracking, mapping the trade structure, and recording the result under explicit rules.
━━━━━━━━━━━━━━━━━━━━━━
🧩 WHY THIS SCRIPT IS NOT A SIMPLE RSI DIVERGENCE MARKER
━━━━━━━━━━━━━━━━━━━━━━
A basic RSI divergence script can stop after drawing a line between two oscillator pivots.
RSI Divergence Entry Engine continues beyond that step.
A confirmed divergence can move through the following stages:
RSI pivot appears
→ right-side confirmation bars complete
→ previous eligible RSI pivot is located
→ pivot distance is validated
→ corresponding price pivots are compared
→ bullish or bearish divergence is confirmed
→ RSI divergence region is displayed
→ main-chart neon price-divergence line is displayed
→ active trend filter is evaluated
→ opposite-direction conflict is rejected
→ existing active-trade state is checked
→ ATR risk distance is calculated
→ entry, SL, TP1, TP2, and TP3 are stored
→ trade boxes extend through time
→ TP3 or SL is detected
→ completed trade is added to statistics
→ historical TP prices remain visible
The RSI module identifies the momentum disagreement.
The trend-filter module defines whether the tracked entry is directionally permitted.
The ATR module adapts the Stop Loss distance to current volatility.
The target module translates the chosen TP3 R multiple into three visual target levels.
The trade-state module prevents overlapping tracked positions.
The statistics module summarizes the outcomes produced by those exact rules.
The alert module communicates divergence, entry, TP3, and Stop Loss events.
This coordinated process makes the publication an entry-engine framework rather than only a divergence drawing tool.
━━━━━━━━━━━━━━━━━━━━━━
⚙️ HOW THE SCRIPT WORKS
━━━━━━━━━━━━━━━━━━━━━━
The indicator operates from a separate RSI pane while using force-overlay visuals for selected elements on the main chart.
The internal RSI configuration is:
• RSI length: 14
• Source: close
• Regular bullish divergence: enabled
• Regular bearish divergence: enabled
• Hidden bullish divergence: internally disabled
• Hidden bearish divergence: internally disabled
• Minimum pivot separation: 5 bars
• Maximum pivot separation: 60 bars
The user controls:
• Pivot Lookback
• Confirmation Bars
• Main-chart signal-label size
• ATR Period
• Stop Loss Distance in ATR
• TP3 Target in R
• Trend Filter
• Higher-Timeframe Trend Timeframe
• Theme Mode
First, the script calculates RSI:
osc = ta.rsi(close, 14)
The script then detects confirmed RSI pivots:
pivotLowValue = ta.pivotlow(osc, lbL, lbR)
pivotHighValue = ta.pivothigh(osc, lbL, lbR)
A pivot is not known on the pivot candle itself.
It becomes confirmed only after the selected Confirmation Bars have closed to its right.
The script then retrieves the previous confirmed pivot value, price value, and pivot bar.
Regular bullish divergence requires:
• current RSI pivot low above the previous RSI pivot low
• current price low below the previous price low
• valid pivot distance
• confirmed current chart bar
Regular bearish divergence requires:
• current RSI pivot high below the previous RSI pivot high
• current price high above the previous price high
• valid pivot distance
• confirmed current chart bar
The confirmed divergence is then displayed in two places:
• RSI pane
• Main price chart
The trend filter is applied only to the tracked trade entry.
This means a confirmed divergence can remain visible even when:
• the selected trend filter rejects the direction
• another trade is already active
• bullish and bearish conditions conflict on the same calculation
This separation is intentional.
The divergence visual represents analytical context.
The main-chart BULLISH or SELL trade label represents an entry that the tracking engine actually accepted.
━━━━━━━━━━━━━━━━━━━━━━
📉 RSI CALCULATION
━━━━━━━━━━━━━━━━━━━━━━
The Relative Strength Index is calculated from closing prices using a fixed length of 14.
The RSI line is displayed in blue.
The RSI pane includes:
• 70 Overbought line
• 50 Middle line
• 30 Oversold line
Dark Mode uses:
• black RSI-panel background
• red Overbought line
• white dotted Middle line
• green Oversold line
Light Mode uses:
• white RSI-panel background
• dark Middle line
• red Overbought line
• green Oversold line
The 70 and 30 lines provide visual context.
They are not mandatory divergence conditions.
A bullish divergence can be detected outside the Oversold region.
A bearish divergence can be detected outside the Overbought region.
The script does not require RSI to cross 30 or 70 before accepting a divergence.
━━━━━━━━━━━━━━━━━━━━━━
🔍 PIVOT DETECTION MODEL
━━━━━━━━━━━━━━━━━━━━━━
Pivot Lookback controls the number of candles examined on the left side of a potential RSI pivot.
The default value is 5.
Higher values generally produce larger and less frequent swing points.
Lower values generally produce smaller and more frequent swing points.
Confirmation Bars controls the number of completed candles required on the right side of the potential pivot.
The default value is 1.
A higher Confirmation Bars value provides more right-side confirmation but increases delay.
A lower value confirms earlier but can identify smaller structures.
The script also requires the previous pivot to be between 5 and 60 bars away.
These minimum and maximum distance values are fixed internally to keep the public settings panel compact.
The pivot model is symmetrical:
• pivot lows are used for bullish divergence
• pivot highs are used for bearish divergence
━━━━━━━━━━━━━━━━━━━━━━
🟢 REGULAR BULLISH DIVERGENCE
━━━━━━━━━━━━━━━━━━━━━━
A regular bullish divergence is confirmed when:
• a new RSI pivot low is confirmed
• the previous eligible RSI pivot low exists
• the current RSI pivot low is higher than the previous RSI pivot low
• the current corresponding price low is lower than the previous price low
• the pivot distance is between the fixed internal limits
• the current calculation bar is confirmed
Conceptually:
Price:
lower low
RSI:
higher low
The RSI pane displays:
• a green divergence line between the two RSI pivot values
• a translucent green fill between the real RSI path and the straight divergence reference
• a BULLISH label at the confirmed pivot location
The main chart displays:
• a three-layer green neon line between the corresponding price lows
A tracked bullish trade opens only when:
• the bullish divergence is not opposed by a bearish divergence on the same calculation
• the selected trend filter allows bullish entries
• no tracked trade is currently active
• another trade did not close on the same candle
• ATR is available and greater than zero
The tracked entry price is the close of the confirmation candle.
It is not the historical pivot-low price.
━━━━━━━━━━━━━━━━━━━━━━
🔴 REGULAR BEARISH DIVERGENCE
━━━━━━━━━━━━━━━━━━━━━━
A regular bearish divergence is confirmed when:
• a new RSI pivot high is confirmed
• the previous eligible RSI pivot high exists
• the current RSI pivot high is lower than the previous RSI pivot high
• the current corresponding price high is higher than the previous price high
• the pivot distance is between the fixed internal limits
• the current calculation bar is confirmed
Conceptually:
Price:
higher high
RSI:
lower high
The RSI pane displays:
• a red divergence line between the two RSI pivot values
• a translucent red fill between the real RSI path and the straight divergence reference
• a SELL label at the confirmed pivot location
The main chart displays:
• a three-layer red neon line between the corresponding price highs
A tracked bearish trade opens only when:
• the bearish divergence is not opposed by a bullish divergence on the same calculation
• the selected trend filter allows bearish entries
• no tracked trade is currently active
• another trade did not close on the same candle
• ATR is available and greater than zero
The tracked entry price is the close of the confirmation candle.
It is not the historical pivot-high price.
━━━━━━━━━━━━━━━━━━━━━━
⏳ PIVOT CONFIRMATION AND SIGNAL TIMING
━━━━━━━━━━━━━━━━━━━━━━
This section is important.
The script uses ta.pivotlow() and ta.pivothigh().
Pivot functions require candles to the right of the pivot before confirmation.
For example, when Confirmation Bars is 1:
• the potential pivot occurs
• one additional candle closes
• the pivot becomes confirmed
• the divergence condition can then be calculated
The RSI-panel divergence line and RSI divergence label are drawn at the original pivot-bar location after confirmation.
The main-chart neon divergence line also connects the original price-pivot bars after the divergence is confirmed.
This creates a historical visual relationship between the two pivots.
It does not mean the divergence was available in realtime on the original pivot candle.
The tracked trade entry is not placed back on the pivot.
The tracked entry occurs at the close of the later candle where the divergence confirmation becomes available.
Therefore, users must distinguish between:
Pivot Visualization
Shows where the confirmed historical pivots occurred.
Trade Entry Label
Shows the candle where the script actually accepted and opened the tracked setup.
Changing Confirmation Bars changes the confirmation delay.
Increasing Confirmation Bars can materially change signal timing and historical divergence output.
━━━━━━━━━━━━━━━━━━━━━━
✨ MAIN-CHART NEON DIVERGENCE VISUALS
━━━━━━━━━━━━━━━━━━━━━━
Confirmed RSI divergences are also displayed directly on the main price chart.
Bullish divergence:
• connects the two corresponding price lows
• uses green
• uses a three-layer neon appearance
Bearish divergence:
• connects the two corresponding price highs
• uses red
• uses a three-layer neon appearance
The neon effect is created from:
• a wide transparent outer glow
• a medium inner glow
• a bright two-pixel core line
The neon line is a historical divergence visual.
It is not an entry line.
It is not a Stop Loss.
It is not a support or resistance guarantee.
The line is created only after the RSI pivot and divergence have been confirmed.
Older line objects are removed when the configured internal object limit is exceeded.
Deleting an older visual object does not change the underlying signal calculation.
━━━━━━━━━━━━━━━━━━━━━━
🎨 RSI DIVERGENCE AREA SYSTEM
━━━━━━━━━━━━━━━━━━━━━━
Inside the RSI pane, the script creates a filled polygon between:
• the actual RSI path from the first pivot to the second pivot
• the straight divergence line connecting those pivot endpoints
Bullish divergence uses a translucent green fill.
Bearish divergence uses a translucent red fill.
The purpose is to make the momentum disagreement easier to recognize than a thin line alone.
The fill does not measure probability.
A larger visual area does not automatically mean a stronger or more profitable divergence.
The fill depends on:
• RSI movement between the pivots
• distance between the pivots
• selected Pivot Lookback
• selected Confirmation Bars
• chart symbol
• timeframe
• loaded historical data
━━━━━━━━━━━━━━━━━━━━━━
🧭 TREND FILTER SYSTEM
━━━━━━━━━━━━━━━━━━━━━━
The trend filter determines whether a confirmed divergence is eligible to open a tracked trade.
Available modes are:
• Off
• EMA Trend
• Supertrend
• HTF Trend
The filter does not hide the confirmed divergence visuals.
It only changes whether the trade engine accepts the bullish or bearish entry.
This allows users to study:
• all confirmed divergence structures
• only the subset that passed the selected directional filter
The active trend reference is drawn on the main chart when a filter mode is selected.
The reference is green when the active filter state is bullish.
The reference is red when the active filter state is bearish.
━━━━━━━━━━━━━━━━━━━━━━
📈 EMA TREND FILTER
━━━━━━━━━━━━━━━━━━━━━━
EMA Trend uses a fixed chart-timeframe EMA 200.
Bullish entries are allowed when:
• chart close is above EMA 200
Bearish entries are allowed when:
• chart close is below EMA 200
When price equals the EMA exactly, neither directional condition is satisfied.
The EMA filter is intended to align bullish divergence tracking with price above a long-term average and bearish divergence tracking with price below it.
It does not guarantee that price will continue in the filtered direction.
A divergence rejected by the EMA filter can still remain visible as a divergence visual.
━━━━━━━━━━━━━━━━━━━━━━
📊 SUPERTREND FILTER
━━━━━━━━━━━━━━━━━━━━━━
Supertrend mode uses fixed internal parameters:
• ATR length: 10
• factor: 3.0
Bullish entries are allowed when the Supertrend state is bullish.
Bearish entries are allowed when the Supertrend state is bearish.
The Supertrend reference is displayed on the main chart.
The fixed parameters keep the public settings menu simple and make behavior consistent across users.
The Supertrend filter can react differently across symbols and timeframes because ATR and price structure differ.
A bullish Supertrend state does not guarantee a successful bullish divergence trade.
A bearish Supertrend state does not guarantee a successful bearish divergence trade.
━━━━━━━━━━━━━━━━━━━━━━
⏱️ HIGHER-TIMEFRAME TREND FILTER
━━━━━━━━━━━━━━━━━━━━━━
HTF Trend compares the selected higher-timeframe close with its EMA 200.
Bullish entries are allowed when:
• higher-timeframe close is above higher-timeframe EMA 200
Bearish entries are allowed when:
• higher-timeframe close is below higher-timeframe EMA 200
The default higher timeframe is 240 minutes.
The request uses:
• gaps_off
• lookahead_off
The script does not intentionally request future higher-timeframe data.
However, the currently forming higher-timeframe candle can continue changing until that higher-timeframe candle closes.
This means the realtime HTF filter state can change while the active higher-timeframe candle is still developing.
Users who require fully closed higher-timeframe confirmation should account for this timing characteristic when interpreting realtime signals.
Changing the HTF Trend Timeframe recalculates historical eligibility.
━━━━━━━━━━━━━━━━━━━━━━
🎯 ENTRY MODEL
━━━━━━━━━━━━━━━━━━━━━━
The indicator uses the close of the divergence-confirmation candle as the tracked entry reference.
A bullish trade is opened when:
• valid bullish divergence is confirmed
• no bearish divergence conflict exists
• bullish trend permission is true
• no trade is active
• no trade closed on the same candle
• ATR is valid
A bearish trade uses the mirrored conditions.
The entry is stored at close.
The script then calculates:
• ATR-based risk distance
• Stop Loss
• TP1
• TP2
• TP3
Only signals that actually open a tracked trade receive the main-chart BULLISH or SELL entry label.
A divergence visual without an entry label can therefore indicate:
• trend-filter rejection
• existing active trade
• same-candle direction conflict
• same-candle previous trade closure
• unavailable ATR
━━━━━━━━━━━━━━━━━━━━━━
🛑 ATR STOP LOSS MODEL
━━━━━━━━━━━━━━━━━━━━━━
Risk distance is calculated as:
ATR × Stop Loss Distance.
Default settings:
• ATR Period: 14
• Stop Loss Distance: 2.0 ATR
Bullish trade:
Stop Loss = entry − risk distance
Bearish trade:
Stop Loss = entry + risk distance
ATR adapts the raw price distance to current market volatility.
The script does not examine:
• market structure below the bullish signal
• market structure above the bearish signal
• spread
• instrument tick value
• account size
• position size
• broker margin
• contract specifications
The ATR Stop Loss is a visual and statistical model.
It is not a broker order.
━━━━━━━━━━━━━━━━━━━━━━
🏆 TP1 / TP2 / TP3 MODEL
━━━━━━━━━━━━━━━━━━━━━━
The user selects the final TP3 target from 1R to 7R.
The default is 2R.
TP1 and TP2 are placed automatically inside the final target distance.
TP1:
one-third of the TP3 distance
TP2:
two-thirds of the TP3 distance
For a 3R TP3 setting:
• TP1 = 1R
• TP2 = 2R
• TP3 = 3R
For a 2R TP3 setting:
• TP1 ≈ 0.67R
• TP2 ≈ 1.33R
• TP3 = 2R
TP1 and TP2 are visual guide levels.
The current statistics engine does not close partial positions at TP1 or TP2.
It does not move Stop Loss to break even after TP1 or TP2.
It does not add partial R profit when TP1 or TP2 is touched.
Only TP3 is counted as a winning trade.
A Stop Loss is counted as -1R.
━━━━━━━━━━━━━━━━━━━━━━
🚦 ONE ACTIVE TRADE AT A TIME
━━━━━━━━━━━━━━━━━━━━━━
The trade engine maintains one active tracked position.
While a trade is active:
• new bullish divergence entries are not opened
• new bearish divergence entries are not opened
• divergence visuals can still appear
• historical divergence lines can still be drawn
This prevents overlapping tracked positions from affecting the statistics model.
A new trade is also prevented from opening on the same candle that the previous trade closes.
The next eligible divergence must occur on a later candle.
This design keeps each tracked result independent under the script’s internal accounting rules.
━━━━━━━━━━━━━━━━━━━━━━
⚠️ TP3 / SL SAME-CANDLE HANDLING
━━━━━━━━━━━━━━━━━━━━━━
Historical OHLC candles do not reveal the exact sequence of every intrabar price movement.
A candle can contain both:
• the TP3 price
• the Stop Loss price
When both are touched inside the same candle, the script cannot know from OHLC data which level occurred first.
The engine uses a conservative rule:
Stop Loss receives priority.
The trade is recorded as a loss.
TP3 and Stop Loss checks begin on the candle after entry.
The entry candle cannot immediately close the tracked trade.
This avoids assuming an unknown movement sequence inside the entry candle.
The conservative priority rule can produce different outcomes from lower-timeframe or tick-based execution reconstruction.
━━━━━━━━━━━━━━━━━━━━━━
📦 TRADE BOX VISUAL SYSTEM
━━━━━━━━━━━━━━━━━━━━━━
Each tracked trade creates two main-chart boxes:
Profit Box
Extends from entry to TP3.
Stop Box
Extends from entry to Stop Loss.
Bullish and bearish trades use the same green profit-area and red risk-area color logic.
While the trade remains active, the boxes extend to the current bar.
When the trade closes, the boxes stop at the exit candle and remain visible historically.
The boxes help visualize:
• entry timing
• risk distance
• final target distance
• trade duration
• exit candle
The boxes are chart drawings.
They are not broker orders.
Older boxes are deleted when the internal historical object limit is exceeded.
━━━━━━━━━━━━━━━━━━━━━━
🏷️ ACTIVE AND HISTORICAL PRICE LABELS
━━━━━━━━━━━━━━━━━━━━━━
During an active tracked trade, the right side of the chart displays dynamic labels for:
• ENTRY
• SL
• TP1
• TP2
• TP3
Each label includes the current stored price.
The labels move to the newest bar while the trade remains active.
On the exit candle, the final prices remain visible for that calculation.
When the trade closes, permanent historical labels are created for:
• TP1
• TP2
• TP3
These historical labels remain attached to the completed trade’s right edge.
The purpose is to preserve the target-price structure after the active dynamic labels disappear.
Historical TP labels do not indicate that TP1 or TP2 was actually touched.
They display the planned target prices for the completed tracked trade.
The final result is determined only by TP3 or Stop Loss.
━━━━━━━━━━━━━━━━━━━━━━
✅ RESULT LABELS
━━━━━━━━━━━━━━━━━━━━━━
When TP3 is reached, the script prints:
TARGET HIT
The trade is counted as a win equal to the selected TP3 R value.
When Stop Loss is reached, the script prints:
SL
The trade is counted as a -1R loss.
Result labels are displayed at the corresponding exit price.
All visible chart labels use bold-italic typography.
Dark Mode label text uses pure white.
Light Mode uses dark text where required for contrast.
━━━━━━━━━━━━━━━━━━━━━━
🎨 THEME SYSTEM
━━━━━━━━━━━━━━━━━━━━━━
The indicator includes three theme modes:
• Dark Mode
• Light Mode
• Mobile Theme
Dark Mode
Designed for dark TradingView layouts.
It uses:
• black RSI-panel background
• dark dashboard surface
• white dashboard text
• pure-white chart-label text
• red brand accents
• green bullish visuals
• red bearish visuals
Light Mode
Designed for light TradingView layouts.
It uses:
• white RSI-panel background
• white dashboard surface
• dark dashboard text
• dark chart-label text where appropriate
• red brand accents
• adjusted divergence transparency
Mobile Theme
Designed for smaller screens.
It uses:
• compact main-chart labels
• smaller RSI labels
• tiny price labels
• a two-row dashboard
• Win Rate
• NET R
Mobile Theme does not display the full desktop statistics table.
Theme selection changes presentation.
It does not change the underlying divergence, trend-filter, or trade calculations.
━━━━━━━━━━━━━━━━━━━━━━
📟 DASHBOARD
━━━━━━━━━━━━━━━━━━━━━━
Dark Mode and Light Mode display the full bottom-right dashboard.
The header displays:
• RSI DIVERGENCE
• selected TP3 R value
• active Trend Filter
The full dashboard includes:
Status
Possible values:
• NO ACTIVE TRADE
• ACTIVE BUY
• ACTIVE SELL
Closed Trades
Number of completed tracked trades.
TP3 Wins
Number of trades that reached TP3 before Stop Loss under the script’s bar-touch rules.
Losses
Number of trades recorded at Stop Loss.
Win Rate
TP3 Wins divided by Closed Trades.
NET R
Gross Profit R minus Gross Loss R.
Gross Profit
Sum of winning TP3 R values.
Gross Loss
Number of losing trades expressed as R because every Stop Loss equals -1R.
Average / Trade
NET R divided by Closed Trades.
Profit Factor
Gross Profit R divided by Gross Loss R.
Mobile Theme displays only:
• Win Rate
• NET R
The dashboard is placed on the main chart even though the indicator calculates in a separate RSI pane.
━━━━━━━━━━━━━━━━━━━━━━
📊 STATISTICS METHODOLOGY
━━━━━━━━━━━━━━━━━━━━━━
The statistics are produced by the script’s internal bar-based trade tracker.
They are not imported from a broker.
They are not verified account results.
They are not TradingView Strategy Tester results.
Win Rate:
wins / closed trades
Gross Profit R:
wins × selected TP3 R
Gross Loss R:
losses × 1R
NET R:
Gross Profit R − Gross Loss R
Average R:
NET R / closed trades
Profit Factor:
Gross Profit R / Gross Loss R
When there are profitable trades but no recorded losses, the script displays 999 as a finite placeholder instead of mathematical infinity.
The statistics do not include:
• TP1 partial profits
• TP2 partial profits
• break-even exits
• trailing stops
• spread
• commission
• slippage
• swap
• latency
• order rejection
• partial fills
• position sizing
• account equity
• compounding
• taxes
Statistics depend on:
• loaded chart history
• selected symbol
• timeframe
• data provider
• Pivot Lookback
• Confirmation Bars
• Trend Filter
• HTF Trend Timeframe
• ATR Period
• Stop Loss multiplier
• TP3 target
• historical-data revisions
Changing any of these inputs can change historical results.
━━━━━━━━━━━━━━━━━━━━━━
🚨 ALERT SYSTEM
━━━━━━━━━━━━━━━━━━━━━━
The script includes static TradingView alert conditions for:
• Regular Bullish Divergence
• Hidden Bullish Divergence
• Regular Bearish Divergence
• Hidden Bearish Divergence
• BUY Entry
• SELL Entry
• TP3 Hit
• Stop Loss Hit
Regular bullish and bearish divergence are enabled in the current public configuration.
Hidden bullish and hidden bearish divergence logic is internally disabled.
The hidden alert choices can therefore appear in TradingView’s alert-condition list, but no hidden divergence event is produced while the internal hidden-divergence switches remain disabled.
The script also includes dynamic alert() calls for:
• BUY entry
• SELL entry
• TP3 hit
• Stop Loss hit
Dynamic BUY and SELL messages can include:
• tradewsamet identifier
• chart ticker
• chart timeframe
• entry price
• TP1 price
• TP2 price
• TP3 price
• Stop Loss price
• final R target
• active Trend Filter
This allows one TradingView alert using:
Any alert() function call
to receive all dynamic entry and result events.
━━━━━━━━━━━━━━━━━━━━━━
🔔 HOW TO USE ALERTS
━━━━━━━━━━━━━━━━━━━━━━
For a specific static event:
1. Add RSI Divergence Entry Engine to the chart.
2. Open TradingView’s Create Alert window.
3. Select the indicator as the condition.
4. Choose the required event.
5. Select the notification method.
6. Use an appropriate frequency.
7. Test the alert before relying on it.
For one combined dynamic workflow:
1. Add the indicator to the chart.
2. Open Create Alert.
3. Select RSI Divergence Entry Engine .
4. Select Any alert() function call.
5. Configure the delivery method.
6. Test BUY, SELL, TP3, and SL message handling.
When the script, settings, symbol, or timeframe changes materially, recreate existing alerts.
A TradingView alert can continue using the script snapshot stored when the alert was created.
Alerts are monitoring tools.
They do not execute, modify, or close broker orders.
━━━━━━━━━━━━━━━━━━━━━━
🧪 HOW TO USE THE INDICATOR
━━━━━━━━━━━━━━━━━━━━━━
A practical workflow:
1. Add RSI Divergence Entry Engine to a standard candlestick chart.
2. Select Dark Mode, Light Mode, or Mobile Theme.
3. Begin with Pivot Lookback set to 5.
4. Begin with Confirmation Bars set to 1.
5. Observe the RSI-panel divergence structures.
6. Observe the matching neon price-pivot lines on the main chart.
7. Remember that the pivot visual becomes available only after right-side confirmation.
8. Distinguish the neon divergence line from the later tracked entry label.
9. Begin with Trend Filter set to Off when studying raw divergence frequency.
10. Test EMA Trend for chart-timeframe directional alignment.
11. Test Supertrend for volatility-based directional alignment.
12. Test HTF Trend for higher-timeframe EMA context.
13. Verify the selected HTF timeframe.
14. Review the main-chart trend reference.
15. Observe whether a BULLISH or SELL entry label is accepted.
16. Review ENTRY, SL, TP1, TP2, and TP3 prices.
17. Observe the profit and risk boxes.
18. Remember that TP1 and TP2 are visual only.
19. Review the final TARGET HIT or SL result.
20. Review dashboard Win Rate and NET R.
21. Compare Dark/Light full dashboard with Mobile Theme.
22. Use alerts for monitoring rather than blind execution.
23. Review broader market structure independently.
24. Review spread, liquidity, volatility, and news conditions.
25. Define personal account risk and position size.
26. Test the exact symbol, timeframe, and data feed personally used.
The indicator is designed for structured study and monitoring.
It should not be treated as an automatic decision-maker.
━━━━━━━━━━━━━━━━━━━━━━
⚙️ SETTINGS REFERENCE
━━━━━━━━━━━━━━━━━━━━━━
🎨 Theme
Theme Mode
Dark Mode
Uses the full dark visual profile.
Light Mode
Uses the full light visual profile.
Mobile Theme
Uses compact labels and a two-row dashboard.
━━━━━━━━━━━━━━━━━━━━━━
🎯 Signal Settings
Pivot Lookback
Controls the left-side pivot search width.
Default:
5
Higher values generally create larger and less frequent pivot structures.
Confirmation Bars
Controls the number of right-side completed candles required to confirm the RSI pivot.
Default:
1
Increasing the value increases confirmation delay.
Chart Signal Label Size
Controls the main-chart BULLISH and SELL entry-label size.
Available values:
• Tiny
• Small
• Normal
• Large
• Huge
Mobile Theme overrides the selected size with a compact layout.
━━━━━━━━━━━━━━━━━━━━━━
🧭 Trend Filter
Trend Filter
Available modes:
• Off
• EMA Trend
• Supertrend
• HTF Trend
Off
Allows tracked bullish and bearish entries without directional trend filtering.
EMA Trend
Uses chart close relative to EMA 200.
Supertrend
Uses ATR 10 and factor 3.0.
HTF Trend
Uses selected higher-timeframe close relative to higher-timeframe EMA 200.
HTF Trend Timeframe
Selects the higher timeframe used by HTF Trend.
Default:
240 minutes
This setting has no effect when HTF Trend is not selected.
━━━━━━━━━━━━━━━━━━━━━━
🛡️ Trade Management
ATR Period
Controls the ATR used for risk-distance calculations.
Default:
14
Stop Loss Distance (ATR)
Multiplies ATR to calculate the Stop Loss distance.
Default:
2.0
TP3 Target (R)
Selects the final target from 1R to 7R.
Default:
2R
TP1 and TP2 are calculated automatically from the TP3 distance.
All public input values are hidden from TradingView’s status line to reduce chart-header clutter.
━━━━━━━━━━━━━━━━━━━━━━
🧠 WHAT MAKES THIS SCRIPT ORIGINAL
━━━━━━━━━━━━━━━━━━━━━━
RSI, divergence, EMA, Supertrend, ATR, risk/reward targets, and trade statistics are established technical-analysis concepts.
These concepts are not unique by themselves.
The originality of RSI Divergence Entry Engine lies in the coordinated workflow applied to them:
fixed RSI calculation
→ confirmed oscillator pivots
→ price / RSI regular divergence comparison
→ pivot-distance validation
→ RSI-path divergence filling
→ main-chart three-layer neon pivot lines
→ optional chart or higher-timeframe trend filtering
→ one-active-trade state
→ confirmation-candle entry
→ ATR-normalized Stop Loss
→ proportional TP1 / TP2 placement
→ adjustable TP3 R target
→ conservative OHLC exit handling
→ permanent risk/reward history
→ historical target-price labels
→ theme-aware chart output
→ mobile-specific dashboard
→ internal R-based statistics
→ static and dynamic alert workflows
Distinctive implementation features include:
• separating divergence context from accepted tracked entries
• displaying the same confirmed divergence in the RSI pane and on the main chart
• filling the RSI path-to-divergence region
• using a three-layer neon price-divergence line
• preserving trade boxes after closure
• preserving TP1, TP2, and TP3 planned prices historically
• allowing multiple direction-filter models inside one entry workflow
• maintaining one tracked trade at a time
• applying conservative Stop Loss priority when TP3 and SL share a candle
• offering theme-specific dashboard behavior
• reducing the Mobile Theme dashboard to Win Rate and NET R
• supporting static conditions and combined dynamic alert() messages
• keeping public settings compact while documenting fixed internal values
The script is not a collection of unrelated indicators placed on one chart.
Every component supports the same objective: converting a confirmed RSI divergence into a transparent, filterable, volatility-mapped, historically reviewable entry framework.
━━━━━━━━━━━━━━━━━━━━━━
⚠️ IMPORTANT PRACTICAL NOTES
━━━━━━━━━━━━━━━━━━━━━━
Signal frequency depends on:
• symbol
• timeframe
• data provider
• Pivot Lookback
• Confirmation Bars
• fixed 5–60 bar pivot-distance window
• Trend Filter
• HTF Trend Timeframe
• existing active-trade state
• ATR availability
• available historical data
Higher Pivot Lookback values can reduce frequency.
Higher Confirmation Bars values increase delay.
EMA Trend can reject counter-position signals relative to EMA 200.
Supertrend can change direction after price movement.
HTF Trend can remain sensitive to the currently developing higher-timeframe candle.
Only one tracked trade can be active.
A divergence can therefore be visible without becoming a tracked trade.
TP1 and TP2 are not partial exits.
Historical TP1, TP2, and TP3 labels display planned prices, not proof that every level was touched.
Dashboard statistics use loaded chart history only.
Different brokers or exchanges can produce different:
• highs
• lows
• closes
• RSI pivots
• ATR values
• divergence signals
• trend-filter states
• TP3 / SL outcomes
• dashboard statistics
Changing the chart’s available history can change the first eligible pivot pair and all later trade-state sequencing.
━━━━━━━━━━━━━━━━━━━━━━
⚠️ LIMITATIONS AND SHORTCOMINGS
━━━━━━━━━━━━━━━━━━━━━━
This script has important limitations:
It does not guarantee profitable trades.
It does not predict future price movement.
It does not execute orders.
It does not place broker Stop Loss orders.
It does not place broker Take Profit orders.
It does not calculate position size.
It does not calculate account risk.
It does not include spread.
It does not include commission.
It does not include slippage.
It does not include latency.
It does not include swap or financing.
It does not model partial fills.
It does not model order rejection.
It does not model contract specifications.
It does not model tick-by-tick execution.
It uses historical OHLC bars.
It cannot always determine whether TP3 or SL occurred first inside one candle.
It resolves same-candle TP3 / SL ambiguity in favor of Stop Loss.
It does not record TP1 or TP2 as partial profit.
It does not move Stop Loss to break even.
It does not trail Stop Loss.
It maintains one active tracked trade.
It can ignore otherwise valid new entries while a trade is active.
It uses pivot confirmation.
Pivot visuals are not available on the original pivot candle in realtime.
RSI pivot visuals are placed at the historical pivot location after confirmation.
Main-chart neon lines are created after divergence confirmation.
The HTF filter can change while the current higher-timeframe candle remains open.
A confirmed divergence can fail.
A trend-aligned divergence can fail.
A larger divergence area does not guarantee a stronger result.
A neon divergence line is not guaranteed support or resistance.
A TARGET HIT label is not broker-verified execution.
Dashboard statistics are not audited performance.
Profit Factor displays 999 when wins exist without recorded losses.
Changing settings recalculates historical conditions.
Changing symbol, timeframe, provider, or available history can change output.
Alert delivery depends on TradingView and user configuration.
Alerts do not guarantee broker execution.
For these reasons, the indicator should be used as an educational decision-support and chart-review tool, not as a standalone automated strategy.
━━━━━━━━━━━━━━━━━━━━━━
👤 WHO THIS SCRIPT MAY BE USEFUL FOR
━━━━━━━━━━━━━━━━━━━━━━
This script may be useful for traders who:
• understand basic RSI divergence
• want regular bullish and bearish divergence visuals
• prefer pivot-confirmed structures
• want divergence displayed in both RSI and price
• want a clear neon main-chart divergence line
• want optional trend filtering
• use EMA 200
• use Supertrend
• use higher-timeframe direction
• want ATR-based risk mapping
• want adjustable R targets
• want historical risk/reward boxes
• want historical planned TP prices
• want one-active-trade statistics
• want Dark, Light, and Mobile themes
• want static alerts
• want one combined dynamic alert
• understand that chart statistics are not verified trading results
It may be less suitable for users who:
• want signals on the unconfirmed pivot candle
• want no pivot delay
• want hidden divergence enabled publicly
• want every divergence to open a trade
• want multiple overlapping tracked trades
• want partial TP accounting
• want automatic break-even management
• want trailing stops
• want tick-level backtesting
• want verified Strategy Tester results
• want broker execution
• want guaranteed reversal signals
• expect a high Win Rate to continue unchanged
• expect the HTF filter to remain fixed before the higher-timeframe candle closes
━━━━━━━━━━━━━━━━━━━━━━
🧭 BEST PRACTICE SUGGESTIONS
━━━━━━━━━━━━━━━━━━━━━━
For studying raw divergence behavior:
• use Trend Filter Off
• begin with Pivot Lookback 5
• begin with Confirmation Bars 1
• observe divergence visuals before evaluating trades
• distinguish pivot location from confirmation timing
For trend-aligned divergence:
• test EMA Trend
• test Supertrend
• compare signal frequency
• review whether the filter removes useful countertrend setups
For broader directional context:
• test HTF Trend
• use a higher timeframe meaningfully above the chart timeframe
• remember that the active HTF candle can change before closing
For trade mapping:
• begin with ATR 14
• begin with Stop Loss Distance 2.0 ATR
• begin with TP3 2R
• remember that TP1 and TP2 are visual only
• review same-candle TP3 / SL cases conservatively
For chart clarity:
• use Dark Mode on dark chart layouts
• use Light Mode on light chart layouts
• use Mobile Theme on small screens
• adjust the main-chart entry-label size
• use neon divergence lines as context, not automatic entries
Always:
• wait for divergence confirmation
• review broader price structure
• review liquidity and volatility
• review session conditions
• review news risk
• define personal account risk
• define personal position size
• test the exact symbol and timeframe
• verify alerts before relying on them
• remember that every divergence can fail
━━━━━━━━━━━━━━━━━━━━━━
🔓 PUBLICATION NOTE
━━━━━━━━━━━━━━━━━━━━━━
RSI Divergence Entry Engine is published as an educational RSI-divergence, directional-filtering, ATR trade-mapping, historical-visualization, and alert tool.
The purpose of this description is to explain:
• how RSI is calculated
• how RSI pivot lows and highs are confirmed
• how Pivot Lookback affects structure selection
• how Confirmation Bars affect delay
• how the fixed pivot-distance window works
• how regular bullish divergence is identified
• how regular bearish divergence is identified
• how divergence is displayed inside the RSI pane
• how the RSI divergence area is filled
• how corresponding price pivots are displayed with neon lines
• when the pivot visuals become available
• why pivot visuals appear at historical pivot locations
• why tracked entries are placed on confirmation-candle close
• how the trend filter affects entries without hiding divergence context
• how EMA Trend works
• how Supertrend works
• how HTF Trend works
• how currently forming higher-timeframe candles affect realtime context
• how ATR risk distance is calculated
• how Stop Loss is placed
• how TP1, TP2, and TP3 are calculated
• why TP1 and TP2 are visual only
• why only TP3 counts as a win
• how one-active-trade handling works
• how same-candle TP3 / SL ambiguity is resolved
• how historical trade boxes are retained
• what historical TP labels represent
• how Dark Mode, Light Mode, and Mobile Theme differ
• what the dashboard displays
• how Win Rate, NET R, Average R, and Profit Factor are calculated
• why the statistics are not broker-verified
• what static alert conditions are available
• how “Any alert() function call” works
• what the script does not simulate
• why the combined modules form one coordinated workflow
The script is designed to support structured review.
It does not promise profitable results.
It does not remove market risk.
It does not replace independent analysis.
It does not replace personal risk management.
━━━━━━━━━━━━━━━━━━━━━━
🕒 REPAINTING, BACKPLOTTING, AND TIMING DISCLOSURE
━━━━━━━━━━━━━━━━━━━━━━
RSI Divergence Entry Engine uses pivot functions.
Pivot confirmation requires future candles relative to the original pivot location.
The number of required right-side candles is controlled by Confirmation Bars.
The script does not know that a pivot exists on the original pivot candle.
After the right-side candles close:
• the pivot becomes confirmed
• the divergence can be calculated
• the RSI divergence line is displayed at the historical pivot locations
• the RSI divergence label is displayed at the confirmed pivot location
• the main-chart neon line connects the corresponding historical price pivots
This historical placement is a visual back-reference to the confirmed pivot structure.
It must not be interpreted as a realtime signal that was available on the original pivot candle.
The tracked trade entry is not backdated.
The tracked trade opens at the close of the later confirmation candle when all entry rules are valid.
The main-chart BULLISH or SELL entry label appears on that confirmation candle.
Trade outcome checks begin on the following candle.
The HTF Trend request uses lookahead_off.
It does not intentionally access future higher-timeframe values.
However, the current higher-timeframe candle can continue developing in realtime until it closes.
Historical results can change when:
• Pivot Lookback changes
• Confirmation Bars changes
• Trend Filter changes
• HTF Trend Timeframe changes
• ATR settings change
• TP3 target changes
• chart symbol changes
• timeframe changes
• exchange or broker feed changes
• historical data is revised
• available chart history changes
Confirmed chart-bar calculations reduce unfinished current-chart-candle changes.
They do not remove pivot confirmation delay, historical pivot placement, HTF live-candle variation, data-feed differences, or market risk.
━━━━━━━━━━━━━━━━━━━━━━
🛡️ DISCLAIMER
━━━━━━━━━━━━━━━━━━━━━━
RSI Divergence Entry Engine is provided for educational and informational purposes only.
It does not constitute financial, investment, trading, legal, accounting, or tax advice.
No indicator can guarantee future results.
Markets are uncertain.
Momentum changes.
Volatility changes.
Trend changes.
Liquidity changes.
Historical chart behavior does not ensure future performance.
Every user is responsible for their own:
• analysis
• validation
• symbol selection
• timeframe selection
• trend-filter selection
• execution planning
• Stop Loss placement
• target planning
• position sizing
• risk management
• alert configuration
• trading decisions
• broker execution
• legal obligations
• tax obligations
The RSI pivots, divergence lines, divergence fills, neon price-pivot lines, trend references, BULLISH labels, SELL labels, ENTRY labels, Stop Loss levels, TP1 levels, TP2 levels, TP3 levels, trade boxes, historical target labels, TARGET HIT labels, SL labels, dashboard statistics, Win Rate, NET R, Average R, Profit Factor, and alerts are visual analysis tools only.
A bullish divergence is not a guaranteed reversal.
A bearish divergence is not a guaranteed reversal.
An EMA-aligned signal is not guaranteed to succeed.
A Supertrend-aligned signal is not guaranteed to succeed.
A higher-timeframe aligned signal is not guaranteed to succeed.
A TARGET HIT label is not proof of an actual broker fill.
An SL label is not proof of an actual broker fill.
The dashboard is not verified account performance.
The statistics are not audited.
The script does not include spread, commission, slippage, latency, financing, partial fills, order rejection, position sizing, account equity, or broker-specific execution behavior.
Use the script as a structured RSI-divergence review, directional-filtering, trade-mapping, and monitoring framework—not as a promise of profitability or a substitute for independent judgment.
Indicateur

Auto-ATR Volatility Spike & Trend Tracker [BigBeluga]Auto-ATR Volatility Spike & Trend Tracker is an institutional-grade algorithmic trend-following terminal engineered for TradingView. It is specifically built to isolate high-momentum breakout anomalies (spikes) from ordinary noise and anchor a dynamic, risk-managed trailing stop-loss directly to the underlying structural expansion.
By merging volumetric price momentum with an adaptive Average True Range (ATR) detection framework, this indicator completely redefines how breakout traders enter and manage trends. Instead of reacting blindly to standard moving average crosses, the system utilizes an execution state machine that locks onto systemic market expansion, tracks trend health via dynamic midpoint lines, and protects capital with a trailing protection line.
🔵 CHANNELS & ARCHITECTURAL CORE ENGINE FEATURES
1. Dual-Mode Spike Detection System
Auto ATR Volatility Engine: Automatically adapts to varying market conditions. By cross-referencing incoming candle structures against an ATR Length multiplier baseline, the indicator filters out flat consolidation periods and flags abnormal, high-liquidity volume expansions that signify true institutional participant footprints.
Fixed Percentage Breakout Mode: For traders operating in highly structured assets with predictable daily limits, this module locks onto absolute price change thresholds ( Fixed Spike Threshold % ), isolating momentum moves that pierce predefined parameters.
Wick-to-Body Range Toggle: Allows you to switch calculations to run from either the raw candle body (Open to Close) or the full extreme range ( Calculate From Wicks (High/Low) ). This isolates clean structural closes while adjusting to high-volatility liquidity sweeps.
2. Predictive Mid-Level Benchmarks & Spacing Visuals
Dynamic Mid Level Dash Lines: When a valid trend spike is verified, the engine immediately draws a horizontal midpoint line extending from the center of the candle ( Display Mid Level Dash Line ). This centerline serves as an immediate structural macro floor or ceiling; as long as price retains this boundary, the primary breakout impulse remains historically intact.
Measurement Arrow Guides & Measurement Labels: Automatically draws measurement arrow guides along with real-time text percentage indicators directly over the breakout candle ( Display Size % Labels & Arrow Lines ). This gives you instant clarity on the volatility profile without needing to use manual drawing tools.
3. Algorithmic State Machine & Trailing Protection
Volatility-Adjusted Trailing Stops: Once a breakout trend is established, the indicator deploys a step-calculated trailing line based on your Trailing ATR Multiplier . This line is engineered to trail tightly beneath bullish expansions or above bearish flushes, keeping you safely in the macro trend while mitigating downside variance.
Trend Interlock Protection: The underlying state machine features built-in trigger restrictions that lock execution while a trend is dominant. This prevents counter-trend false entries or premature reversals, keeping your focus strictly on the dominant structural path.
Theme Overwrite Candlesticks: Completely recolors the active layout chart workspace bars using vivid, customized hex-theme presets ( Bullish/Bearish Theme Colors ) the exact moment an abnormal spike is validated.
4. Persistent Macro Statistics Dashboard Matrix
Top-Right Analytics HUD Table: Instantly maps out a high-performance database grid showing critical data points from the most recent historical market expansions.
Real-Time Metrics Monitoring: Explicitly stores and displays the precise directional Spike Type , Size (%) , and exact entry execution Price for both bullish and bearish cycles, providing a reliable quantitative snapshot of the asset's structural strength.
🔵 SYSTEMATIC EXECUTION STRATEGIES & RISK INTERPRETATION
Midpoint Re-test Accumulation Plays: When a powerful up-spike forces a market breakout, do not chase the initial overextended move. Instead, wait for a constructive pullback toward the extended dynamic dashed midline. If price builds a base and prints a clean rejection candle at this level, it signals a premium, low-risk continuation entry aligned with institutional order flow.
Trailing ATR Invalidation Exits: The trailing stop-loss line acts as your absolute trend line invalidation boundary. In a powerful bullish expansion, the indicator will continuously trail and lock in accrued profit beneath the recent low points. A clean daily close crossing beneath this line confirms an official trend termination, signaling an immediate exit to protect your capital.
Breakout Sizing Divergences: Cross-reference the live metrics dashboard data to spot exhausting trends. If an asset is pressing higher but newly generated bullish spikes show smaller percentage sizes compared to the historical records on your HUD table, it exposes fading momentum—frequently warning of an impending reversal or structural distribution phase.
🔵 INTERFACE CONFIGURATION AND PARAMETERS
Detection Mode Controls: Choose between Auto ATR or Fixed % settings and specify lookback periods to customize the indicator to match any asset class, volatility cycle, or execution chart timeframe.
Visibility Filters Overrides: Independently toggle midlines, trailing stops, background cloud color fills, or measurement labels to maintain a clean, distraction-free charting interface.
Theme Personalization Modifiers: Fully adjust color properties for upward spikes, downward spikes, buy/sell arrows, and trailing lines to blend seamlessly into your dark or light workspace layout themes.
Transform your charting workspace from speculative guessing into an automated, volatility-tracked breakout environment with the Auto-ATR Volatility Spike & Trend Tracker terminal. Indicateur

W-X-Y Pattern Auto Targets Pro [JPT]🔷 OVERVIEW
W-X-Y Pattern Auto Targets Pro is an educational price action indicator that automatically detects potential W-X-Y reversal structures using confirmed swing points. When a valid setup is identified, the indicator displays a complete trade framework including an Entry level, Stop Loss, and multiple Take Profit targets.
The indicator is designed to help traders visualize market structure and practice trade planning. It does not predict future price movement or guarantee profitable trades.
🔷 FEATURES
Automatic W-X-Y pattern detection
Bullish and bearish setups
Entry, Stop Loss, TP1, TP2, and TP3 levels
Risk/Reward visualization
EMA 50 & EMA 200 trend filter
Confirmed swing-based structure
Optional alerts for new setups
Clean chart layout with minimal clutter
🔷 HOW IT WORKS
Detects confirmed swing highs and swing lows.
Identifies potential W-X-Y reversal formations.
Applies the optional EMA trend filter for additional market context.
Calculates Entry, Stop Loss, and Take Profit levels based on the detected structure.
Draws the setup directly on the chart for easy analysis
🔷 HOW TO USE
Look for newly detected W-X-Y patterns.
Review the market structure and overall trend before making any trading decisions.
Use the displayed Entry, Stop Loss, and Take Profit levels as a reference for planning trades.
Consider combining this indicator with your own confirmation methods and risk management rules.
🔷 NOTES
Signals are generated from historical and confirmed price structure.
The indicator is intended as an educational and analytical tool.
No indicator can guarantee successful trades, and this script should not be used as the sole
basis for investment or trading decisions.
If you find this project useful your feedback and suggestions are always appreciated Happy trading! Indicateur

Uptrick: Flow Expansion TrendIntroduction
Uptrick: Flow Expansion Trend (FET) is an overlay tool built around an efficiency-adaptive midline that speeds up or slows down based on how directional recent price movement has been. The midline is paired with a volatility-based signal boundary and a minimum flow-strength filter to determine confirmed trend flips, and the script includes a market-state read that classifies current conditions as directional, developing, or compressed. Signal labels can be anchored to price highs and lows, a fixed ATR distance from price, or the midline itself.
Originality
This script's core is an efficiency ratio, calculated as the net price movement over a lookback divided by the sum of all bar-to-bar movement over that same lookback, which produces a value between 0 and 1 describing how directional versus choppy the recent path has been. Rather than using this ratio as a standalone oscillator, it is fed into the smoothing constant of the midline itself, so the midline's responsiveness continuously adjusts between a fast and slow smoothing constant based on current market efficiency. This is what separates the midline from a standard moving average, since it does not use a fixed lookback response but instead reshapes itself with the character of the move.
The signal boundary distance around the midline is also adaptive: it widens or narrows based on the same efficiency reading, so the distance price must travel to trigger a trend flip contracts in efficient, directional conditions and expands in choppier ones. A trend flip additionally requires a minimum flow-strength threshold, a normalized measure of the midline's own rate of change relative to ATR, so a boundary breach alone is not sufficient to flip the trend without accompanying follow-through in the midline's slope.
Combining an adaptive midline, an adaptive signal boundary, and a flow-strength confirmation filter into a single confirmed-trend mechanism is the original contribution of this script, since each of the three components is derived from the same efficiency and volatility inputs but serves a distinct role in preventing premature or noise-driven flips. The selectable signal anchor further separates the trend calculation from the signal display, letting traders choose whether labels sit at the bar's high/low, a fixed ATR offset from price, or directly on the midline, without altering the underlying trend logic in any way.
Features
Efficiency-adaptive midline that adjusts its smoothing speed based on how directional recent price action has been
Adaptive signal boundary that widens in choppy conditions and narrows in directional conditions
Minimum flow-strength filter required alongside a boundary breach to confirm a trend flip
Confirmed-bar trend state calculation to avoid intrabar repainting of the trend flip
Selectable signal anchor for up and down labels: high/low, fixed ATR distance from price, or midline
Adjustable ATR distance value when the ATR distance anchor is selected
Up and down trend signal labels
Optional candle coloring based on the most recent confirmed signal
Adjustable midline width
On-chart dashboard showing trend, market efficiency percentage, flow strength, market state classification, bars since the last signal, and current signal anchor mode
Four selectable dashboard positions
Four alert conditions: up signal, down signal, any trend signal, and market becoming directional
Inputs
Trend Engine: source, trend length, signal distance multiplier, minimum signal strength threshold.
Signals: show/hide up and down signals, signal anchor mode, signal ATR distance.
Visuals: candle coloring toggle, midline width, show/hide dashboard, dashboard position.
How It Works / How to Use
The script measures how efficiently price has moved over the trend length by comparing net displacement to total path length traveled. This efficiency value continuously reshapes the midline's smoothing speed, so the midline hugs price more closely in strong directional runs and lags more in choppy conditions. An ATR-based boundary is placed around the midline, with its distance also scaled by the same efficiency reading. A trend flip is confirmed only when price closes beyond this boundary on a confirmed bar and the midline's own rate of change exceeds the minimum flow-strength threshold in that direction.
Once a flip is confirmed, the up or down label is placed according to the chosen signal anchor: at the bar's high or low, at a fixed ATR distance beyond price, or directly on the midline. This is purely a display choice and does not affect when or why a trend flip occurs.
Traders can use the midline's slope and color for ongoing directional bias, the up and down signals for confirmed flips, and the dashboard's market-state classification to gauge whether current conditions are more suited to trend-following or more likely to produce choppy, range-bound behavior.
Conclusion
Uptrick: Flow Expansion Trend combines an efficiency-adaptive midline, a matching adaptive signal boundary, and a flow-strength confirmation filter into a single trend-following overlay, giving traders a trend read that reshapes itself with current market conditions rather than relying on a fixed-speed average, with flexible signal placement to suit different charting preferences.
Disclaimer
This script is provided for informational and educational purposes only and does not constitute financial advice. Past performance, whether shown historically or implied through the script's logic, does not guarantee future results. Always perform your own due diligence and risk management before making trading decisions. Indicateur

Indicateur

Strong Gradient Channel | ProjectSyndicateStrong Gradient Channel combines a full order-flow volume profile along the slope of a linear-regression channel, splits every price level into real buy and sell mass, grades the auction, and projects a forward route that stays locked inside the channel walls. It is not a channel with an indicator bolted on — the channel, the profile, the order flow and the outlook are one connected engine, and every number on the panel is measured, not invented.
USDJPY
🟥🟩 IMPORTANT INFO: The channel, the volume profile and the deviation walls are all computed over the same regression window, so the tool self-calibrates to whatever you load it on. Defaults are tuned for a wide 480-bar window on HLC3. Works on any symbol and timeframe; on very high timeframes drop the Channel Length so the profile stays representative of current structure.
📐 A Volume Profile That Follows the Trend — the core of this tool. Every other volume profile is drawn as flat horizontal rows, which quietly assumes price has no trend. This one doesn't. The profile is poured along the regression slope, so each row is a parallelogram tracking the channel's gradient. In a trending market that means the POC, the value area and every heavy level sit where volume actually built — on the diagonal — instead of being smeared into a flat histogram that ignores the move. The result is a value map that tells the truth about a sloped market.
🧲 Real Buy / Sell Split, Not Guesswork. Each candle's volume is broken into its internal buy and sell halves using intrabar data pulled from a lower timeframe, then classified by close-location, body-direction, or a weighted blend you control. Every profile row renders as a stacked bull + sell parallelogram, so you see not just where volume traded but which side owned each level. A Delta POC line marks the row holding the largest one-sided imbalance, and rows exceeding mean + 2σ are flagged as institutional — unusually heavy single-level activity.
ES
⭐ POC, Value Area & Naked POC Magnets. The point of control, the value-area high and low, and the profile extremes are all drawn as sloped lines that ride the channel and extend to the right edge with live price labels. On top of that, the script tracks Naked POCs — the point-of-control of unusually strong individual candles — and extends each one to the right as a magnet until price trades back through it, then retires it. Untested value tends to get revisited; this shows you exactly where it lives.
♻️ Contrarian Fade Engine — auction exhaustion at the walls. When price pierces a channel wall and the order flow shows the move is running out of participation, the engine fires a FADE ▲ / FADE ▼ signal graded by a 0–10 conviction score. It isn't a naive "price touched the band" trigger — it reads the auction against the move and only fires when exhaustion and a local extreme line up, with a cooldown so you don't get a cluster of the same idea. Each signal can plot its own target and invalidation line.
🗺️ Scenario Projection — the powerful new part. This is not a hand-drawn arrow. The script walks the live channel forward from the last bar and assembles a route from surveyed structure: 1 · TRIGGER — the first objective. In Channel Extremes mode it rides the wall in the trigger direction; in Key Levels mode it snaps to the nearest POC / VA / ΔPOC. 2 · REVERSE — a retrace of that leg, sized by your ratio. 3 · RETEST — a partial recovery that deliberately fails short of the trigger extreme. 4 · TARGET — the objective on the far side of price: the opposite wall, or the strongest key level. 5 · EXTENSION — a continuation leg toward the far wall, if you enable Extended detail. Trigger direction defaults to Auto, taken from the live net-flow bias (buy/sell split + slope + CVD). Every leg is a clean straight segment, bars-per-leg are allocated proportionally to price travel, and the whole path is clamped inside the sloped walls — so the outlook can span the full channel from the red wall to the green wall without ever looking synthetic or bowing outside structure.
📊 Command Dashboard — every figure measured. A compact panel that reports the whole engine at a glance, in five themed positions and four text sizes: CHANNEL & TREND — price regime (overbought / inside / oversold vs the walls), current price, slope and channel width. LIVE ORDER FLOW — the running buy/sell split and CVD read for the loaded window. VOLUME PROFILE — POC, value-area high/low and delta-POC prices straight off the sloped profile. AUCTION & FADE — the live fade signal, its direction, and its conviction stars. REGIME — a plain-language read of the overall state, including bullish / bearish reversal watches when regime and flow disagree. SCENARIO PATH — the full waypoint list: trigger, reverse, retest, target, extension, with prices and moves.
ETH
🔬 Non-Repainting By Construction. The regression, the profile and all levels are computed on closed bars and drawn on the last bar. Intrabar order flow is read from confirmed lower-timeframe data. Fade signals fire on bar close with a cooldown. Nothing is redrawn backwards once placed.
🎨 Clean Themed Visuals. Five palettes engineered for a pure-black background (Obsidian Aurora, Magma, Plasma, Deep Ocean, Graphite Mono), or full custom colors. Dashed value-area lines, a solid POC, red upper and green lower walls, an optional channel-body fill, a spectral volume-weighted ramp on the profile rows, and a scenario path drawn as a soft-glow core line with diamond waypoint markers, a terminal arrowhead and dotted trigger / target rails. An optional on-chart legend key explains every glyph.
🔔 Built-In Alerts & Standard-Chart Guard. Fade and structure events are surfaced on the panel and chart, firing on bar close. The script refuses to run on Heikin Ashi and Renko charts, because those distort the volume and price action the whole engine depends on — a guard most profile tools quietly skip.
🔧 Fully Customizable. Channel length, source and wall basis (Std Dev / Max Deviation / ATR) with independent upper and lower multipliers. Profile rows, width, anchor side, buy/sell split, value-area percent and every level toggle. Intrabar granularity and classification mode. The full fade filter set — conviction floor, extreme lookback, cooldown, target length. Naked-POC score floor and count cap. The complete scenario set — path detail, anchor mode, trigger direction, projection length, retrace and retest ratios, wall padding, right-extension length. Plus every theme, panel and legend option.
NVDA
🎯 Why this is different. Most volume-profile tools draw flat rows and pretend the market isn't trending. This one pours the profile along the actual regression slope, splits every level into real buy and sell mass, grades auction exhaustion at the walls, tracks untested POCs as forward magnets, and then projects a straight-line route that spans the full channel and stays locked inside it. Value, order flow, structure and outlook — one engine, one honest picture.
🧭 How to use it. · Read the dashboard before the chart. CHANNEL & TREND tells you where price sits relative to the walls; LIVE ORDER FLOW tells you which side is pressing; REGIME gives you the one-line summary. · Use the sloped profile as your value map. Price above a rising POC with buy-heavy rows is a different market than price below a falling POC — the diagonal keeps that distinction intact. Treat the POC and value area as magnets and the institutional rows as heavy shelves. · Watch the walls for the fade. A FADE ▲ / FADE ▼ at a wall with a high conviction score is the engine flagging exhaustion of a push into the extreme — a mean-reversion cue back toward the POC, not a blind reversal. · Treat the scenario as a roadmap, not a promise. TRIGGER is where the first objective sits, TARGET is the logical destination on the far side. In Channel Extremes mode the outlook spans wall-to-wall; switch to Key Levels for a tighter path that snaps to profile structure. If the Auto direction reads the wrong way for your bias, set Trigger Direction to Up First or Down First. · Combine, don't obey. Everything shown is descriptive of current structure, value and order flow — pair it with your own analysis and risk management.
EURUSD
⚙️ Key settings to know first. · Channel Length (default 480) — the single most important dial. It sets the regression window and the profile sample. Longer = the broader, structural channel; shorter = a reactive, local channel. · Source (default HLC3) — what the regression is fit to. HLC3 is smoother and less wick-sensitive than close. · Band Basis + Upper/Lower Mult — how wide the walls sit. Std Dev is statistical, Max Deviation hugs the most extreme wick, ATR is a volatility multiple. Independent multipliers let you build an asymmetric channel. · Trigger / Target Anchor — Channel Extremes makes the outlook span the whole channel wall-to-wall; Key Levels keeps it tight to POC / value area. · Extend Channel Right (bars) — how far the walls, midline and levels (and the room for the scenario) project past the last bar. · Use Intrabar Volume + Classification — the accuracy of the buy/sell split. Blend is the balanced default; turn intrabar off for a lighter, whole-candle read. · Min Conviction Score (Fade) — raise it to see only the highest-quality wall fades, lower it to see more.
⚠️ Important. This is a decision-support tool, not a standalone buy/sell system, and it makes no performance guarantees. Everything it displays is descriptive of current channel position, sloped-profile value, real order-flow split and measured auction state. The scenario path is level geometry rendered forward — a current-state projection that re-solves as structure changes, not a forecast of price, and it carries no probability claim. Volume-split figures are reconstructed from intrabar data and bar geometry, not raw tick data. Behaviour varies by symbol, timeframe and configuration. Always combine it with your own analysis and risk management, and test it on your market before trading it live. Indicateur

Dynamic Market Metrics [MarkitTick]💡 All-in-one market analysis suite designed to unify trend evaluation, momentum measurement, and dynamic risk management into a single, cohesive interface. Rather than relying on a scattered array of disparate indicators, this unified system synthesizes multiple dimensions of market data—including volatility, money flow, and higher-timeframe confluence—to provide a comprehensive structural overview of the current asset. It visually maps trend direction, plots actionable trade risk levels, and features a real-time heads-up display (HUD) dashboard to track critical market internals without cluttering the charting workspace.
● Overview
✨ Originality and Utility
Traditional technical analysis often forces traders to compromise between lagging trend followers and noisy momentum oscillators. This script solves that divergence by integrating an adaptive trend baseline with volume-weighted momentum constraints. It is unique in its ability to automatically map forward-looking risk-to-reward brackets the moment a structural shift is confirmed. Instead of guessing where to place stops and targets, the system calculates these thresholds dynamically based on real-time volatility, offering a strictly objective framework for trade management. This eliminates the need for messy chart mashups, replacing them with a highly organized, singular logic engine.
🔬 Methodology and Concepts
The core engine of this tool operates on an abstracted synthesis of price volatility and money flow dynamics.
The primary trend anchor is established by evaluating average true price ranges against the flow of capital entering or exiting the asset.
Rather than relying on simple price crosses, the baseline only shifts when confirmed by underlying volume and momentum pressures.
A specialized breakout override mechanism constantly monitors for abnormal momentum spikes. If a sudden surge in directional velocity exceeds the baseline volatility threshold, the system immediately recalculates the trend state to adapt to the new market structure.
Trade levels are generated using a dynamic risk parity model. The system measures the precise distance between the confirmed entry trigger and the structural invalidation point, projecting synchronized target tiers that maintain strict mathematical risk-to-reward ratios.
All higher-timeframe data integration is strictly coded using offset historical referencing, ensuring absolute data integrity and preventing any future leakage or repainting artifacts.
🎨 Visual Guide
The script utilizes a clean, professional aesthetic, heavily reliant on dynamic colors and structured dashboard elements.
• The Trend Anchor and Cloud
Trend Line: A distinct, segmented line that tracks the primary market direction. It colors dynamically based on the active state (Bullish, Bearish, or Neutral).
Dynamic Cloud: A semi-transparent filled area bridging the primary trend line and a smoothed reference baseline. The thickness of this cloud visually represents the immediate strength and momentum of the trend.
Candle Coloring: Chart candles are painted to match the active trend state, providing instant visual alignment with the underlying engine.
• Trade Levels and Signals
Signal Markers: Minimalist labels appear above or below the price action to indicate confirmed structural shifts.
Stop Loss (SL) Line: A solid line representing the exact invalidation point of the active trend.
Entry Line: A dashed line marking the exact price where the signal was confirmed.
Take Profit (TP) Lines: A series of three dashed lines representing incremental target zones.
Risk/Reward Fills: Shaded background zones visually map the risk area (Entry to SL) against the reward area (Entry to TP3), allowing for immediate visual risk assessment.
• The HUD Dashboard
Located in the top right corner, this data table provides a real-time read of market internals:
Trend State & HTF Context: Displays the current directional bias on both the local and higher timeframes.
Entry, Target, and SL: Prints the exact numerical values for the active trade parameters.
Momentum & Money Flow: Visual progress bars indicating the current intensity of price movement and capital flow.
Volatility: Indicates whether the market is currently in a state of expansion or contraction.
Trend Age: A counter showing exactly how many bars have elapsed since the current trend began.
📖 How to Use
The system is designed to be highly objective. Monitor the chart for a confirmed signal marker, which indicates a shift in the underlying structural trend. Once a signal fires, the script will automatically render the Entry, Stop Loss, and Take Profit levels.
Validation: Before considering the signal, check the HUD Dashboard. A high Momentum score and an aligned Higher Timeframe (HTF) Context significantly increase the probability of continuation.
Execution: Use the exact printed Entry line for placement. The Stop Loss line dictates the hard invalidation point where the premise of the trend is broken.
Management: As price moves in the anticipated direction, manage the position by scaling out or moving protective stops as the asset crosses the TP1, TP2, and TP3 thresholds.
Breakouts: If a sudden momentum burst triggers an override, the trend state will flip immediately. Treat these as aggressive volatility expansions that require tighter risk management.
⚙️ Inputs and Settings
The settings panel is modularized for precise user control:
• Core & Breakout
ATR Mult & Length: Adjusts the core sensitivity of the volatility engine. Lower values create a tighter, more reactive baseline.
BO Override & Sens: Toggles the momentum breakout detection and dictates how much abnormal velocity is required to override the primary trend.
• Higher Timeframe (HTF)
Show HTF & TF: Enables the integration of a secondary, longer-term timeframe to act as a directional filter.
• Trade Tools & Cloud
Show Trade Levels: Toggles the rendering of the dynamic Entry, SL, and TP lines.
Cloud Settings: Controls the length, transparency, and rendering of the visual trend cloud and candle coloring.
• Alerts & Colors
JSON Action Strings: Allows users to input custom formatted strings for Long, Short, and Close actions, perfectly integrating with automated third-party execution platforms.
Colors: Fully customizable palettes for all lines, fills, dashboards, and signal markers.
🔍 Deconstruction of the Underlying Scientific and Academic Framework
The architectural foundation of this system rests on auction market theory and the statistical properties of volatility clustering. Financial markets operate through continuous auctions where price discovery is driven by the aggressive absorption of resting liquidity. This engine abstracts that process by measuring the standard deviation of price excursions—quantifying the asset's true range—and mapping it against the directional flow of capital.
By analyzing the divergence between pure price action and volume-weighted accumulation, the system identifies the true mean of value. When price deviates beyond these statistical bounds accompanied by extreme momentum, it signals a structural paradigm shift rather than a standard mean-reversion event. Furthermore, the embedded risk parity model abandons static numerical thresholds in favor of dynamic proportional scaling. The reward brackets are continuously mathematically linked to the localized volatility of the anchor point, ensuring that the risk-to-reward distribution remains statistically constant regardless of the asset's current expansion or contraction phase.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. We expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Indicateur

Dynamic Range Pro [The_lurker]Dynamic Range Pro detects horizontal price-consolidation zones and grades
the quality of the breakout that follows — not a plain buy/sell signal, but
a transparent, live verdict on how much to trust it.
It is also a ground-up evolution of my earlier indicator, Dynamic Range Finder
While that tool relied on volume filters, TP/SL levels, and a stack of optional indicators, Dynamic Range Pro was rebuilt around a single specific question: is this consolidation genuinely real, and how good was the break that followed? Every gate and score below exists to answer one specific part of that question, and each has been tested on real historical data — not just code built on intuition.
🔑 AT A GLANCE
🔹 Four independent formation gates, not just an ATR box
🔹 Two synchronized range definitions — pick which one triggers signals
🔹 A graded breakout verdict instead of a flat buy/sell
🔹 A pre-breakout quality score that updates before any signal fires
🔹 Every claim below is backed by real backtested data
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🎯 WHAT MAKES IT DIFFERENT
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Most range indicators draw a single box from average price ± ATR and treat any close beyond it as a signal. Dynamic Range Pro adds three things most of them ignore entirely:
1️⃣ Smarter detection
A four-gate filter that rejects ranges a plain ATR test would wrongly accept — including the exact scenario where a sharp move inflates ATR enough to disguise an unstable window as a valid range.
2️⃣ A second, independent box
A close-based range you can promote to be the actual breakout trigger instead of the ATR box — no fixed rule, your choice.
3️⃣ A graded verdict, not a flat signal
Every breakout is scored across five factors into Strong / Inconclusive / Likely Trap, so you see the reasoning, not just an arrow.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🚦 FOUR-GATE RANGE DETECTION
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
A range is only confirmed when all four of these agree on the same bar:
1️⃣ ATR Containment
Recent closes stay within average price ± ATR × multiplier. The standard test nearly every range tool uses.
2️⃣ Horizontality
The correlation between close price and time over the lookback window stays below a threshold, filtering out windows that are quietly trending rather than truly sideways.
3️⃣ Absolute Amplitude Gate
The gate most tools miss. After a sharp move, ATR itself balloons, which can make gate 1 pass even for a range that clearly isn't one — a wider ATR band is simply easier to stay inside. This gate checks the actual high-to-low spread of the window as a plain percentage of price, independent of ATR, so an inflated ATR reading can no longer disguise a genuinely wide, unstable window as a valid range.
4️⃣ Entry-Slope Gate
Checks the price move across the first few candles of the window specifically. A window that starts mid-collapse and simply hasn't finished collapsing yet fails this gate even if the rest of the window looks calm.
🔸 Optional: Prior-Trend Filter
ADX measured at the window's starting edge can further restrict detection to ranges that formed after a genuine trend rather than from a standing start — useful for trend-then-consolidation strategies.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📦 TWO BOXES, YOUR CHOICE OF TRIGGER
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Dynamic Range Pro tracks two boxes at once:
1️⃣ Main Box (ATR-based)
The standard range: average price ± ATR × multiplier. The classic definition every range tool uses, and the default breakout trigger.
2️⃣ Inner Box (Close-based)
A second, independent box built purely from the highest and lowest closing prices reached during formation — ignoring wicks entirely. It gives a tighter, noise-resistant read on where price actually settled.
🔀 Box Mode — choosing the trigger
Display either box, both together, or promote the Inner Box to be the actual breakout trigger instead of the Main Box. Triggering on the Inner Box produces an earlier, narrower breakout definition — useful if you want to react before price clears the full ATR band, at the cost of more frequent signals.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🏆 GRADED BREAK-QUALITY VERDICT
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Instead of a plain buy or sell with no context, every confirmed breakout is
scored across five factors:
1️⃣ Trend strength (ADX)
Healthy within a defined range, overheated above it.
2️⃣ Momentum saturation (RSI)
Near-saturation in the breakout direction counts against the move.
3️⃣ Breach depth
How far the close cleared the boundary, in box-height units.
4️⃣ Pre-formation dispersion
How active the range was before the break, frozen at formation.
5️⃣ Directional flow alignment (DI spread)
Whether the directional-movement spread confirms or contradicts the
breakout direction.
Each factor votes toward a Strong / Inconclusive / Likely Trap verdict. You see the full breakdown on the chart — live during formation, frozen the moment the break confirms — so you can judge which factors are driving the call rather than trusting a closed label.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🏁 READING THE BOTTOM LINE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
The last row of the table condenses everything above it into one plain-language line that updates live. It only ever shows one of five states:
1️⃣ No box currently
No active or recently broken range exists — nothing to report yet.
2️⃣ Range active — awaiting break
A valid range currently exists, but price hasn't tested either boundary yet, so there's nothing to score yet.
3️⃣ ✅ Strong break
The five Break-Quality factors net to a score at or above the "strong" threshold — most factors support continuation.
4️⃣ ⚖️ Mixed (score shown)
The score lands between the strong and trap thresholds — factors are pulling in different directions, worth extra caution.
5️⃣ ⚠️ Likely trap
The score falls at or below the "trap" threshold — most factors point to exhaustion or reversal risk.
🔸 The ◷ symbol
When ◷ appears before a verdict, price is still breaching the boundary intrabar and the candle hasn't closed yet — a live, unconfirmed preview that can still change. Once the candle closes and the break is confirmed, ◷ disappears and the verdict locks in.
Both the "strong" and "trap" score thresholds are adjustable in settings.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🧬 RANGE INTEGRITY SCORE — before the break happens
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
The layer I find most exciting conceptually: a live 0-100 score describing how "clean" a forming range actually looks, computed continuously before any breakout occurs, from four independent angles:
1️⃣ Path noise
How much the close zigzagged relative to the window's total range.
2️⃣ Candle cohesion
How large individual candles are relative to the window.
3️⃣ Dispersion trend
Whether volatility is tightening or loosening over time.
4️⃣ Edge-touch count
How many times price tested the eventual boundary without breaking it.
This answers a different question than the Break-Quality Verdict does — not "how strong was the break," but "how trustworthy is this range in the first place" — and it updates live as the range develops, well before any signal fires.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📊 BUILT ON REAL DATA, NOT JUST INTUITION
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Every gate and score in this script has been tested against real 4H data across 19-20 Binance pairs, roughly 440-620 historical range/breakout events depending on the test. I publish exactly what that testing found, including where it didn't confirm my expectations:
✅ The prior-trend ADX filter measurably sharpens detection quality on the tested sample.
⚠️ Three of the five Break-Quality factors (RSI level, ADX magnitude, dispersion) did not show a measurable independent relationship with what happened after the break. They remain in the score as a transparent, chart-readable checklist rather than a claimed predictive edge — you see exactly which factors tipped any verdict and weigh them yourself.
📈 The Range Integrity Score showed a small, positive, not-yet-statistically-significant relationship with post-break continuation (r = +0.10, p = 0.20, n = 176) — a promising direction, not a proven signal yet, which is exactly why it's a display-only layer with no influence on alerts or box formation.
This is not a "trust the backtest" pitch — it's the opposite. Everything above is a starting point for your own judgment, not a replacement for it.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⚙️ PRACTICAL FEATURES
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🌐 Full Arabic/English toggle for the on-chart table and BUY/SELL labels (settings and alert text are bilingual either way)
🔔 BUY/SELL alerts, plus an optional intrabar "live breach" alert — early, purely informational, before the candle closes
📦 Historical range boxes are preserved cleanly across multiple formations, with no overlapping clutter
🎨 Every color, line width, and line style is customizable
🔒 All signals fire strictly on confirmed candle closes — no repainting, no lookahead
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🗣️ INTERFACE LANGUAGE
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Defaults to English. Switch "Table language" to Arabic in settings if you
prefer. Arabic-mode glossary:
Prior trend = الاتجاه السابق
Trend strength (ADX) = قوة الاتجاه
Break direction = اتجاه الكسر
Direction match = مطابقة الاتجاه
Breach depth = عمق الاختراق
Range dispersion = تشتت النطاق
Break verdict = تقييم الكسر
Range/entry % = امتداد/دخول %
Range integrity = تكامل النطاق
Range age = عمر النطاق
BUY/SELL = شراء / بيع
═════════════════════════════════════════════════════════════
⚠️ DISCLAIMER
═════════════════════════════════════════════════════════════
This indicator is for educational and analytical purposes only. It does not constitute financial, investment, or trading advice. Use it alongside your own strategy and risk management. Neither TradingView nor the developer is responsible for any financial decisions or losses.
══════════════════════════════════════════════════════════
══════════════════════════════════════════════════════════
Dynamic Range Pro
أداة تكتشف مناطق التوحيد السعريّ الأفقيّة ، وتُقيِّم جودة الكسر الذي يليها — لا مجرّد إشارة شراء أو بيع ، بل تقييم حيّ وشفّاف لمدى
الثقة به.
وهو أيضًا تطوير جذري كامل لمؤشّري السابق Dynamic Range Finder
بينما اعتمدت تلك الأداة على فلاتر الحجم ومستويات الجني/الخسارة وحزمة من المؤشرات الاختياريّة ، أُعيد بناء Dynamic Range Pro حول سؤال واحد محدّد: هل هذا التوحيد السعريّ حقيقيّ فعلًا ، وما مدى جودة الكسر الذي تلاه ؟
كل بوابة وكل درجة أدناه وُجدت للإجابة على جزء محدّد من هذا السؤال ، واختُبرت فعليًّا على بيانات تاريخيّة حقيقيّة — لا مجرّد كود مبنيّ على الحدس .
🔑 نظرة سريعة
🔹 أربع بوابات تكوين مستقلّة ، لا مجرّد صندوق ATR
🔹 تعريفا نطاق متزامنان — اختر أيّهما يُطلق الإشارات
🔹 تقييم متدرّج للكسر بدل شراء/بيع مسطّح
🔹 درجة جودة قبل الكسر تتحدّث قبل أيّ إشارة
🔹 كل ادّعاء أدناه مدعوم ببيانات باك-تست حقيقيّة
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🎯 ما الذي يميّزه فعليًّا
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
معظم مؤشّرات النطاق ترسم صندوقًا واحدًا من متوسط السعر ± ATR وتعتبر أيّ إغلاق خارجه إشارة . يضيف Dynamic Range Pro ثلاثة أمور يتجاهلها أغلبها كليًّا :
1️⃣ كشف أذكى
فلتر بأربع بوابات يرفض النطاقات التي كان اختبار ATR وحده سيقبلها خطأً ، بما في ذلك السيناريو تحديدًا حين تُضخِّم حركة حادّة قيمة ATR بما يكفي لتمويه نافذة غير مستقرّة كنطاق صالح.
2️⃣ صندوق ثانٍ مستقلّ
نطاق قائم على الإغلاق يمكنك ترقيته ليكون مصدر الكسر الفعليّ بدل صندوق ATR لا بقاعدة ثابتة — باختيارك .
3️⃣ تقييم متدرّج، لا إشارة مسطّحة
كل كسر يُقيَّم عبر خمسة عوامل إلى قوي / غير حاسم / مصيدة محتملة ، فترى السبب لا مجرّد سهم .
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🚦 كشف النطاق بأربع بوابات
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
لا يُعتمَد النطاق إلا حين تتّفق البوابات الأربع على نفس الشمعة :
1️⃣ احتواء ATR
الإغلاقات الحديثة تبقى ضمن متوسط السعر ± ATR × مضاعف. الاختبار المعياريّ الذي تستخدمه كل أدوات النطاق تقريبًا.
2️⃣ الأفقيّة
الارتباط بين سعر الإغلاق والزمن عبر نافذة النظر للخلف يبقى تحت عتبة محدّدة ، فيستبعد النوافذ التي تتّجه بهدوء بدل أن تكون أفقيّة فعلًا.
3️⃣ بوابة الاتّساع المطلق
البوابة التي تُفوِّتها أغلب الأدوات. بعد حركة حادّة، يتضخّم ATR نفسه ، ممّا قد يجعل البوابة الأولى تمرّ حتى لو كان النطاق واضحًا أنّه ليس نطاقًا — لأنّ نطاق ATR الأوسع أسهل للبقاء داخله . تفحص هذه البوابة الفارق الفعليّ بين أعلى وأدنى نقطة في النافذة كنسبة مئويّة بسيطة من السعر ، بمعزل عن ATR ، فلا يعود قياس ATR المتضخِّم قادرًا على تمويه نافذة واسعة وغير مستقرّة فعليًّا على أنّها نطاق صالح .
4️⃣ بوابة زاوية الدخول
تفحص حركة السعر عبر أوّل شموع النافذة تحديدًا. النافذة التي تبدأ في منتصف انهيار سعريّ ولم ينتهِ بعد ترسب في هذه البوابة حتى لو بدت بقيّة النافذة هادئة.
🔸 اختياريّ: فلتر الاتجاه السابق
عند الحافة الأولى للنافذة يمكنه تقييد الكشف أكثر على النطاقات ADX التي تكوّنت بعد اتجاه حقيقيّ لا من بداية ساكنة — مفيد لاستراتيجيّات اتجاه - ثم - توحيد .
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📦 صندوقان، واختيارك لمصدر الكسر
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
يتتبّع Dynamic Range Pro صندوقين في آنٍ واحد:
1️⃣ الصندوق الرئيسيّ (القائم على ATR)
النطاق المعياريّ: متوسط السعر ± ATR × مضاعف. هذا التعريف الكلاسيكيّ الذي تستخدمه كل أدوات النطاق، ومصدر الكسر الافتراضيّ.
2️⃣ الصندوق الداخليّ (القائم على الإغلاق)
صندوق ثانٍ مستقلّ مبنيّ حصرًا من أعلى وأدنى سعر إغلاق خلال التكوّن — متجاهلًا الفتائل كليًّا. يمنح قراءة أضيق ومقاومة للضوضاء لموضع استقرار السعر الفعليّ.
🔀 وضع الصندوق — اختيار مصدر الكسر
اعرض أيّ صندوق، أو كليهما معًا، أو رقِّ الصندوق الداخليّ ليكون مصدر الكسر الفعليّ بدل الرئيسيّ. الكسر عبر الصندوق الداخليّ يُنتج تعريفًا أبكر وأضيق — مفيد إن أردت التفاعل قبل خروج السعر من نطاق ATR كاملًا ، مقابل إشارات أكثر تكرارًا.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🏆 تقييم متدرّج لجودة الكسر
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
بدل شراء أو بيع مجرّد بلا سياق ، يُقيَّم كل كسر مؤكَّد عبر خمسة عوامل :
1️⃣ قوّة الاتجاه (ADX)
صحّي ضمن مدى محدّد، محموم فوقه.
2️⃣ اقتراب الزخم من التشبّع (RSI)
القرب من التشبّع في اتجاه الكسر يُحسب ضدّ الحركة.
3️⃣ عمق الاختراق
كم ابتعد الإغلاق عن الحدّ، بوحدة ارتفاع الصندوق.
4️⃣ تشتّت ما قبل التكوّن
مدى نشاط النطاق قبل الكسر، مُجمَّد عند التكوين.
5️⃣ محاذاة تدفّق الاتجاه (فارق DI)
هل فارق الحركة الاتجاهيّة يؤكّد اتجاه الكسر أم يعاكسه.
كل عامل يصوّت نحو تقييم قوي / غير حاسم / مصيدة محتملة. ترى التفصيل الكامل على الشارت — حيًّا أثناء التكوّن ، ومُجمَّدًا لحظة تأكّد الكسر — فتحكم بنفسك أيّ العوامل قاد القرار بدل الثقة بتصنيف مغلق.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🏁 قراءة السطر السفليّ
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
الصفّ الأخير في الجدول يُلخِّص كل ما فوقه في سطر واحد بلغة مبسّطة يتحدّث حيًّا . لا يظهر فيه إلّا واحدة من خمس حالات :
1️⃣ لا صندوق حاليًّا
لا يوجد نطاق نشط أو مكسور مؤخّرًا — لا شيء لعرضه بعد.
2️⃣ النطاق نشط — بانتظار الكسر
يوجد نطاق صالح حاليًّا، لكن السعر لم يختبر أيّ حدّ بعد، فلا شيء لتقييمه بعد.
3️⃣ ✅ كسر قوي
محصّلة العوامل الخمسة لجودة الكسر عند أو فوق عتبة "القويّ" — أغلب العوامل تدعم الاستمرار.
4️⃣ ⚖️ إشارة مختلطة (مع عرض المحصّلة)
المحصّلة بين عتبتَي القويّ والمصيدة — العوامل متضاربة، تستحقّ حذرًا إضافيًّا.
5️⃣ ⚠️ مصيدة محتملة
المحصّلة عند أو تحت عتبة "المصيدة" — أغلب العوامل تشير لإنهاك أو خطر انعكاس.
🔸 رمز ◷
حين يظهر ◷ قبل أيّ تقييم، يعني أنّ السعر لا يزال يخترق الحدّ داخل الشمعة ولم تُغلَق بعد — معاينة حيّة غير مؤكَّدة قد تتغيّر. بمجرّد إغلاق الشمعة وتأكّد الكسر، يختفي ◷ ويثبت التقييم.
عتبتا "القويّ" و"المصيدة" كلتاهما قابلتان للتعديل من الإعدادات.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🧬 درجة تكامل النطاق — قبل وقوع الكسر
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
الطبقة التي أراها الأكثر إثارة من الناحية المفاهيميّة: درجة حيّة من 0 إلى 100 تصف مدى "نظافة" النطاق المتكوّن فعليًّا، تُحسب باستمرار قبل وقوع أيّ كسر، من أربع زوايا مستقلّة:
1️⃣ تشوّش المسار
مقدار تعرّج الإغلاق نسبةً لإجمالي امتداد النافذة.
2️⃣ تماسك الشمعة
حجم الشموع الفرديّة نسبةً للنافذة.
3️⃣ اتجاه التشتّت
هل التقلّب يتحسّن أم يتّسع عبر الزمن.
4️⃣ عدد لمسات الحافة
كم مرّة اختبر السعر الحدّ المرتقَب دون كسره.
تجيب عن سؤال مختلف عمّا يجيبه تقييم جودة الكسر — ليس "ما مدى قوّة الكسر" بل "ما مدى مصداقيّة هذا النطاق أصلًا" — وتتحدّث حيًّا مع تطوّر النطاق، قبل أيّ إشارة بوقت طويل.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📊 مبنيّ على بيانات حقيقيّة، لا الحدس فقط
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
كل بوابة وكل درجة في هذا السكربت اختُبرت فعليًّا على بيانات 4H حقيقيّة عبر 19-20 عملة من Binance، وما يقارب 440-620 حدث نطاق/كسر تاريخيّ حسب الاختبار ، أنشر بالضبط ما وجده ذلك الاختبار، بما في ذلك ما لم يؤكّد توقّعي:
✅ فلتر ADX للاتجاه السابق يُحسِّن جودة الكشف بشكل قابل للقياس على العيّنة المختبَرة.
⚠️ ثلاثة من عوامل جودة الكسر الخمسة (مستوى RSI، مقدار ADX، التشتّت) لم تُظهر علاقة مستقلّة قابلة للقياس بما حدث بعد الكسر. تبقى في التقييم كقائمة تحقّق شفّافة قابلة للقراءة على الشارت لا كميزة تنبّؤيّة مُدَّعاة — ترى بالضبط أيّ العوامل رجّح أيّ تقييم وتزنها بنفسك.
📈 درجة تكامل النطاق أظهرت علاقة موجبة صغيرة، غير دالّة إحصائيًّا بعد، مع استمراريّة ما بعد الكسر (r = +0.10، p = 0.20، n = 176) — اتجاه واعد ، لا إشارة مُثبَتة بعد، وهذا بالضبط سبب كونها طبقة عرض فقط بلا تأثير على التنبيهات أو تكوّن الصندوق.
هذا ليس عرضًا من نوع "ثق بنتائج الباك-تست" — بل عكس ذلك تمامًا. كل ما سبق نقطة انطلاق لحكمك أنت، لا بديل عنه.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⚙️ ميزات عمليّة
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🌐 تبديل كامل بين العربيّة والإنجليزيّة لواجهة الجدول وعلامتَي الشراء/البيع (لوحة الإعدادات ورسائل التنبيه ثنائيّة اللغة دومًا)
🔔 تنبيهات شراء/بيع، مع تنبيه اختياريّ للاختراق اللحظيّ — مبكّر، إخباريّ بحت، قبل إغلاق الشمعة
📦 صناديق النطاقات التاريخيّة تُحفَظ بنظافة عبر عدّة تكوينات، بلا تراكب فوضويّ
🎨 كل لون وسماكة ونمط خطّ قابل للتخصيص
🔒 كل الإشارات تُطلَق حصرًا عند إغلاق شمعة مؤكَّد — بلا إعادة رسم، بلا استباق
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🗣️ لغة الواجهة
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
تعرض الإنجليزيّة افتراضيًّا. بدّل "لغة الجدول" للعربيّة من الإعدادات إن فضّلت. دليل الوضع العربيّ:
Prior trend = الاتجاه السابق
Trend strength (ADX) = قوة الاتجاه
Break direction = اتجاه الكسر
Direction match = مطابقة الاتجاه
Breach depth = عمق الاختراق
Range dispersion = تشتت النطاق
Break verdict = تقييم الكسر
Range/entry % = امتداد/دخول %
Range integrity = تكامل النطاق
Range age = عمر النطاق
BUY/SELL = شراء / بيع
═════════════════════════════════════════════════════════════
⚠️ إخلاء المسؤولية
═════════════════════════════════════════════════════════════
هذا المؤشر لأغراض تعليمية وتحليلية فقط. لا يُمثل نصيحة مالية أو استثمارية أو تداولية. استخدمه بالتزامن مع استراتيجيتك الخاصة وإدارة المخاطر. لا يتحمل TradingView ولا المطور مسؤولية أي قرارات مالية أو خسائر. Indicateur

Indicateur

Indicateur

VWAP Deviation Trend [BackQuant]VWAP Deviation Trend
Overview
VWAP Deviation Trend is a volume-weighted trend-following overlay that transforms VWAP and its surrounding price distribution into a directional trailing structure.
Rather than using VWAP only as a fair-value line, the indicator calculates:
A configurable anchored or rolling VWAP.
The volume-weighted standard deviation of price around that VWAP.
Adaptive upper and lower deviation bands.
One-sided trailing boundaries used to confirm bullish and bearish regimes.
The indicator is designed to identify when price has moved far enough away from accepted volume-weighted value to establish a meaningful directional shift.
Unlike a simple VWAP crossover, price can move through VWAP without immediately changing the active trend. A new regime requires price to break the opposite trailing deviation boundary, optionally with confirmation from the direction of VWAP itself.
The updated visual engine also measures trend strength and uses it to control:
Gradient intensity.
Trail glow width.
Post-flip bloom effects.
The visual separation between price and the active trail.
Core concept
VWAP represents the average price paid over a selected period, weighted by trading volume.
The basic formula is:
VWAP = Sum of Price × Volume / Sum of Volume
Prices associated with greater volume contribute more heavily to the final value. This makes VWAP a useful approximation of:
Volume-weighted fair value.
The center of traded activity.
The average position of market participants.
An institutional execution benchmark.
However, VWAP alone does not explain how widely price has been distributed around that value.
VWAP Deviation Trend treats VWAP as the center of a volume-weighted price distribution and measures the dispersion around it. That dispersion is then used to create trailing trend boundaries.
VWAP calculation modes
The indicator supports five VWAP windows:
4 Hours
Daily
Weekly
Rolling Lookback Bars
Rolling Lookback Days
4 Hours
Resets VWAP at fixed four-hour intervals.
This can be useful for:
Cryptocurrency markets.
Intraday futures.
Continuously traded markets.
Shorter fair-value regimes.
Daily
Resets at the beginning of each calendar day.
This is the traditional intraday VWAP structure and is useful for:
Session bias.
Intraday mean reversion.
Day-trading trend confirmation.
Weekly
Accumulates volume and price across the current week.
This creates a slower structural anchor suited to:
Swing trading.
Weekly positioning.
Broader accepted-value analysis.
Rolling Lookback Bars
Calculates VWAP over a fixed number of candles.
The window moves forward continuously and does not reset at a calendar boundary.
This is useful for:
Systematic trend models.
Consistent multi-timeframe analysis.
Markets where daily sessions are less important.
Rolling Lookback Days
Includes bars that fall within a selected number of calendar days.
This keeps the analytical window tied to elapsed time instead of a fixed candle count.
Anchored versus rolling VWAP
Anchored modes begin at a fixed boundary and accumulate until the next reset.
Rolling modes continually remove old observations as new observations arrive.
Anchored VWAP is useful when a particular session or week has structural meaning. Rolling VWAP is useful when the trader wants a stable and continuously adapting lookback.
Volume-weighted deviation
The indicator calculates more than the VWAP mean.
It also measures volume-weighted price variance using:
Weighted Mean Square = Sum of Price² × Volume / Sum of Volume
Weighted Variance = Weighted Mean Square - VWAP²
Weighted Deviation = Square Root of Weighted Variance
This measures how widely prices associated with meaningful trading volume are distributed around VWAP.
A small deviation suggests:
Trading is concentrated near fair value.
The market is relatively balanced.
Price acceptance is narrow.
A large deviation suggests:
Trading is spread across a wider range.
Price discovery is more active.
The market is less tightly centered around VWAP.
Because the calculation is volume weighted, high-volume prices influence the bands more than low-volume excursions.
Fallback when volume is unavailable
If usable volume is not available, the indicator falls back to an unweighted arithmetic mean and variance.
This allows it to function on synthetic or limited-volume symbols, although the result should then be interpreted as a rolling or anchored mean rather than a true VWAP.
Deviation bands
The raw width is calculated as:
Deviation Width = Weighted Deviation × Deviation Multiplier
The upper and lower raw bands are:
Upper Band = VWAP + Band Width
Lower Band = VWAP - Band Width
Higher deviation multipliers create wider bands and fewer trend changes.
Lower multipliers create tighter bands and faster, more frequent flips.
ATR minimum width
During low-dispersion periods, volume-weighted deviation can become extremely narrow.
This can cause small and insignificant movements to trigger repeated reversals.
The optional ATR floor calculates:
ATR Floor = ATR × ATR Minimum Multiplier
The final width becomes:
Band Width = Maximum of Deviation Width and ATR Floor
This preserves volume-weighted deviation as the primary band engine while preventing the channel from collapsing below a practical volatility threshold.
Trailing-band construction
The raw deviation bands move freely with VWAP and dispersion.
The indicator converts them into one-sided trailing levels.
Lower trail
While the selected trigger remains above the lower trail:
The trail can rise.
It cannot move downward.
This creates a ratcheting support structure.
Upper trail
While the trigger remains below the upper trail:
The trail can fall.
It cannot move upward.
This creates a ratcheting resistance structure.
The active trend trail is:
The lower trail during bullish regimes.
The upper trail during bearish regimes.
Why trailing logic matters
A raw VWAP band can move toward price and create unstable signals.
The one-sided trail preserves trend structure and creates hysteresis.
Hysteresis means the threshold required to enter a bullish regime is different from the threshold required to enter a bearish regime.
This allows price to rotate around VWAP without constantly changing the active trend.
Trend initialization
When the first valid VWAP is available:
The trend initializes bullish if the trigger is at or above VWAP.
The trend initializes bearish if the trigger is below VWAP.
After initialization, a full break of the opposite trail is required to change regimes.
Bullish trend flip
A bullish flip requires:
The selected trigger to move above the upper trailing band.
The current trend not already to be bullish.
VWAP slope confirmation to pass if enabled.
Once confirmed:
The trend becomes bullish.
The active trail moves beneath the market.
A bullish signal marker is displayed.
Bearish trend flip
A bearish flip requires:
The selected trigger to move below the lower trailing band.
The current trend not already to be bearish.
VWAP slope confirmation to pass if enabled.
Once confirmed:
The trend becomes bearish.
The active trail moves above the market.
A bearish signal marker is displayed.
Flip trigger
The trend can be triggered using:
Close
The selected VWAP price source
Close is the more conventional option.
Using the price source, such as HLC3, can produce a slightly smoother trigger because it reflects more of the bar than the close alone.
VWAP slope confirmation
Optional slope confirmation requires VWAP itself to move in the direction of the proposed new trend.
For a bullish flip:
Current VWAP must be above VWAP from the selected lookback.
For a bearish flip:
Current VWAP must be below its prior value.
This can help reject:
Temporary band breaks.
Low-volume price spikes.
Liquidity sweeps against flat fair value.
The tradeoff is additional confirmation delay.
Breaking the trail on flips
The active trail changes from one side of the market to the other during a regime transition.
The Break Trail On Flips option inserts a visual gap on the flip bar so the previous and new trails are not connected by a misleading line segment.
This affects presentation only.
Visual trend-strength engine
The updated script includes a visual-strength model that controls the intensity of the gradient and glow.
It combines two measurements:
Distance between price and the active trail.
Slope of VWAP relative to the current band width.
Distance strength
The script measures:
Absolute Distance = |Close - Trend Trail|
This is normalized by the current band width.
A larger distance indicates stronger separation between price and the structural trail.
Slope strength
VWAP movement across the slope lookback is also normalized by the band width.
This measures whether volume-weighted fair value itself is moving meaningfully relative to the size of the current deviation structure.
Combined trend strength
The final visual strength is weighted:
70% price-to-trail distance.
30% VWAP slope strength.
This produces a value between zero and one.
It does not change trend logic or signals. It controls the visual intensity of the indicator.
Layered gradient fill
Instead of using one flat gradient, the updated indicator divides the space between the trail and price into six visual layers.
The levels are placed progressively between:
The active trend trail.
The current closing price.
The gradient is:
Most concentrated near the structural trail.
Progressively softer toward price.
The opacity adapts to trend strength.
When price is strongly separated from the trail and VWAP is moving with the regime:
The gradient becomes more vivid.
When the trend is weak:
The fill becomes softer and more transparent.
This makes the visual ribbon encode more than direction. It also reflects the current strength of the price-to-structure relationship.
Flip bloom
After a confirmed trend flip, the indicator creates a temporary bloom around the new trail.
The bloom is strongest immediately after the transition and fades over the following bars.
Its intensity follows this general sequence:
First bar after flip: strongest bloom.
Second bar: reduced bloom.
Third bar: light residual bloom.
Afterward: bloom disappears.
This visually emphasizes fresh regime changes without permanently increasing chart brightness.
The bloom is cosmetic and does not affect calculation.
Adaptive trail glow
The glow surrounding the trail also changes with trend strength.
The base width is ATR-scaled, then increases slightly as the visual trend-strength score rises.
This creates:
A broader glow during stronger regimes.
A narrower glow when trend structure is weaker.
The glow contains:
An inner, more visible layer.
A wider, softer outer layer.
Visual interpretation
The updated presentation provides several pieces of information simultaneously:
Color shows the active trend direction.
The trail shows the structural regime boundary.
Gradient intensity reflects trend strength.
Glow width reinforces structural conviction.
The bloom highlights fresh regime transitions.
How to use the indicator
Trend regime filter
Use the active color and trail position as directional context:
Favor longs during bullish regimes.
Favor shorts during bearish regimes.
Pullback structure
In a bullish regime:
VWAP represents volume-weighted fair value.
The lower trail represents deeper structural support.
In a bearish regime:
VWAP represents the mean-reversion anchor.
The upper trail represents deeper structural resistance.
Trend-strength context
A vivid gradient and broader glow suggest:
Price is well separated from the trail.
VWAP is moving in the trend direction.
The regime has stronger structural momentum.
A weak or faded gradient suggests:
Price is closer to the trail.
VWAP slope is weaker.
The trend may be consolidating or losing strength.
Fresh transitions
The bloom helps identify newly established regimes.
A fresh flip with:
Strong bloom.
Growing price separation.
VWAP slope alignment.
generally represents stronger early trend structure than a flip that immediately loses visual intensity.
Dynamic risk management
The active trail may be used as:
A trailing stop reference.
A regime invalidation boundary.
A position-management guide.
Because the trail responds to both volume-weighted dispersion and volatility, it adjusts as market conditions change.
How this differs from a standard VWAP
A standard VWAP:
Plots only volume-weighted mean price.
Usually resets once per session.
Does not maintain trend state.
VWAP Deviation Trend:
Supports anchored and rolling windows.
Calculates volume-weighted dispersion.
Creates adaptive raw bands.
Converts them into directional trailing boundaries.
Maintains persistent bullish and bearish regimes.
Adds a strength-reactive visual system.
How this differs from Supertrend
A traditional Supertrend normally uses a central price such as HL2 and ATR-based bands.
VWAP Deviation Trend uses:
Volume-weighted fair value as the center.
Volume-weighted standard deviation as the primary width.
ATR only as an optional minimum floor.
This means the trail responds not only to range volatility, but also to where trading volume has been concentrated.
How this differs from Bollinger Bands
Bollinger Bands normally use:
A moving average.
Unweighted standard deviation.
Symmetrical non-trailing bands.
This indicator uses:
A volume-weighted mean.
Volume-weighted variance.
One-sided trailing bands.
Persistent trend-state logic.
It is therefore a trend-regime model rather than a standard mean-reversion envelope.
Input guide
VWAP Mode
Selects the anchored or rolling calculation window.
Deviation Multiplier
Controls the width of the statistical bands.
Higher values produce wider, slower regimes. Lower values produce tighter and faster regimes.
ATR Minimum Width
Prevents excessive narrowing during compressed conditions.
VWAP Slope Confirmation
Requires volume-weighted fair value to move with the proposed trend.
Flip Trigger
Selects whether close or the chosen price source must cross the trail.
Visual settings
Allow the trader to display:
The trend trail.
VWAP.
Raw deviation bands.
Layered gradient.
Adaptive glow.
Signals.
Trend candles.
Strengths
Combines fair value, dispersion, and trend structure.
Uses volume-weighted mean and variance.
Supports multiple anchored and rolling VWAP windows.
Uses ATR protection against narrow-band whipsaws.
Creates persistent regimes with hysteresis.
Provides optional VWAP slope confirmation.
Includes a trend-strength-reactive visual system.
Clearly emphasizes fresh trend transitions.
Limitations
Volume quality varies between instruments.
Anchored VWAP modes may be unstable immediately after a reset.
Long windows can react slowly to sudden regime changes.
Tight settings can increase whipsaws.
Wide settings can delay reversals.
Slope confirmation can add additional lag.
Visual strength is contextual and is not a separate trading signal.
Alerts
The indicator includes alerts for:
Confirmed bullish trend flips.
Confirmed bearish trend flips.
These represent complete VWAP deviation regime changes, not ordinary crosses of VWAP.
Summary
VWAP Deviation Trend converts volume-weighted fair value and price dispersion into a directional trend trail.
It calculates VWAP over a configurable anchored or rolling window, measures volume-weighted standard deviation around that VWAP, and builds upper and lower deviation bands. An optional ATR floor prevents the structure from becoming excessively narrow during quiet conditions.
The raw bands are transformed into one-sided trails. The lower trail ratchets upward during bullish regimes, while the upper trail ratchets downward during bearish regimes. Trend changes occur only when price breaks the opposite trail, optionally with confirmation from the slope of VWAP.
The updated visual engine measures price separation and VWAP slope to dynamically control the layered gradient, trail glow, and temporary post-flip bloom. This creates a clearer representation of direction, structural strength, and fresh regime transitions without changing the underlying signal logic. Indicateur

Trinity Flexible Multi-TF MA Alignment Dashboard**User Guide: Flexible Multi-TF MA Alignment Dashboard**
### How to Add the Indicator
1. Open TradingView chart (any symbol/timeframe)
2. Click **Indicators** → Search for "**Flexible Multi-TF MA Alignment Dashboard**" (or "Flex MA Dashboard")
3. Add it to your chart
### Core Functionality
This dashboard lets you monitor **up to 5 independent Moving Averages** at the same time, each with:
- Its own **Timeframe** (5min, 15min, 1H, 4H, Daily, etc.)
- Its own **Length** (e.g., 9, 20, 34, 50, 200)
- Its own **Type** (EMA or SMA)
The indicator shows:
- Whether price is **Above** (Bullish) or **Below** (Bearish) each MA
- **Overall alignment signal** (Strong Buy / Strong Sell / No Clear Alignment)
- The actual MA lines plotted on your chart (optional)
- Candle coloring based on overall alignment (optional)
### Settings Breakdown
#### MA 1 to MA 5 (Each has its own group)
- **Enable MA X**: Turn individual rows on/off
- **MA X Timeframe**: Choose from:
- `Chart` → Uses whatever timeframe your chart is on
- `5`, `15`, `30`, `60` (1H), `240` (4H), `D` (Daily), `W`, `M`
- **MA X Type**: EMA or SMA
- **MA X Length**: Any number (default 20)
**Tip**: Common setup for scalping:
- MA1: 5min + 9 EMA
- MA2: 15min + 20 EMA
- MA3: 1H + 20 EMA
- MA4: 4H + 50 EMA
- MA5: Daily + 200 EMA
### How to Read the Indicator
**Table Rows (MA1 to MA5)**:
- Shows the exact configuration (e.g., "MA3 (60 EMA20)")
- **Green** = Price is above that MA → Bullish bias on that timeframe
- **Red** = Price is below that MA → Bearish bias
- **Gray** = Row disabled
**Overall Signal (Bottom Row)**:
- **STRONG BUY** (Green) → All active MAs are aligned bullish
- **STRONG SELL** (Red) → All active MAs are aligned bearish
- **No Clear Alignment** (Yellow) → Mixed signals → Stay out or be cautious
**Visuals on Chart**:
- Colored MA lines (match the row colors)
- Candles colored green/red based on overall alignment (toggleable)
### Trading Usage Examples
**Scalping / Short-term Bias**:
- Use tighter MAs on lower timeframes (9 or 20 EMA)
- Look for **STRONG BUY/SELL** on 5min chart when higher timeframes (1H + 4H) are also aligned
**Trend-Following Day Trading**:
- Set MA1 = 15min 20 EMA
- MA2 = 1H 20 EMA
- MA3 = 4H 50 EMA
- MA4 = Daily 200 EMA
- Only take longs when you get **STRONG BUY**
**Your Original Request Style**:
- Set 5 rows to 20 EMA (or 9 EMA)
- Different timeframes: 5min, 15min, 1H, 4H, Daily
- Enter **puts** only when you get **STRONG SELL** (all MAs aligned bearish)
### Pro Tips
- Start with 3–4 MAs active to avoid over-filtering
- Use "Chart" timeframe on one row so you always see the current chart’s MA
- Turn off **Show MA Lines** if the chart gets too cluttered
- Turn off **Color Candles** if you prefer clean price action
- The more timeframes that align, the higher the probability (especially when Daily + 4H agree)
Indicateur

Change of Character (CHoCH) Alert System [algo_aakash]Change of Character (CHoCH) Alert System is a market structure signal tool focused on a single event: a confirmed shift in directional bias. Rather than labeling every Break of Structure and CHoCH the way many public structure scripts do, this indicator deliberately ignores continuation breaks and limits both the chart and the alert feed to the moments where the prevailing character of the market actually flips.
Problem Statement
Most public CHoCH implementations classify a character change purely on the direction of a swing break, with no measure of how convincing that break actually was. This creates two practical issues for anyone building alerts around structure. Every minor swing wobble can trigger a notification, producing alert fatigue, and there is no way to separate a decisive character change from one that barely closed beyond the swing level. This script addresses both issues with a close-confirmed CHoCH-only detection engine and a built-in confidence grading step applied to every signal.
Methodology
The script maintains a single structure register holding the most recent confirmed swing high and swing low, located with standard pivot detection over a user-defined pivot length. When the adaptive swing filter is enabled, a newly confirmed pivot only replaces the stored swing if its distance from the last opposite-type pivot exceeds a configurable ATR-relative threshold, which keeps insignificant micro-swings out of the structure register before they can influence a signal.
A Change of Character is only evaluated on a confirmed candle close, so nothing in the detection logic repaints once a signal has printed. A bullish CHoCH requires a close above the last swing high while the tracked bias is bearish or undefined. A bearish CHoCH requires a close below the last swing low while the tracked bias is bullish or undefined. A break that occurs while the bias already agrees with the break direction is treated as ordinary continuation and is not flagged.
Two optional filters gate confirmation further. A displacement filter requires the breaking close to clear the swing level by a minimum ATR multiple, removing marginal breaks. A momentum filter requires the breakout candle's body to represent a minimum percentage of its total range, removing breaks driven mostly by wick with little real conviction behind the close.
Once a CHoCH is confirmed, the broken swing level is projected forward on the chart as an active structure line. If a later confirmed close moves back through that level, the structure is marked invalidated and the projection line is dimmed, separately from the detection of any new CHoCH.
Signal Workflow
Track the most recent confirmed swing high and swing low using pivot detection.
Apply the adaptive swing filter to reject pivots too close to the last opposite-type pivot.
On each confirmed candle close, test for a close beyond the stored swing level against the current bias.
Apply the displacement filter to confirm the close cleared the level by a minimum ATR multiple.
Apply the momentum filter to confirm the breakout candle's body-to-range ratio meets the minimum threshold.
Score the confirmed breakout candle on displacement in ATR units and body-to-range ratio to produce a Weak, Moderate, or Strong confidence grade.
Flip the tracked bias, plot the CHoCH label with its grade, and project the broken level forward as an active structure line.
Continue monitoring the active structure line and mark it invalidated if a later confirmed close moves back through it.
Why This Indicator Is Different
Many structure tools plot every Break of Structure alongside every CHoCH, leaving the trader to filter out which events represent an actual change in character.
This script omits BOS events entirely and reports only confirmed CHoCH signals, which are the events that correspond to a bias flip.
Each confirmed CHoCH is scored using two independent factors measured on the breakout candle itself, its ATR-normalized displacement past the level and its body-to-range ratio, rather than being treated as a single undifferentiated event.
The confidence grade is written into the alert message text at the moment the event fires, which requires composing the message dynamically rather than relying on a fixed template.
The swing level broken by a CHoCH remains tracked after the signal fires, so a later close back through that level produces a distinct invalidation alert rather than silently vanishing into the next structure calculation.
Detection is restricted to confirmed candle closes throughout, so the bias, the grade, and the invalidation state cannot change intrabar once printed.
Inputs
Structure Engine
Swing Pivot Length
Adaptive Swing Filter
Filter Threshold (ATR multiple)
Break Confirmation
Displacement Filter
Displacement Multiplier
Momentum Filter
Minimum Body % of Range
ATR Length
Visual Settings
Show Swing Points
Show Structure Projection
Projection Extension
Show Trend Background Wash
Color Candles After CHoCH
Show Confidence Grade
Label Size
Bullish, Bearish, and Projection colors
Status Panel
Show Status Panel
Panel Position
Alerts
Alert: Bullish CHoCH
Alert: Bearish CHoCH
Alert: Bullish Structure Invalidated
Alert: Bearish Structure Invalidated
Alerts
Alerts are available for:
Bullish CHoCH confirmed on a closed candle, with the confidence grade included in the alert message
Bearish CHoCH confirmed on a closed candle, with the confidence grade included in the alert message
Bullish structure invalidated after a confirmed close back below an active bullish level
Bearish structure invalidated after a confirmed close back above an active bearish level
Practical Usage
Use a shorter pivot length on intraday charts to react to structure earlier, combined with the displacement and momentum filters to avoid marginal breaks.
Use a longer pivot length on higher timeframes to isolate structurally significant character changes only.
Treat a Strong-grade CHoCH as a higher-conviction event than a Weak-grade CHoCH when weighing entry timing or position sizing.
Watch for a structure invalidated alert shortly after a CHoCH, since it indicates price has returned through the level that produced the signal.
Use the status panel as a quick reference for the current bias and the most recent CHoCH grade without needing to scan the chart for labels.
Limitations
Swing highs and lows depend on confirmed pivots, which require the full pivot length of bars to close on both sides before becoming available, introducing a disclosed confirmation lag.
The displacement and momentum filters reduce signal frequency by design, which means fewer but more selective CHoCH events compared to unfiltered structure break detection.
Structure invalidation reflects a return through a previously broken level and does not attempt to forecast subsequent price direction.
This indicator identifies structural events only and does not constitute financial advice or a complete trading system on its own.
Notes
All structural state, including the tracked bias, the active levels, and the confidence grade, is evaluated only on a confirmed candle close, so nothing in this script repaints once printed.
The only lag in the system is the standard pivot confirmation lag inherent to pivot-based swing detection, which is disclosed above rather than hidden.
Designed for dark theme charts. On light themes, consider darkening the projection line color for improved contrast.
Indicateur

Liquidity Zones Liquidity Zones automatically identifies and displays potentially significant support and resistance zones formed around confirmed local price highs and lows.
The indicator helps traders analyze:
• market structure;
• areas where price may react;
• repeated returns into a zone;
• trading volume associated with candles overlapping the zone;
• zone invalidation or loss of relevance;
• the position of the current price relative to nearby structural areas.
Within this indicator, the term “liquidity zone” refers to a structural price area formed around a confirmed pivot.
The indicator does not use order book data, does not detect the actual number of resting limit orders, and does not display real order book liquidity.
Liquidity Zones does not generate Buy or Sell signals and is not a complete trading system.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🧠 INDICATOR CONCEPT
A traditional horizontal level represents a single price. In practice, however, market reactions rarely occur at one exact price.
For this reason, the indicator works with price ranges rather than isolated horizontal levels. Each range is derived from the candle that formed a confirmed local pivot.
Every zone follows its own lifecycle:
It originates from a local high or low.
It is confirmed after the required number of candles has closed.
Its price range is calculated.
Information about retests and overlapping volume is accumulated.
It remains active until it is broken or replaced by a newer zone.
It remains visible as part of the historical market structure.
The user therefore sees not only the location of a zone, but also its current state.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📍 HOW LOCAL PIVOTS ARE IDENTIFIED
The calculations are based on confirmed Pivot Highs and Pivot Lows.
The Pivot Lookback setting defines the number of candles used on each side of a potential pivot.
A Pivot High is confirmed when the high of the candidate candle remains a local high relative to the selected number of candles on both its left and right sides.
A Pivot Low is confirmed when the low of the candidate candle remains a local low relative to the selected number of candles on both its left and right sides.
For example, with Pivot Lookback set to 15, the indicator uses:
• 15 candles to the left of the potential pivot;
• the pivot candle itself;
• 15 candles to the right of the potential pivot.
The zone becomes known only after all candles required to confirm the pivot have closed.
A higher Pivot Lookback generally identifies larger and less frequent structural pivots.
A lower value makes the algorithm more sensitive and produces more local zones.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🧱 HOW THE ZONE RANGE IS CALCULATED
The Swing Area setting provides two methods for defining the zone.
🔹 Wick Extremity
This mode uses the part of the pivot candle located between its body and the outer end of its wick.
For a resistance zone, the range is formed between:
• the upper edge of the pivot candle body;
• the high of the pivot candle.
For a support zone, the range is formed between:
• the low of the pivot candle;
• the lower edge of the pivot candle body.
This mode creates narrower zones around the wicks of pivot candles.
🔹 Full Range
This mode uses the complete range of the pivot candle:
• from its low;
• to its high.
It creates a wider zone that includes both the candle body and its wicks.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🔴 RESISTANCE ZONES
A resistance zone is formed from a confirmed Pivot High.
Its outer boundary is the high of the pivot candle.
Resistance zones are displayed in red by default.
The user can:
• enable or disable resistance zones;
• change the level line color;
• change the zone fill color.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🟢 SUPPORT ZONES
A support zone is formed from a confirmed Pivot Low.
Its outer boundary is the low of the pivot candle.
Support zones are displayed in green by default.
The user can:
• enable or disable support zones;
• change the level line color;
• change the zone fill color.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
♻️ ZONE LIFECYCLE
The indicator separately tracks:
• one current resistance zone;
• one current support zone.
When a new Pivot High is confirmed, the previous active resistance zone is retired.
When a new Pivot Low is confirmed, the previous active support zone is also retired.
This preserves historical market structure while keeping the latest confirmed zone of each type visually relevant.
Active zones extend to the right of the latest chart candle.
Broken or retired zones stop extending and are displayed with reduced visual intensity.
The algorithm distinguishes between two separate states.
💥 Broken
Price has violated the outer boundary of the zone according to the selected break confirmation method.
🕰 Retired
The zone has not necessarily been broken, but it is no longer the current zone because a newer confirmed zone of the same type has appeared.
Separating these states allows the user to distinguish an actual boundary break from a normal update in market structure.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
✅ BREAK CONFIRMATION
The Break Confirmation setting determines when a zone is considered broken.
🔹 Close
A resistance zone is considered broken when a completed candle closes above the upper zone boundary.
A support zone is considered broken when a completed candle closes below the lower zone boundary.
In this mode, a wick crossing the boundary is not sufficient.
🔹 Wick
A resistance zone is considered broken when the high of a completed candle moves above the upper boundary.
A support zone is considered broken when the low of a completed candle moves below the lower boundary.
This mode is more sensitive because even a temporary wick movement beyond the boundary can invalidate the zone.
Zone state changes are processed only after the relevant candle has completed.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🔁 HOW RETESTS ARE COUNTED
When Filter By = Retests is selected, zones are evaluated by the number of separate price returns.
A retest is recorded only after the following sequence occurs:
Price leaves the zone.
Price remains outside the zone.
Price later returns into the zone.
After this return, the retest counter increases by one.
Several consecutive candles remaining inside the same zone are not counted as several separate retests.
The original pivot candle that formed the zone is also not counted as a retest.
When price has not yet left and returned to the zone, the zone is marked as:
Fresh
The Minimum setting defines the minimum number of retests required before a zone is displayed.
For example:
• Minimum = 0 displays both fresh and retested zones;
• Minimum = 1 hides zones without a confirmed return;
• Minimum = 2 displays only zones with at least two separate retests.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
📊 OVERLAP VOLUME FILTERING
When Filter By = Overlap Volume is selected, the indicator measures the cumulative volume of candles whose price ranges overlap the zone.
A candle is considered to overlap a zone when:
• its high is not below the lower zone boundary;
• its low is not above the upper zone boundary.
The full volume of every overlapping candle is added to the calculation.
The volume of the original pivot candle is also included in Overlap Volume.
It is important to understand that Overlap Volume is not a volume profile and does not show the exact distribution of transactions within the price zone.
The algorithm does not determine which portion of a candle’s volume was traded specifically inside the zone. It adds the full volume of every candle whose range partially or fully overlaps the zone.
In this mode, the Minimum setting defines the minimum accumulated Overlap Volume required for a zone to be displayed.
On instruments without available or representative volume data, this filtering method may provide limited information.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⏳ STATE RECONSTRUCTION AFTER PIVOT CONFIRMATION
A pivot becomes known only after the required number of candles to its right has closed.
During the period between the original pivot candle and its confirmation, price may already have:
• left the future zone;
• returned into it;
• crossed its range several times;
• accumulated trading volume;
• broken its outer boundary.
To avoid ignoring these events, the indicator reconstructs the zone lifecycle after the pivot is confirmed.
It processes the candles between the original pivot candle and the confirmation candle in chronological order.
During this reconstruction, the algorithm evaluates:
• price exits from the zone;
• separate returns into the zone;
• accumulated Overlap Volume;
• possible zone breaks;
• the resulting zone state.
As a result, the newly confirmed zone immediately reflects the price behavior that has already occurred instead of starting its calculations only from the confirmation candle.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
💎 ORIGINALITY AND PRACTICAL VALUE
Liquidity Zones is not a mechanical combination of unrelated indicators.
All components of the script operate as parts of one unified model describing the lifecycle of a structural price zone.
The algorithm combines:
• confirmed local pivot detection;
• zone construction from the pivot candle;
• a choice between wick-based and full-range zones;
• reconstruction of events that occurred before pivot confirmation;
• counting separate price returns instead of every overlapping candle;
• accumulation of volume from candles overlapping the zone;
• two independent break confirmation methods;
• separation of broken and retired zones;
• preservation of historical market structure;
• visual emphasis on the latest active zone of each type;
• direct display of zone information on the chart.
The practical value of this approach is that the user receives more than a static support or resistance line.
The indicator provides information about:
• the full zone range;
• the zone type;
• its current state;
• the number of separate retests;
• accumulated Overlap Volume;
• distance from the current price;
• zone age;
• the selected break confirmation method;
• the pivot confirmation period.
This allows the zone to be evaluated as an evolving structural object rather than as a fixed horizontal level.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🏷 ACTIVE ZONE LABELS
The Show Active Zone Labels setting enables or disables labels for current active zones.
The following abbreviations are used:
• R — Resistance zone;
• S — Support zone;
• Fresh — a zone without a separate confirmed return;
• retest or retests — the number of recorded price returns.
🔹 Compact
Displays:
• the zone type;
• the value of its outer boundary;
• the number of retests.
🔹 Detailed
Additionally displays accumulated Overlap Volume.
When the user hovers over a label, the tooltip provides:
• zone type and status;
• full price range;
• outer boundary value;
• zone width as a percentage;
• number of retests;
• accumulated Overlap Volume;
• zone age in bars;
• distance from the current price to the nearest zone edge;
• selected break confirmation method;
• Pivot Lookback value;
• explanations of the Retests and Overlap Volume calculations.
Labels are displayed only for active zones that pass the selected filter.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⚙️ INDICATOR SETTINGS
🔸 Pivot Lookback
The number of candles used on each side of a potential local pivot.
Higher values identify larger and less frequent structural pivots.
Lower values increase the sensitivity of the algorithm.
🔸 Swing Area
Defines the width of the zone:
• Wick Extremity — the wick area of the pivot candle;
• Full Range — the complete range of the pivot candle.
🔸 Filter By
Selects the filtering method:
• Retests;
• Overlap Volume.
🔸 Minimum
The minimum value of the selected filtering metric required before the zone is displayed.
🔸 Break Confirmation
Selects the zone break method:
• Close;
• Wick.
🔸 Show Active Zone Labels
Enables or disables labels for active zones.
🔸 Label Detail
Selects the compact or detailed label format.
🔸 Resistance
Enables, disables, and customizes resistance zone colors.
🔸 Support
Enables, disables, and customizes support zone colors.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🧩 EXAMPLE SETUP AND USAGE
1️⃣ Select a chart timeframe that corresponds to your analysis horizon.
2️⃣ Configure Pivot Lookback.
A higher value helps identify larger structural pivots.
A lower value provides a more sensitive view of local price movements.
3️⃣ Select Swing Area.
Wick Extremity creates narrower zones around candle wicks.
Full Range uses the complete pivot candle range.
4️⃣ Select the filtering method.
Retests evaluates the number of separate price returns.
Overlap Volume evaluates the accumulated volume of candles that crossed or touched the zone.
5️⃣ Set the Minimum value.
This setting hides zones that have not yet reached the required filter threshold.
6️⃣ Select Break Confirmation.
Close requires a completed candle to close beyond the zone boundary.
Wick detects a boundary violation based on the wick of a completed candle.
7️⃣ Use the zones as analytical context together with:
• market structure;
• trend direction;
• volatility;
• trading volume;
• price action;
• personal risk management rules.
A touch of a zone does not mean that price will necessarily reverse.
A zone break also does not guarantee that price will continue moving in the same direction.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
⚠️ INDICATOR LIMITATIONS
• A zone is confirmed with a delay equal to the Pivot Lookback value.
• On historical charts, the zone begins at the original pivot candle, although in real time it becomes known only after the required candles to the right have closed.
• If a zone passes the selected filter at a later point, its visual display still begins from the original pivot candle.
• The displayed areas are a mathematical interpretation of price structure and not information about actual resting limit orders.
• Overlap Volume uses the full volume of an overlapping candle and does not determine the portion traded specifically inside the zone.
• The quality and meaning of volume data depend on the market, instrument, and data source.
• Only the latest confirmed support zone and the latest confirmed resistance zone remain active at the same time.
• Settings require adjustment for the selected instrument, timeframe, and current volatility.
• The indicator does not calculate the probability of a price reaction.
• The indicator does not predict the direction of future price movement.
• The indicator does not contain entry or exit rules.
• The indicator does not determine Stop Loss, Take Profit, or position size.
• The indicator is not a strategy and does not perform historical testing of a trading system.
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
🛡 RISK DISCLAIMER
Liquidity Zones is an analytical tool designed to assist with the study of price structure.
It should not be used as the sole basis for making a trading decision.
All trading decisions, parameter selection, zone interpretation, and risk management remain the responsibility of the user.
Past price behavior around the displayed zones does not guarantee a similar reaction in the future. Indicateur

Institutional Gradient ChannelInstitutional Gradient Channel
tradingview.com
Institutional Gradient Channel is a comprehensive institutional market analysis indicator designed to help traders understand trend direction, market structure, institutional participation, price location, momentum quality, and potential continuation or reversal opportunities from a single integrated trading framework. Rather than relying on a single technical indicator, it combines multiple analytical models into one unified environment so traders can evaluate the overall condition of the market before making trading decisions.
The primary objective of this indicator is to simplify institutional-style chart analysis. Professional traders rarely make decisions based on one signal alone. They study trend direction, price position, market structure, liquidity, momentum, volatility, volume behavior, and reaction zones simultaneously. Institutional Gradient Channel brings these concepts together into a single visual framework that remains clean, organized, and easy to interpret during live market conditions.
The indicator continuously evaluates price action using an adaptive gradient channel that automatically adjusts to changing market conditions. As volatility expands or contracts, the channel responds dynamically to maintain a realistic representation of the current trading environment. This allows traders to immediately recognize whether price is trending strongly, moving within equilibrium, approaching potential resistance, or trading near areas where institutional reactions may become more likely.
One of the core features of the indicator is its institutional gradient channel. Instead of displaying a simple static trend line, the channel provides a dynamic visual representation of market direction while highlighting the relative position of price within the current trend. As price approaches the upper portion of the channel, traders can evaluate whether buying pressure remains healthy or whether momentum may be weakening. Likewise, movement toward the lower portion of the channel may indicate increasing selling pressure or developing opportunities for bullish recovery depending on surrounding market conditions.
The indicator also performs continuous market structure analysis. Every new swing is evaluated to determine whether the market is producing Higher Highs, Higher Lows, Lower Highs, or Lower Lows. Breaks in market structure are identified to help traders recognize transitions between bullish and bearish environments. This enables traders to understand whether the prevailing trend remains intact or whether institutional order flow may be beginning to shift in the opposite direction.
Trend quality is measured through multiple internal calculations rather than a single moving average. Momentum, directional persistence, volatility, and structural behavior are combined to estimate the overall strength of the current trend. Instead of simply showing whether price is rising or falling, the indicator attempts to determine how healthy and sustainable the trend currently appears.
Another important component is the institutional order flow analysis. While true exchange order flow data is not available for many markets, the indicator estimates buying and selling participation by analyzing price movement, candle behavior, volatility, and relative volume. These measurements provide traders with an approximation of whether buyers or sellers currently maintain stronger control over market direction.
The volume profile section enhances the analysis by identifying areas where market activity has concentrated over the selected analysis period. The developing Point of Control, Value Area, and high-volume regions help traders understand where institutional participation has historically been strongest. These areas frequently act as important reaction zones where price may pause, consolidate, reverse, or continue depending on broader market conditions.
Institutional Gradient Channel also continuously evaluates price location relative to the overall trading environment. It determines whether price is positioned inside premium territory, discount territory, or near equilibrium. This information helps traders avoid chasing extended moves and instead focus on locations where risk and reward may become more favorable.
Support and resistance levels are generated dynamically rather than remaining fixed. As market conditions evolve, the indicator updates important boundaries using current price behavior, trend development, structural analysis, and institutional positioning. These adaptive levels help traders monitor potential reaction zones without requiring constant manual chart adjustments.
The scenario projection engine provides an estimated continuation pathway based on the current market environment. Rather than attempting to predict the future with certainty, it illustrates a logical sequence of possible market development including trigger zones, retest opportunities, continuation areas, projected targets, and potential extension levels. This allows traders to prepare for multiple outcomes while maintaining flexibility as new price information becomes available.
The integrated dashboard serves as a centralized decision-making panel by summarizing the most important market information in real time. It continuously updates values such as market bias, trend strength, channel position, institutional participation, price location, momentum quality, compression level, volume profile statistics, structural status, and scenario direction. Instead of scanning multiple indicators across the chart, traders can quickly assess overall market conditions from a single organized interface.
This indicator is designed to support discretionary trading rather than replace proper market analysis. It performs best when its institutional framework is combined with disciplined risk management, higher timeframe confirmation, and sound trading principles. The generated information should be interpreted as analytical guidance intended to assist decision-making rather than as guaranteed buy or sell instructions.
Institutional Gradient Channel was developed to provide traders with a professional-grade institutional analysis framework that remains visually organized while delivering meaningful insight into changing market conditions. The objective is to reduce chart clutter, improve market awareness, and help traders evaluate trend quality, institutional positioning, and structural behavior through one integrated analytical environment suitable for Forex, Gold, Indices, Stocks, Futures, and Cryptocurrency markets across multiple timeframes.
Verification and Clarification
Author: Forex_Market_Insights
This indicator has been independently designed, engineered, and implemented by Forex_Market_Insights. Every analytical component, calculation method, visualization system, dashboard element, market structure model, trend evaluation process, channel construction technique, volume interpretation method, projection framework, and internal programming architecture has been developed specifically for this project using original implementation methods.
Although the indicator utilizes analytical concepts that are widely recognized throughout technical analysis, including trend channels, regression analysis, market structure, support and resistance, volume profile concepts, momentum evaluation, volatility measurements, and institutional trading principles, the software implementation itself has been independently engineered from the ground up.
This script is not intended to reproduce, imitate, reverse engineer, translate, decompile, modify, or derive from the protected implementation of any commercial, invite-only, private, open-source, or publicly available TradingView indicator. Similarity in trading concepts reflects the common nature of financial market analysis and should not be interpreted as similarity in programming implementation or software architecture.
Forex_Market_Insights declares that this indicator represents an original software development project created through independent research, engineering, and Pine Script programming practices. Every calculation, visual component, dashboard system, analytical module, and processing routine has been designed to operate as part of a self-contained institutional trading framework developed specifically for this indicator.
The purpose of publishing this script is to provide traders with a professional institutional market analysis tool that emphasizes clarity, transparency, maintainability, performance, and independent software engineering while delivering meaningful market insight through an original Pine Script implementation.
tradingview.com Indicateur

ICT Sessions & Killzones [JOAT]ICT Sessions and Killzones
Maps the trading day into sessions and killzones, then shows where each session's liquidity rests and when the next session raids it.
What it is
Intraday price is organised by time: different sessions have different behaviour, and each one leaves liquidity that the next session hunts. This indicator frames when the market is active and where that liquidity sits, so the raids become obvious in advance. It is an original session-mapping tool built around the widely-taught concept of session killzones and inter-session liquidity.
How it works
• Session boxes — Asia, London, New York AM and New York PM are each boxed from their own high to their own low across their clock window. The box is that session's realised range, and its edges are the liquidity the following sessions tend to seek.
• Liquidity lines — every completed session leaves its high and low as thin levels extended to the right. Resting buy-side liquidity sits at the highs, sell-side at the lows, each labelled.
• Sweeps — when a later session trades through a prior session's high or low, that raid is tagged, marking where stops were likely taken.
• Classic reference levels — the previous day's high and low and the midnight open are drawn as the anchor points this style of analysis leans on.
• Bias read — a simple, transparent read from the midnight open and the most recent killzone sweep-and-reclaim prints an understated directional tag. This tool is about mapping context and timing; it deliberately shows direction rather than full trade management.
The dashboard
An adjustable session-clock panel shows which session is currently active, the countdown context of the day, the most recent liquidity event, the current bias, and the reference levels in play, so the state of the day is readable at a glance.
How to use it
• Set the session windows and timezone to your market.
• Watch for a session to sweep the prior session's high or low and then reclaim — that is the timing this map is built to highlight.
• Use it as a context and timing layer beneath your own entry method, or alongside a structure or entry tool.
Settings
Session windows and timezone, which sessions and reference levels to display, sweep marking, bias options, plus full visual and dashboard controls.
Originality and usefulness
The contribution is a single, coherent map of session ranges, inter-session liquidity, sweeps and classic reference levels, with a transparent bias read — assembled so a trader can see the day's liquidity structure and timing without cluttering the chart. Everything evaluates on confirmed bars and does not repaint.
Notes and limitations
• Session times depend on the timezone and the instrument's trading hours; set them correctly for your market.
• The bias read is intentionally simple context, not a standalone trade signal.
• This tool maps liquidity and timing; it does not place stops or targets for you.
• Educational and analytical tool, not financial advice.
— made with passion by officialjackofalltrades
Indicateur

Wyckoff Architectural Range - erdensedatThe "Wyckoff Architectural Probability Range" is an advanced, non-overlapping consolidation detector and liquidity sweep identification system. Designed to keep charts clean, it dynamically adapts to market volatility and focuses solely on the current active trading range.
Key Features:
- Dynamic ATR-Based Range Width: The indicator automatically adjusts its maximum allowed range width based on the asset's current volatility, ensuring it works seamlessly across both major assets (BTC, ETH) and highly volatile altcoins.
- Non-Overlapping Architecture: Historical ranges are completely removed upon a confirmed breakout, leaving only the active, actionable consolidation zone on your chart.
- Premium & Discount Zones: The range is mathematically divided into Premium (Top 25%), Equilibrium (Middle 50%), and Discount (Bottom 25%) zones. Internal EQ levels (0.4 and 0.6) are also projected.
- Advanced Retest Signals:
> Buy Signal: Prints when price crosses below the Discount EQ and subsequently retests and closes above it.
> Sell Signal: Prints when price crosses above the Premium EQ and subsequently retests and closes below it.
- Smart Liquidity Detection (Spring & UTAD): Automatically identifies and labels wick-based liquidity sweeps outside the range.
- Mean Reversion Probability: A dynamic stats panel calculates the mean reversion probability based on the current deviation from the main Equilibrium level.
- Built-in Alert System: Provides any() alert conditions for Buy/Sell signals, Spring/UTAD sweeps, and Range Breakouts.
- Optional VWAP: Toggle a standard VWAP line on or off directly from the settings for additional confluence.
How to Use:
Use the statistical panel and structural boxes to identify institutional accumulation (Discount Zone) and distribution (Premium Zone). Wait for confirmed retest signals (Triangles) or liquidity sweeps (Spring/UTAD) for high-probability mean-reversion entries.
Disclaimer:
The information and scripts provided in this indicator are for educational and informational purposes only and do not constitute financial advice. Trading cryptocurrencies, forex, and other financial markets involves a high degree of risk and may not be suitable for all investors. Past performance is not indicative of future results. Always conduct your own research and consult with a certified financial advisor before making any trading decisions.
Indicateur

FVG Sniper [JOAT]═══ FVG SNIPER ═══
A complete Fair Value Gap engine that finds price imbalances, grades their quality, tracks how they fill, mitigate and invert, and then paints a full trade blueprint the moment a clean setup fires. One gap is spotlighted as the strongest, and every signal arrives with entry, three targets, a stop, and colored risk/reward zones — no arrows, no clutter.
▎ WHAT IT DOES
FVG Sniper detects three-candle fair value gaps (imbalances), scores each one from 0–10, and monitors its life cycle: how much of the gap has been filled, whether it has been mitigated (wick-tapped through), and whether price has closed fully through it to flip its role into an Inverted FVG (IFVG) . When a graded gap produces a rejection or an IFVG flip that agrees with the higher-timeframe bias, it draws a structured trade plan and reports the whole picture in a dashboard.
▎ HOW IT WORKS
• Gap detection — a bullish gap forms when the current low sits above the high from two bars back; a bearish gap forms when the current high sits below the low from two bars back.
• Quality filters — each candidate must clear a minimum gap size (as a multiple of ATR ) and a minimum displacement body ratio on the impulse candle, so tiny or weak imbalances are ignored.
• Grade (0–10) — blends gap size, the displacement range of the middle candle, and relative volume into a single score. Only gaps at or above your minimum grade may fire a signal.
• Fill & mitigation — the engine tracks the running extreme inside each gap to compute a live fill percentage, and marks a gap mitigated once a wick fully traverses it.
• Inversion (IFVG) — when price closes fully through a gap, its role flips; the box restyles to a dashed amber accent and the flip is logged.
• Signals — two sources you can mix or isolate: Rejection (price retraces into a live gap and reacts back out with a directional close) and IFVG Flip (a mitigated gap is closed through, confirming continuation).
• HTF bias filter — an optional higher-timeframe EMA bias must agree with the signal direction before it is allowed.
• Trade model — on a fresh signal it sets entry at close, a stop either gap-protected (just beyond the triggering gap boundary) or ATR-based, with risk clamped between a floor and a cap. Targets TP1/TP2/TP3 are placed at your chosen R multiples.
• Non-repainting — all detection, scoring and signals evaluate on confirmed (closed) bars only, and the HTF request uses no lookahead.
▎ HOW TO USE IT
• Trade in the direction of the BUY / SELL pill. The stars and score on the pill show the grade of the gap that triggered it.
• The entry line (chrome), dashed stop , and TP1/TP2/TP3 lines map the plan directly on the chart; level labels on the right print exact prices and R values.
• The green zone is the target/reward area from entry to TP3; the red zone is the risk area between entry and stop — a fast visual read of the trade's R:R.
• A single ★ spotlight tags only the strongest active gap, so you always know the best imbalance in view.
• Use live gaps as decision zones: watch the fill % of the nearest gap, and treat an IFVG flip as a shift in short-term control.
• When a trade closes, a result label prints the outcome (TP hit, stop, or exit at R) so completed setups stay readable.
• Combine with your own structure, session and news context — the gap engine locates the where , you confirm the when .
▎ KEY SETTINGS
• Engine — enable bullish/bearish detection, choose the signal source (Rejection, IFVG Flip, or both), and cap how many gaps stay visible plus their lifetime and box extension.
• Filters — ATR length, minimum gap size, minimum displacement body ratio, minimum grade, the HTF bias filter (timeframe + EMA length), and whether a directional rejection close is required.
• Trade Model — stop basis (Gap-Protected vs ATR), stop buffer/distance, risk floor and cap, TP1–TP3 in R, max trade duration, zone projection, and how many completed trades to keep.
• Visuals — toggle gap boxes, midline, hide-mitigated declutter, grade spotlight, IFVG styling, signal pills, zone boxes, lines, level and result labels, zone-reader candle coloring, optional VWAP + σ bands, and all colors/transparency/sizes.
• Dashboard — show/hide, position, text size, and dark or light panel.
▎ DASHBOARD
The on-chart panel reports: HTF bias, count of active bullish and bearish gaps, the nearest gap price and its fill %, the strongest gap's star grade, the last IFVG flip (with bar age), the active signal, any live trade with its entry, and running totals of bullish / bearish / inverted gaps detected.
▎ ALERTS
• BUY signal
• SELL signal
• Bullish IFVG Flip (inversion up)
• Bearish IFVG Flip (inversion down)
▎ NOTES
• Works on all timeframes and all assets — indices, forex, crypto, stocks, futures.
• Signals and drawings are computed on closed bars, so they do not repaint after the bar confirms.
• Object caps and hide-mitigated / declutter toggles keep the chart clean even on long histories.
• Any on-chart result labels reflect historical signals only and are illustrative, not a performance guarantee.
For research and education only. This is not financial advice. No indicator can predict the future, and past behavior does not guarantee future results — always manage your own risk.
Made with passion by JackOfAllTrades ⚡
Indicateur

Dealing and Displacement Range Trade EntriesDealing and Displacement Range Trade Entries
tradingview.com
Dealing and Displacement Range Trade Entries is an advanced Smart Money Concept based TradingView indicator designed to identify high-probability institutional trading opportunities by combining market structure, dealing ranges, premium and discount zones, displacement, Order Blocks, Fair Value Gaps and precise trade execution levels into one complete trading system. Instead of relying on a single confirmation, the indicator builds every setup using multiple layers of price action analysis so traders can understand where institutions are most likely accumulating or distributing positions before entering the market.
The primary purpose of this indicator is to simplify institutional trading concepts into a visual and rule-based framework that can be used on every market and every timeframe. Whether a trader is trading Forex, Gold, Indices, Cryptocurrency, Stocks or Futures, the indicator automatically adapts to current market conditions and continuously updates its analysis as new candles are formed.
The foundation of the indicator begins with automatic detection of a confirmed Three Bar Swing High and Three Bar Swing Low. A Swing High is confirmed when the middle candle creates the highest high while the candles on both sides fail to exceed that high. Likewise, a Swing Low is confirmed when the middle candle forms the lowest low while the surrounding candles fail to break that low. These swing points are confirmed only after the right-side candle closes, ensuring stable structure recognition and minimizing repainting.
Once both swing points have been identified, the indicator automatically creates a complete Dealing Range between the confirmed Swing High and Swing Low. This range represents the active institutional price cycle where buying and selling activity is expected to develop. Instead of forcing traders to manually draw ranges, the indicator continuously recalculates and updates the dealing range whenever a new valid market structure is confirmed.
The dealing range is automatically divided into two equal sections. The upper half becomes the Premium Zone while the lower half becomes the Discount Zone. These zones provide an immediate visual understanding of where price is considered relatively expensive or relatively discounted within the current market cycle. This helps traders avoid entering trades at poor prices and instead focus on areas where institutional participation is more likely.
The Premium Zone is primarily monitored for selling opportunities. When price trades into this region, the indicator searches for additional institutional confirmations such as bearish Order Blocks, bearish Fair Value Gaps and displacement signals before considering a short setup. Conversely, the Discount Zone is monitored for buying opportunities where bullish Order Blocks, bullish Fair Value Gaps and bullish displacement provide additional confirmation before generating a long setup.
The indicator also identifies Fair Value Gaps that represent areas of temporary market imbalance created by aggressive buying or selling pressure. These imbalances often act as magnets for future price movement as the market seeks to rebalance inefficient price delivery. Fair Value Gaps are automatically highlighted and extended while remaining valid, allowing traders to anticipate future reaction zones.
Alongside Fair Value Gap detection, the indicator automatically identifies significant Order Blocks that represent institutional buying and selling activity. These Order Blocks serve as potential reaction levels where professional market participants may defend previous positions. By combining Order Blocks with Premium and Discount Zones, traders receive stronger confirmation before entering the market.
Displacement plays an equally important role within the overall trading model. Strong directional price movement indicates aggressive institutional participation and often signals the beginning of a new market phase. The indicator evaluates these displacement moves alongside market structure to determine whether momentum supports continuation or potential reversal.
Once all required confirmations align, the indicator automatically generates a complete trading setup. Every setup is plotted directly on the chart with clearly defined Entry, Stop Loss and multiple Take Profit objectives. Entry signals are confirmed only after the required candle closes, helping reduce false signals generated by incomplete price action.
For Buy setups, the indicator waits until price enters the Discount Zone and receives confirmation from institutional structure before plotting the entry. Stop Loss is positioned beneath the protected structural low while Take Profit levels are projected toward important liquidity objectives, Fair Value Gaps, Order Blocks and eventually the opposite side of the dealing range.
For Sell setups, price must first enter the Premium Zone before institutional confirmations are satisfied. Once bearish confirmation is complete, the indicator plots the Sell Entry together with a logically positioned Stop Loss above market structure and multiple Take Profit targets extending toward Discount Zone liquidity.
To improve trade management, every signal includes a complete visual Risk Reward projection. Traders can immediately see the relationship between Entry, Stop Loss, Take Profit levels and Final Target without manually drawing trading boxes. This creates a structured workflow that encourages disciplined risk management.
The indicator also displays an intelligent dashboard that continuously summarizes important market information. The dashboard provides the current market bias, price location within the dealing range, active trading status, equilibrium level, range boundaries and live trade information. These values automatically update with every incoming candle, allowing traders to monitor changing market conditions in real time.
One of the strongest advantages of this indicator is its ability to combine several institutional trading concepts into one unified workflow. Rather than requiring traders to use multiple separate indicators for market structure, Fair Value Gaps, Order Blocks, dealing ranges and trade management, everything is integrated into a single organized trading environment.
The indicator is suitable for scalping, intraday trading, swing trading and higher timeframe positional analysis because every calculation automatically adapts to the currently selected timeframe. This flexibility allows traders to maintain the same decision-making process regardless of market or trading style.
The objective behind publishing this indicator is to provide traders with a professional institutional analysis framework that simplifies complex Smart Money Concepts into a clear, visual and practical decision-support system. By automating repetitive chart analysis while preserving transparent trading logic, the indicator helps traders improve consistency, reduce emotional decision making and execute trades using predefined institutional rules instead of subjective judgment.
Verification
This indicator has been independently designed and developed for the TradingView profile Forex_Market_Insights. The overall architecture, analytical methodology, visualization techniques, calculations and trading workflow have been created specifically for this project using original Pine Script Version 6 development practices. Every component has been built to provide a structured institutional trading experience while maintaining a consistent, professional and well-documented implementation.
Clarification
This indicator presents an original implementation of widely recognized technical analysis concepts including market structure, dealing ranges, premium and discount zones, displacement analysis, Fair Value Gaps and Order Blocks. While these concepts are commonly discussed within the trading community, the source code, calculation flow, chart visualization and system design have been independently developed for this indicator. The project is not intended to reproduce, decompile or replicate the protected implementation of any third-party script. Its purpose is to provide traders with a transparent, educational and practical analytical framework that follows original software development principles and supports responsible TradingView publishing practices.
tradingview.com Indicateur

Indicateur

Titan Algo | PropTraderz
Titan Algo | PropTraderz is an all-in-one technical analysis indicator designed to help traders identify market direction, trend strength, potential Buy/Sell signals, and important trading levels.
Main features:
• Supertrend-based Buy and Sell signals
• Optional Smart Signals using the 200 EMA trend filter
• Multi-timeframe dashboard for M1, M5, M15, M30, 1H, 4H, and D1
• Bar Coloring modes: Gradient, Trend, or None
• Trend Cloud, Trend Follower, Cumulus Cloud, and Cirrus Cloud
• Smart Trail and dynamic trend lines
• Support and Resistance zones
• Supply and Demand areas
• ATR-based Entry, Stop Loss, and Take Profit levels
• 1:1, 2:1, and 3:1 risk-reward targets
• Buy and Sell alerts
• Adjustable sensitivity and risk-management settings
This indicator is intended as a technical analysis and confluence tool. Signals should always be confirmed with your own market analysis and proper risk management. This script does not provide financial advice. Indicateur

Indicateur

Indicateur
