Session Micro-Structure Shift & Range Equilibrium RadarOverview and Purpose
The Session Micro-Structure Shift and Range Equilibrium Radar is an open source technical analysis indicator designed for intraday traders utilizing ICT and Smart Money Concepts (SMC). It automates the tracking of key trading sessions like Asia, London, and New York, measures range equilibrium, and filters for structural shifts combined with Fair Value Gap (FVG) retests.
How the Indicator Works and Mathematical Logic
1. Session Range and Equilibrium Computation:
The script plots distinct session ranges for Asia (20:00 to 00:00 UTC-4), London (02:00 to 06:00 UTC-4), and New York (08:00 to 12:00 UTC-4). For each active session, the 50 percent Equilibrium level is dynamically plotted using the average of session high and session low.
2. Liquidity Sweep Detection:
The algorithm continuously checks whether price sweeps the previous session high or low liquidity levels.
3. ATR Filtered Displacement and MSS Confirmation:
Following a sweep, a Micro-Structure Shift (MSS) is validated only when a displacement candle forms. Displacement is verified using a 14 period Average True Range filter where the candle body size exceeds 0.8 times the ATR value. The bar must close beyond the active session equilibrium line to mark a true MSS.
4. Fair Value Gap (FVG) Identification and Alert Engine:
When an MSS is confirmed, the script checks for a 3 candle imbalance and draws an active zone box. To avoid signal spam, exactly one alert per session is triggered when price taps into the FVG zone.
Trading Interpretation and Application
Valid Setup (FVG Tap):
When price sweeps a session extreme, confirms an MSS across the Equilibrium level, and retraces to tap the highlighted FVG zone, a valid trade setup occurs. Traders typically place stop losses at the recent swing low or high and target a minimum 1 to 2.5 Risk to Reward ratio.
Invalidated or Unfilled Setup (Missed FVG):
If price performs all required steps like sweep and MSS but fails to retest or tap the FVG box before expanding away, no alert triggers, and the setup is treated as unfilled to protect capital.
Disclaimer
This script is strictly for educational and chart analysis purposes. It does not provide financial advice or direct trading signals. Always manage risk responsibly and perform backtesting across your chosen trading pairs.
Indicator

PO3 Matrix+ (M1D)PO3 Matrix+ (M1D)
Projects the recent candles of a chosen higher timeframe as a compact candle matrix beside live price, then marks the liquidity events, structure and PD array context that develop on that timeframe — taken swings, structure shifts, fair value gaps, previous-day levels, and cross-market divergence. The intent is to read higher-timeframe conditions without leaving the execution chart, and to keep every drawn element sourced from the same data so nothing drifts out of step.
── HOW IT IS BUILT ──
The selected higher timeframe is pulled once, as a snapshot of its recent candles, and every element is drawn on the last bar from that one source. Dividers, high/low rails, quadrants, sweeps, gaps and structure all read the same array, so they cannot disagree with each other. The forming candle is accumulated from chart bars, so it updates live without repainting its history.
Level lines are origin-anchored: each one begins at the candle that actually printed the extreme, not at the bar where the level happened to be calculated. Derived midlines (equilibrium, the inner quartiles) have no originating candle, so they run from the period open instead.
── WHAT IT DRAWS ──
PO3 CANDLE MATRIX — the selected higher timeframe's recent candles, projected to the right of price with time dividers on the live chart and a per-candle high/low rail. A countdown above the block shows the timeframe in use and the time left on the forming candle. The PD array context is mirrored onto the block at its own horizontal scale, and each event carries a compact direction marker there, so the block reads as a standalone view of what that timeframe is showing.
CANDLE EQUILIBRIUM — the true 50 percent of each completed candle in the block, as a reference the following candle can retrace into.
CURRENT-RANGE QUADRANTS — the forming candle's high, 75 percent, equilibrium, 25 percent and low projected across price as a live premium and discount reference.
LIQUIDITY SWEEPS — only swing liquidity is marked. A level qualifies when it is a swing high or swing low that a later candle raids and then closes back inside: wick beyond, body back within. A candle that simply trades past its neighbour is not a sweep and is not marked.
SMT DIVERGENCE — the correlated market is read on the same higher-timeframe grid, so the two align candle for candle. A SMT is marked when your chart takes a swing but the peer fails to take its matching swing, meaning the move lacked cross-market participation. The peer auto-pairs across equity indices, precious metals and BTC against ETH, in matching contract sizes, and can be overridden with any symbol. It deliberately does not guess a peer for markets where the correlation is too loose for a divergence to mean anything; with no pairing, no SMT is drawn. A SMT is invalidated in real time once price trades back through the extreme that formed it, and is then either faded or removed.
MARKET STRUCTURE SHIFT — a true swing broken by a body close. A swing here means a level price actually turned at: a swing low sits at the change from a down candle to an up candle, a swing high at the change from an up candle to a down one. A low that merely sits under its neighbours while price kept running the same way is not a swing and is never used, which is what separates this from a plain pivot break. The first candle to CLOSE beyond the swing's full wick — body, not wick — marks the shift; later closes past the same level are continuation and are not marked. An optional setting requires a liquidity raid to precede the shift, for the classic sweep-then-shift sequencing: a buyside raid before a bearish shift, a sellside raid before a bullish one.
FAIR VALUE GAPS (BISI+ / SIBI-) — detected on the higher-timeframe snapshot, so they are multi-timeframe by construction. Only fully formed gaps are drawn; a gap still forming on the live candle is ignored until it completes. Each zone moves through four states: live, active, inverted, or spent. A gap closed clean through has inverted — the old support is now resistance, or the reverse — and it stays inverted, flipped and redrawn in the inversion colour, for as long as that break holds. No retest is required, because a retest is where the level gets traded rather than what makes it valid. Closing back through in the original direction takes the gap back; the zone is spent, and fades but stays on the chart as history rather than disappearing.
PREVIOUS-DAY LEVELS — previous high, low and equilibrium, drawn from session start and dimming once taken. Three definitions of the day are offered because they genuinely differ on futures: the symbol's own daily candle, midnight to midnight New York, or the regular-hours session only. Regular hours are taken from the instrument itself rather than a fixed clock, so index futures, metals and everything else each use their own session. The label carries the source date, so a level that is several days old after a weekend reads as intentional.
CONTEXT TABLE — day, AMD phase, forming-candle bias, premium or discount, higher-timeframe direction, last sweep, market structure shift, fair value gap, previous-day status, and a session-close countdown. SMT is drawn on the chart and the block but does not have its own table row.
── SETTINGS WORTH KNOWING ──
The higher timeframe must be above the chart timeframe; the script says so on the chart if it is not.
Session handling is read from the instrument, not hardcoded, so the regular-hours option and the session countdown are correct on index futures, metals and anything else without configuration. Instruments that trade around the clock have no regular session, and the countdown says so rather than inventing one.
Every drawn element can be turned on or off on its own, and the chart labels and the compact markers on the projected block are controlled separately, so the block can be kept clean while the chart stays annotated. Label size, colour, vertical clearance, which side of a line a label sits on, and the marker glyph style are all adjustable.
Fair value gap sensitivity is measured against the average range of the visible higher-timeframe candles, so it scales per instrument rather than being a fixed distance. Raise the minimum height and displacement to keep only the larger gaps.
Market structure shift has an optional displacement requirement, off by default. Turn it on if you want the shifting candle to also expand or leave a gap, which reduces how often it marks.
Sweeps, gaps and structure marks each have a maximum shown, so the chart stays contained rather than accumulating history indefinitely. Gap zones also declutter against each other: two translucent zones stacked on the same prices multiply into a solid block, so a zone overlapping one already drawn beyond an adjustable tolerance is skipped and the most recent gap in that price band is the one kept. The same idea applies to stacking: two same-direction zones separated by only a thin seam read as one inefficiency wearing two boxes, so the older one is removed and the newest kept. Zones facing opposite directions are never removed for sitting close together — they are genuinely different reads.
── NOTES ──
Detection runs on completed higher-timeframe candles. The forming candle updates live, but a gap or a structure mark is only considered once the candles that define it have closed.
SMT is not available in bar replay. Replay rewinds the chart symbol only, so the correlated symbol keeps returning its live data and the two grids no longer line up; the table reports Misaligned and no divergence is drawn. That is the alignment guard working, not a fault. Every other feature reads from the chart symbol and replays normally.
Everything drawn is context. There are no entry or exit instructions, no directional calls, and no performance claims of any kind. It reports what has happened on the higher timeframe.
This is a market-analysis tool, not financial advice. Past market behaviour does not indicate future results. Test any tool thoroughly and trade your own plan.
Indicator

FVG Sweep Magnet Engine [PhenLabs]📊 FVG Sweep Magnet Engine
Version: PineScript™ v6
📌 Description
The FVG Sweep Magnet Engine turns displacement-born Fair Value Gaps into scored magnetic targets that only arm after a real liquidity sweep. Instead of treating every imbalance as tradeable, FSME waits for buy-side or sell-side liquidity to be raided, then confirms when price is pulled back into a high-quality FVG.
This solves the two biggest failure modes retail ICT tools create: trading empty gaps with no context, and chasing sweeps that never reclaim structure. Neon multi-layer magnet beams, graded gap boxes, and a live regime dashboard make the confluence readable in one glance — built for dark-chart screenshots and fast decision-making on futures, indices, FX, and crypto.
🚀 Points of Innovation
Displacement-validated FVG detection filters out micro-noise gaps that never attract price
Liquidity sweep gate (BSL/SSL raid + rejection) must print before any magnet signal arms
0–10 quality score blends gap size, displacement strength, freshness, and volume impulse
Clean visual hierarchy: soft FVG zones + single CE midline by default; neon only on MAG
Partial-fill fade and full mitigation cleanup keep the chart honest as gaps get consumed
Live FSME dashboard tracks bias, live gaps, best score, sweep state, and last signal
🔧 Core Components
Displacement FVG Engine: Detects classic 3-candle bullish/bearish imbalances only when the middle candle body clears an ATR displacement threshold and the gap clears a minimum ATR size filter
Liquidity Rail Tracker: Maintains confirmed swing BSL/SSL pools as dotted rails and classifies wick-rejection raids that reclaim the level
Magnet Confluence Gate: Arms a signal only when a fresh sweep window overlaps a live scored FVG that price re-enters with directional close confirmation
Target Projector: Extends dotted neon target rays from the FVG midline by ATR multiple after a magnet print
Regime Dashboard: Compact top-right table summarizing bull/bear FVG count, best score, sweep state, last signal, nearest magnet mid, and ATR
🔥 Key Features
Non-repaint pivot liquidity and confirmed-bar FVG logic suitable for alerts and live trading
Configurable displacement, gap size, magnet window, min score, and target extension
Bull cyan / bear magenta neon palette with independent fill, border, rail, and beam colors
Optional faded mitigated FVGs for study mode, or hard-delete cleanup for clean charts
Alertconditions for bull/bear magnets, BSL/SSL sweeps, and new displacement FVGs
Works as a standalone SMC overlay or confluence layer on top of session/order-block tools
🎨 Visualization
FVG zones: Soft teal/red translucent boxes (high transparency so candles stay readable) with score on the right edge
CE midline: Single thin dashed line at the gap center — no permanent multi-layer beam cage
Neon on MAG only: Triple glow beam + TP ray appear only when a magnet signal arms
MAG labels: Clear ▲ MAG / ▼ MAG tags offset above/below the bar (not stacked on wicks)
Optional extras (off by default): liquidity rails and sweep diamonds for power users
Signal highlight: Soft bar tint only on confirmed MAG bars
Dashboard: Compact 6-row panel — Bias, Live Gaps, Best Score, Sweep, Last Signal
📖 Usage Guidelines
Max Active FVGs — Default: 10 — Range: 2-40 — Keep low for a clean chart
Displacement ATR Mult — Default: 1.25 — Range: 0.3-5.0 — Raise on noisy lower TFs
Min Gap Size (ATR) — Default: 0.25 — Range: 0.05-3.0 — Higher = fewer, cleaner zones
Require Displacement Candle — Default: true — Keep on for quality
Max FVG Age (bars) — Default: 60 — Range: 10-300 — Expires stale magnets
Magnet Window — Default: 18 — Range: 3-80 — Bars after a sweep for FVG entry confirm
Min Score for Signal — Default: 5 — Range: 0-10 — Raise to 7+ for selective setups
Show FVG Midline (CE) — Default: true — Single dashed CE line per zone
Neon Beam Only on MAG — Default: true — Neon appears only on confirmed signals
Show Liquidity Rails — Default: false — Optional; off keeps chart readable
Show Sweep Diamonds — Default: false — Optional; off by default to reduce noise
✅ Best Use Cases
ICT/SMC traders waiting for liquidity raids into unfilled FVGs instead of blind gap fades
Intraday index and futures traders (ES, NQ, YM) on 1m–15m seeking clean reversal confluence
FX and crypto traders mapping displacement legs during London/NY expansion
Prop-style discretionary traders who want scored setups with explicit invalidation (full gap fill)
Content creators capturing high-contrast neon dark-chart screenshots for PulseWire publish art
⚠️ Limitations
FVG detection is geometric (3-candle imbalance) and does not use true order-book data
Sweep logic uses confirmed swing pivots, so very fresh local highs/lows need pivot length bars to register
High-volatility news spikes can create large displacement gaps that score well but fail if context is one-way trend
Neon beams and boxes are object-limited; extreme settings (max FVGs + long age) can hit PulseWire object caps
This is a confluence overlay, not a complete strategy — always pair with risk rules and higher-timeframe bias
💡 What Makes This Unique
Sweep-gated magnets: FVGs stay passive until liquidity is actually raided — reverse of “every gap is a signal” tools
Scored gaps: Traders see why a zone matters (size, displacement, age, volume) instead of binary boxes
Signal-first visuals: zones stay quiet until confluence arms — neon and TP only on MAG
PhenLabs DNA: Liquidity + engine naming + dashboard, fused with this week’s dominant FVG/ICT community demand
🔬 How It Works
Displacement scan: On each bar the engine checks for a 3-candle bullish or bearish FVG, requires the middle candle body to clear ATR × displacement mult, and rejects gaps smaller than ATR × min gap size
Score + draw: Qualifying gaps receive a 0–10 score and are rendered as translucent boxes with a three-layer neon midline beam and optional score label
Liquidity map: Confirmed pivot highs/lows become BSL/SSL rails; a sweep prints when price raids the level with sufficient wick and closes back through it
Magnet arming: For a limited bar window after the sweep, if price re-enters a live same-direction FVG that clears the min score and closes in the reclaim direction, a MAG signal fires
Projection + lifecycle: Dotted ATR targets extend from the magnet mid; partial fills fade the box, full fills or max age invalidate the gap and clean objects unless faded mode is enabled
💡 Note:
Use FSME as a visual decision-support layer for liquidity-to-imbalance workflows. Confirm higher-timeframe bias, define risk beyond the opposite side of the FVG or swept pool, and never treat magnet markers as guaranteed entries. This script is an analytical aid only and does not constitute financial advice.
Indicator

CHoCH SetupCHoCH Setup is a comprehensive multi-timeframe analysis tool designed to identify structural shifts, validate them with volume and momentum, and highlight high-probability Fair Value Gap (FVG) entries.
Multi-Timeframe (MTF) Alignment: Evaluates a Higher Timeframe (HTF) directional bias to ensure your current timeframe trades align with the macro trend.
Volume Point of Control (POC): Dynamically calculates the high-volume node of recent periods. Breaks through the POC indicate strength.
BLVL (Break Level) CHoCH & BOS: Identifies structural market shifts. A CHoCH (Change of Character) triggers the drawing of the main setup box.
Volume Profile Inside CHoCH Box: Visualizes the volume intensity directly within the CHoCH box to validate the momentum of the breakout.
RSI Tracking Polyline: Tracks the RSI behavior historically to identify if the setup occurred in overbought/oversold conditions or if there is momentum divergence.
FVG Engine: Highlights bullish and bearish Fair Value Gaps. It can optionally filter for "bounces" or mitigations where price taps into the FVG after a structural break.
CHoCH Fibonacci Zones & Targets: Automatically plots a Buy/Sell mitigation zone (0.382 - 0.618) and extended target levels (1.47, 1.55, 2.56, 2.6, 2.68) for taking profit.
HUD Dashboard: Provides a real-time summary of the HTF Bias, Current TF Bias, POC Trap State, and the strength of the current CHoCH.
🎯 Identifying an "A+ Setup"
An A+ setup occurs when multiple confluences align simultaneously. Look for the following conditions on your dashboard and chart:
Timeframe Alignment: Both HTF Bias and Current TF Bias are pointing in the same direction.
Strong CHoCH Signal: A CHoCH break happens in the direction of the HTF Bias, backed by above-average volume (indicated by thick volume columns inside the CHoCH box).
POC Confirmation: Price breaks and holds beyond the POC level, avoiding a "Trap" state (e.g., a "Strong Bullish" state on the dashboard).
FVG Creation: The impulse move that caused the CHoCH leaves behind a Fair Value Gap.
Entry Execution: Price pulls back into the CHoCH Fibo Zone (0.382 - 0.618) and taps the FVG. This is the optimal entry zone targeting the extended Fibo levels (1.47+).
🔔 Alerts
The script includes built-in alert conditions tailored for this setup:
Bullish CHoCH Direction FVG Formed!: Triggers when a new bullish FVG forms immediately following a Bullish CHoCH.
Bearish CHoCH Direction FVG Formed!: Triggers when a new bearish FVG forms immediately following a Bearish CHoCH.
(To set these up: Create an alert on PulseWire, select the indicator, and choose "Any alert() function call".)
⚠️ Disclaimer
This script is provided for educational and informational purposes only. It does not constitute financial or trading advice. Trading in financial markets involves a high degree of risk, and past performance of any indicator or setup is not indicative of future results. Always backtest strategies thoroughly and use proper risk management.* Indicator

Fair Value Gap Detector | AlphaScript⚡ Fair Value Gap Detector
Most fair value gap indicators mark every three-candle gap on the chart — including the weak, meaningless ones. This tool only marks FVGs created by genuine displacement: a strong-bodied move that signals real institutional participation. Fewer gaps, but the ones that matter.
💡 What a fair value gap is
A fair value gap (FVG) is a three-candle imbalance where price moved so quickly that it left an unfilled gap. In a bullish FVG, the low of the third candle sits above the high of the first — the middle candle's move was so strong it skipped a price range where little trading occurred. Price often returns to "fill" these gaps before continuing, which is why traders watch them as potential entry and reaction zones.
🎯 Why displacement matters
A gap alone is not significant, gaps form constantly, most from weak or random price action. What makes an FVG worth trading is displacement: the middle candle being a large, decisive move that leaves the gap behind. This tool measures the middle candle's body against ATR and only registers the FVG when that body is large enough to qualify as real displacement, and when it moved in the gap's direction. The result is a chart showing institutional-grade gaps instead of noise.
🔍 How detection works
On each confirmed three-candle sequence the tool checks:
A valid gap exists (third candle's low above first candle's high for bullish; third's high below first's low for bearish).
The gap is at least a minimum size, measured as a multiple of ATR, so it is instrument-independent.
The middle candle's body is a genuine displacement — at least a configurable multiple of ATR — and pushed in the gap's direction.
Only sequences passing all three become FVG zones. The displacement requirement can be turned off if you prefer the classic "any gap" behavior.
🟩 Mitigation tracking
Each FVG zone stays active until price fills it. You choose how a fill is counted:
Touch — the gap is mitigated when price reaches its midpoint (the 50% level, where FVGs often react).
Close — the gap is mitigated only when price closes fully through it.
A midline marks the 50% level of every zone.
🎨 Customization
Bullish and bearish fill colors and opacity, midline display, and how far zones extend to the right (a configurable number of bars, so zones don't run infinitely across the chart, or fully infinite if you prefer). Separate toggles for bullish and bearish zones.
📈 How to use it
Treat an active bullish FVG below price as a potential demand zone and an active bearish FVG above price as potential supply. Watch for price returning to a zone — especially the 50% midline — as a possible reaction point, in the direction of the displacement that created it. Because only displacement gaps are shown, each zone represents a move with real momentum behind it rather than a random imbalance. Combine with your own structure and bias — the tool marks the zones, you make the decisions.
🔔 Alerts
Bullish FVG formed, bearish FVG formed, and mitigation alerts when a zone is filled.
⚙️ Settings
ATR length and minimum gap size, displacement requirement and strength, mitigation mode, zone extension length, colors, opacity, midline, and per-direction display toggles.
📌 Notes
FVGs are detected on confirmed bars only and do not repaint intrabar. Detection strictness depends on the gap-size and displacement settings — tune them to your instrument and timeframe. A fair value gap marks an area of potential interest, not a guaranteed reaction — always combine with your own analysis and risk management.
Indicator

EonMetrics CISDCISD — Change In State of Delivery
CISD marks the moment the market's delivery flips. Price is "delivered" in one direction through a series of consecutive same-direction candles; the open of the first candle of that series is the delivery level. When a later candle closes back through that level, the state of delivery has changed — that close is the CISD. The level is then kept on the chart and tracked as support or resistance, with retest and invalidation handling.
🔶 HOW IT WORKS
The script counts consecutive same-direction candles (by candle body, by default). When such a series ends, the open of its FIRST candle is remembered as the delivery level, shown as a dotted pending line. When a later candle CLOSES through that level against the series direction, the CISD is confirmed — the level is drawn and tracked as support or resistance from that bar on.
🔶 HOW CISD DIFFERS FROM MSS / BOS
Structure tools (MSS, BOS, CHoCH) need a swing pivot: a high or low must form and be confirmed by candles on both sides before a break of it means anything. CISD needs no pivot at all — the reference level comes straight from the candle series itself (the open of the first candle of the last delivery leg). That is why a CISD typically confirms earlier than a structure shift: the close through the series origin often prints several bars before the equivalent MSS. Earlier also means less filtered — CISD is a faster, more granular read of the same idea, not a replacement for structure.
🔶 WHAT IT DOES
Series detection — counts consecutive same-direction candles (direction by candle body, or optionally close-vs-previous-close). A series qualifies as delivery once it reaches the minimum length you set. A doji can either ride the series or end it — your choice.
Pending level (dotted) — as soon as a qualifying series ends, the open of its first candle becomes the candidate level, drawn as a dotted line. This is where the next CISD would confirm. Nothing is signaled yet — the line just shows you what the market has to close through.
Confirmed CISD (solid) — when a candle closes through the pending level, the level turns solid, gets its CISD label, and starts being tracked: bullish CISD levels act as support, bearish as resistance.
Level lifecycle — an active level extends bar by bar. When price fully leaves it and later returns to touch it, that touch is marked as a retest (wick-based). When a candle closes back through the level, it is invalidated — removed, or kept dimmed on the chart if you prefer to study failures. An optional lifetime cap quietly expires old levels.
Current delivery state — an optional floating label shows the running series direction and its candle count (e.g. "Bearish x4").
🔶 NON-REPAINTING
The entire engine advances on confirmed bars only. Nothing is drawn, moved or deleted intrabar: a pending level appears only after its series is complete, a CISD confirms only on a closed candle, and retests/breaks are evaluated on closed candles. What you see on a historical chart is exactly what you would have seen live.
🔶 ALERTS
Six alert conditions: bullish/bearish CISD confirmed, bullish/bearish level retested, bullish/bearish level broken.
🔶 HOW TO USE
1. Keep Min Series Length at 2 for a responsive read, raise to 3-4 to only mark the strongest delivery legs.
2. Watch the dotted pending line — it tells you in advance which level a close has to take out for delivery to flip.
3. After a confirmed CISD, the level itself is the tradeable information: bullish CISD levels tend to act as support on the retest, bearish as resistance.
4. Set alerts on confirmations and retests instead of watching the chart.
🔶 SETTINGS
Detection (min series length, candle direction mode, doji handling) · Levels (max active per side, lifetime, keep broken, retest markers, pending line) · Style (colors, line width, label size, delivery-state label).
This tool annotates delivery levels. It does not predict direction, does not generate entries and has no targets — what you do at a level is your decision.
Part of the EonMetrics toolset.
Indicator

MTF FVG + OB Confluence Strategy (4H -> 1H -> 15M) | XAUUSDMTF FVG + OB Confluence Strategy (4H → 1H → 15M) | XAUUSD
This strategy trades price-action confluence across three timeframes (4H, 1H, 15M) using Fair Value Gaps (FVG) and Order Blocks (OB), entering only when a fresh engulfing candle confirms rejection inside an aligned zone.
How it works
Scans the 4H, 1H, and 15M timeframes for Fair Value Gaps and Order Blocks, plotting each as a labeled zone anchored to the candle that formed it.
An Order Block requires a displacement candle at least 1.2x the 15M ATR, confirming real momentum rather than noise.
When a mitigated Order Block is broken, it can optionally flip into a Breaker Block with reversed bias.
A trade is only considered when a 15M zone overlaps a same-direction 1H zone (with an option to require full 4H+1H+15M triple alignment for a stricter filter).
Entry triggers on a bullish/bearish engulfing candle that touches the active confluence zone.
Optional session filter restricts trading to the London and NY AM killzones.
Risk management
Position size is calculated from a fixed risk percentage of equity per trade.
Stop-loss sits just beyond the zone boundary, with an ATR-based buffer.
Take-profit uses three Fibonacci extensions of the initial risk (default 1.618R / 2.618R / 4.236R), scaling out 33/33/34% of the position at each target.
Only one position is open at a time — no pyramiding or averaging into losers.
Notes
Built and tested for XAUUSD; timeframes and risk inputs are adjustable for other symbols.
The on-chart table shows live zone counts, confluence status, and trigger state for transparency.
This is not financial advice — backtested performance does not guarantee future results. Always validate on your own account/broker conditions before trading live. Strategy

Liquidity Sweep Hunter | AlphaScript💧 Liquidity Sweep Hunter
Liquidity Sweep Hunter maps the resting liquidity at swing highs and lows — the stop orders sitting just beyond obvious pivots — and detects when price raids it. It marks each level as resting, swept, or reclaimed, so you can see both where liquidity is waiting and when it gets taken.
💡 The idea behind it
Stop orders cluster just beyond swing highs and swing lows. Above a swing high sit the stops of short sellers and the buy orders of breakout traders — buy-side liquidity (BSL). Below a swing low sit the opposite — sell-side liquidity (SSL). Larger participants are drawn to these pools because that resting liquidity is what fills their orders. When price spikes through a level, takes the stops, and rejects back, that is a liquidity sweep — often the origin of a reversal. This tool identifies those events systematically instead of by eye.
🔍 How detection works
Levels are anchored to confirmed swing pivots (default lookback 10 bars each side). A swing high becomes a buy-side liquidity level; a swing low becomes a sell-side liquidity level. Pivots are only registered after they are fully confirmed, so levels do not repaint. Each level is drawn as a line and tagged so its state is always clear:
⇠ Resting — an unswept level. The stops are still sitting there; price may return to raid it. Tagged BSL ⇠ (above swing highs) or SSL ⇠ (below swing lows). These are potential targets.
✗ Swept — price wicked through the level but the bar closed back on the original side. The stops were taken and price rejected. Tagged ✗ BSL swept or ✗ SSL swept.
⟲ Reclaimed — price closed through the level, then on a later bar closed back across it: a failed break that reclaimed the level. Tagged ⟲ BSL reclaimed or ⟲ SSL reclaimed.
You choose the detection mode: Wick (sweeps only), Reclaim (break-and-reclaim only), or Both.
🎯 Penetration filter
An optional ATR-based filter requires price to pierce the level by a minimum multiple of ATR before an event qualifies. Because it is measured in ATR rather than fixed ticks, it means the same thing across every instrument — no re-tuning when you switch markets. Set to zero to disable.
🟠 Broken levels
In Reclaim and Both modes, a level that price closes through is kept on the chart in a distinct color and tagged while it awaits a possible reclaim — so you can see levels that failed but might still be reclaimed. These can be toggled off for a cleaner chart.
📊 Dashboard
A compact panel shows the current symbol, the number of active buy-side and sell-side levels being tracked, and the active detection mode. Theme (dark/light), size, and position are all configurable.
🎨 Customization
Full control over the look: colors for bullish/bearish events, level lines, and broken levels; line style and width for both level lines and event lines; label text color (for readability on light or dark charts); how far pending level lines extend; and toggles for level lines, event labels, pending-level tags, and broken levels.
📈 How to use it
Watch the resting (⇠) levels as the liquidity price may be drawn toward. When a swing high is swept (✗ BSL) after an up-move, buy-side liquidity has been taken and a move down may follow; a swept swing low (✗ SSL) can signal the reverse.
Reclaim events flag failed breaks that often precede a move back in the reclaim direction. Use the tags as points of interest to combine with your own structure read, higher-timeframe bias, and risk management — the tool shows where liquidity rests and when it is taken; you decide what to do with it.
🔔 Alerts
Separate alerts for SSL sweep, BSL sweep, SSL reclaim, BSL reclaim, plus combined "Any Sweep" and "Any Reclaim" conditions.
⚙️ Settings
Swing lookback, detection mode, ATR penetration filter, maximum active levels, level age limit, visible-event cap, recent-bars window for signal shapes, plus the full display and customization controls above.
📌 Notes
This tool detects liquidity at swing pivots specifically — individual swing highs and lows. It is one lens on liquidity and pairs naturally with equal-high/low and session-level analysis for a fuller picture. Events are confirmed on closed bars and do not repaint intrabar. A liquidity sweep marks where stops were taken, not a guaranteed reversal — always combine with your own analysis and risk management. Indicator

ICT Logo 2-1-2 Nested Cycles - ExtendedICT Logo 2–1–2 Fractal AMD Cycles
This indicator is an experimental time-cycle framework inspired by ICT’s logo sequence and the fractal nature of price delivery.
The core idea is that every selected time range can be divided into three proportional phases using the sequence:
2 – 1 – 2
Because the total equals five units, each parent cycle is divided at:
0.40
0.60
1.00
This creates three consecutive time phases (Power of 3):
First phase: 40% of the cycle
Middle phase: 20% of the cycle
Final phase: 40% of the cycle
These phases can be interpreted through the familiar AMD framework:
Accumulation
Manipulation
Distribution
The indicator does not assume that every first phase must accumulate, every middle phase must manipulate, or every final phase must distribute. Instead, it provides a consistent temporal structure in which those behaviors can be studied.
Fractal AMD micro-cycles
The main feature of the indicator is recursive subdivision.
Each of the three primary AMD phases is divided again using the same 2–1–2 ratio. This creates smaller AMD cycles inside the larger one.
At each additional depth, the number of cycles increases:
Depth 1: 3 primary cycles
Depth 2: 9 micro-cycles
Depth 3: 27 smaller cycles
Depth 4: 81 micro-cycles
This makes it possible to observe how short-term price delivery develops inside a larger daily, weekly, monthly, four-hour, hourly, or intraday cycle.
For example, a daily parent cycle contains three major phases. Each major phase can then contain its own accumulation, manipulation, and distribution sequence. Those smaller cycles may themselves contain further micro-cycles.
The result is a nested temporal structure:
Parent AMD cycle
├── First major phase
│ ├── Micro accumulation
│ ├── Micro manipulation
│ └── Micro distribution
├── Middle major phase
│ ├── Micro accumulation
│ ├── Micro manipulation
│ └── Micro distribution
└── Final major phase
├── Micro accumulation
├── Micro manipulation
└── Micro distribution
Range boxes
Every cycle can be surrounded by a box that records the high and low produced during that specific time window.
The larger boxes show the range of the parent or major AMD phase, while the smaller nested boxes show the range created inside each micro-cycle.
The boxes update as new candles print and remain anchored to the chart’s time and price coordinates.
This helps visualize:
Range expansion and contraction
Liquidity forming above or below previous cycle ranges
Manipulation outside an earlier micro-cycle
Distribution away from a completed range
Nested premium and discount relationships
Whether a smaller cycle is expanding with or against the larger cycle
The box colors represent the repeating three-part sequence, not guaranteed bullish or bearish direction.
Supported parent cycles
The indicator can apply the same 2–1–2 structure across multiple time ranges:
Monthly
Weekly
Daily
4 Hour
1 Hour
15 Minute
Custom duration
The default daily range is: 00:00–16:15 New York time
The default weekly range is: Sunday futures open–Friday 16:15 New York time
Weekly, daily, and repeating-cycle anchors are adjustable, allowing the model to be tested on different market sessions and instruments.
Timing guides
Vertical timing lines show the boundaries of each cycle and micro-cycle.
Different colors and line styles distinguish the fractal depth. Major boundaries represent the larger cycle divisions, while thinner or dotted lines represent smaller nested timing intervals.
These lines are intended as areas of interest rather than automatic reversal signals (Or are they? 💡).
A timing boundary becomes more meaningful when it aligns with additional context such as:
External or internal liquidity
Previous highs or lows
Fair value gaps
Order blocks
NDOGs/NWOGs
SMT divergence
CISD
Displacement
Premium or discount positioning
Midnight Open
The indicator also plots the New York Midnight Open using the actual 00:00 candle opening price.
This level can be used as a daily reference for:
Intraday premium and discount
Bullish or bearish delivery relative to midnight
Liquidity runs around the opening price
Alignment between the parent AMD cycle and its micro-cycles
Suggested interpretation
The indicator is best used from the outside inward.
First, identify the current parent cycle and determine which of its three major phases is active. Then examine the smaller cycle currently developing inside that phase.
For example:
The daily cycle may be in its final 2-phase,
while the active hourly micro-cycle is still in manipulation.
This allows the trader to distinguish between the larger delivery structure and the immediate short-term behavior.
A lower-timeframe reversal may only represent a micro-cycle transition, while a reversal at the boundary of both a micro-cycle and a major parent phase may carry greater significance.
Important note
This indicator is a research and visualization tool. It does not claim that time alone predicts price, nor does it generate automatic trade signals.
The 2–1–2 sequence is used as a consistent fractal framework for studying AMD-style delivery across multiple time horizons. The model should be combined with price action, liquidity, market structure, and independent testing.
Past reactions around cycle boundaries do not guarantee future reversals or continuation.
Happy to discuss further in the comments. Let me know your thoughts 👇: Indicator

Order Block Zones | AlphaScriptOrder Block Zones automatically detects and tracks institutional order blocks the candles where significant buying or selling originated and manages each zone through its full lifecycle from formation to mitigation.
💡What an order block is
An order block is the last candle before a strong directional move: the point where institutional orders were placed before price left the area. Traders watch these zones because price often returns to them, using the untraded liquidity as support (bullish OB) or resistance (bearish OB). This tool identifies those zones systematically instead of by eye.
🔍How detection works
Zones are anchored to confirmed swing pivots. A bullish order block is drawn from a down-candle at a confirmed swing low; a bearish order block from an up-candle at a confirmed swing high. Pivots are confirmed using a symmetrical lookback (default 10 bars each side), so a zone only appears after the pivot is fully validated — the detection does not repaint. You can define the zone boundaries two ways: Full Candle (high to low, the complete range) or Body Only (open to close, a tighter zone focused on the candle body).
⚙️Filtering for quality
Not every pivot candle is worth marking. Two optional filters keep the chart focused on significant zones:
ATR Size Filter — the candle's range must exceed a multiple of ATR, so only meaningfully large origin candles qualify.
Volume Filter — the candle's volume must exceed a multiple of its 20-period average, favoring zones formed on genuine participation.
A configurable cap limits how many active zones are tracked per side, keeping the most recent and relevant ones.
🎯Mitigation tracking — the core of the tool
A zone stays active until price invalidates it. You choose how invalidation is measured:
Close mode — the zone is mitigated when a candle closes through it (stricter, fewer false invalidations).
Wick mode — the zone is mitigated on any wick penetration (more sensitive).
When a zone is mitigated you can either remove it (Delete) or leave a dimmed marker where it was (Keep Faded), so you can see where past zones were tested.
📈How to use it
Treat active bullish zones as potential demand (support) and active bearish zones as potential supply (resistance). Watch for price returning to an unmitigated zone as a possible reaction area, and use the mitigation state to know when a level has genuinely failed rather than held. The zone's midline gives a reference level within the block. Combine it with your own structure read and higher-timeframe bias — the tool marks the zones, you make the decisions.
🎨Customization
Zone fill and border opacity, border width, extension length, midline style and width, label size, side, and text, and full color control — so the zones fit your chart rather than forcing a fixed look.
🔔Alerts
Bullish/bearish order block formed, and bullish/bearish order block mitigated.
📌Notes
Zones are drawn from confirmed pivots and evaluated on closed bars only — signals do not repaint intrabar. Detection quality depends on the pivot length and filters; adjust them to your instrument and timeframe. Order blocks mark areas of interest, not guaranteed reversals — always combine with your own analysis and risk management. Indicator

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 PulseWire 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 PulseWire 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 PulseWire 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 PulseWire 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 PulseWire 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 PulseWire 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 PulseWire’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 PulseWire 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 PulseWire’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 PulseWire 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 PulseWire’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 PulseWire 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.
Indicator

NY Open Range Gap Reversal (M1D)M1D NY Open Range Gap Reversal
OVERVIEW
A reference and marking tool for the New York Regular Trading Hours (RTH) opening gap. It maps the price and time levels of the classic open-gap "manipulation then reversal" sequence so a discretionary trader can read the session at a glance. It draws levels and flags conditions on closed bars — it does not place orders, produce buy/sell calls, or predict outcomes.
THE IDEA
At the 09:30 ET cash open a gap frequently forms between the prior session's 16:15 ET RTH close and today's open. That gap often produces an early "judas swing": a first push off the open that raids liquidity, fails, and reverses back through the gap toward a gap-fill draw. This indicator frames that sequence with objective, repeatable levels and time windows so the read is consistent from day to day.
WHAT IT DRAWS
- RTH Open (True Day Open) line, annotated with the day's gap size and direction.
- Opening-gap retracement levels at 25%, 50% (the primary draw, emphasised), 75%, and 100% (full fill = the prior RTH close).
- Shading of the 09:30-10:00 gap-fill window and a 10:00 checkpoint line.
- Opening Range high and low (first N minutes of RTH; default 30).
- Liquidity Sweep flag when the opening-range extreme is taken and price closes back inside (the manipulation leg).
- SMT divergence flag against two correlated index futures (default YM and ES), pivot-based. Each flag names which comparison index diverged (e.g. "SMT - YM"), so a one-sided divergence is distinguishable from both indices disagreeing.
- An info panel showing gap size, live gap-fill percentage, a countdown to the RTH close, the day's directional bias, and which SMT comparison symbols are in play.
- Right-margin labels that sit within a configurable ATR distance of each other are merged into one line of text instead of overlapping illegibly.
HOW IT WORKS
Session handling uses the exchange clock in the America/New_York timezone, so it is daylight-saving safe with no fixed offset. The gap is measured from the prior RTH session's 16:15 ET futures close to the current 09:30 ET open; the electronic/Globex 17:00 ET close is intentionally not used. Directional bias is derived from gap direction: a gap up frames a bearish fade toward the fill, a gap down frames a bullish fade. The Sweep and SMT modules only evaluate on days whose gap is at or above a configurable minimum. The minimum can be expressed as a multiple of the previous day's ATR (the default, 0.15, so the threshold scales with each instrument's own volatility), as a percentage of price, or in raw points. Both modules arm only after the opening range locks (SMT pivot history is still tracked through the range, so the first pivot after the lock has a same-session reference; an input allows SMT inside the range). By default an SMT flag requires BOTH comparison symbols to fail to confirm the chart's pivot; an input relaxes this to either one. A comparison symbol that tracks the same index as the chart cannot diverge from it, so that leg is automatically excluded and the info panel reports which symbols remain active. Line and label activity (extension and new Sweep/SMT detection) stops at a configurable cutoff (default 11:30 ET) and resumes automatically at the next session's open; the info panel is unaffected and keeps updating through the close. All detection is evaluated on bar close (barstate.isconfirmed) to avoid repainting, and prior-day drawings are removed at the 16:15 ET boundary so nothing carries into the next session.
HOW TO USE IT
Apply to CME equity-index futures (for example MNQ/NQ, MES/ES, MYM/YM) on an intraday execution timeframe such as 1-5 minute. Read the levels as context: the gap-fill levels are potential draws, the opening range and its sweep mark the manipulation leg, and the SMT flag marks a confirming (or diverging) move in the correlated indices. The trader decides where and how to act — the script does not mark an entry. Every module, colour, time window, label size, and the SMT symbol pair are adjustable in the settings.
INPUTS
Grouped controls for session times, the gap minimum (ATR-relative, percent, or points) and which fib levels to show, opening-range length, timing references, and the Sweep / SMT modules (symbol pair, pivot length, both-or-either divergence, bias filter). Every drawn line and label has its own colour, line style, and label text, on top of global controls for the brand colours, line width, label size, right-margin offset, and info-table position.
NOTES
- This is an indicator, not a strategy: it does not generate orders, alerts to enter, or performance results.
- It evaluates conditions on closed bars and does not repaint.
- Descriptions of how gaps have tended to behave are informational, not predictive.
DISCLAIMER
This script is provided for educational and informational purposes only. It is not financial advice and is not a recommendation to buy or sell any instrument. Trading futures carries a substantial risk of loss. Past behaviour is not indicative of future results. You are solely responsible for your own trading decisions. Test thoroughly before relying on it in any live environment. Indicator

Session Seasonality Deviation [MarkitTick]💡 A highly advanced analytical framework meticulously engineered to quantify, measure, and visualize volatility anomalies within specific, localized trading windows. By programmatically isolating price action strictly to predefined market hours—such as the London or New York opens—this tool establishes an objective statistical baseline of expected market movement based exclusively on historical day-of-the-week performance data. Rather than relying on lagging continuous averages, this mathematical model detects the precise moment a market transitions from baseline activity into statistically significant expansion or compression, providing an objective lens through which to view true price dynamics.
● ✨ Originality and Utility
Traditional volatility metrics and bands typically analyze continuous price data streams, inadvertently blending distinct, structurally different trading periods into a single, homogenized moving average. This generalized approach inherently degrades the accuracy of volatility forecasting. The core utility of the SSD indicator lies in its targeted isolation of distinct market sessions, mathematically acknowledging the reality that a Tuesday London session behaves with entirely different liquidity parameters than a Friday New York session.
By creating an isolated historical distribution for each specific day of the week, this tool offers a highly accurate, predictive baseline for expected volatility that adapts to the calendar. Furthermore, the integration of structural price action filters ensures that these statistical anomalies are always correlated with actual market mechanics, elevating the tool beyond simple moving average bands and providing a robust, multidimensional analysis of market intent.
● 🔬 Methodology and Concepts
This script operates on a sophisticated confluence of statistical profiling and structural market analysis, creating an unyielding logic engine designed to filter market noise.
Time-Series Stratification: The underlying logic initiates by isolating raw price data exclusively within a user-defined temporal window. It captures the extreme upper and lower boundaries of this session, establishing the true operational range and discarding irrelevant data from inactive hours.
Day-of-Week (DOW) Seasonality Profiling: Rather than utilizing a generic rolling lookback of consecutive calendar days, the algorithmic engine stores and categorizes historical session ranges based on the specific day of the week. It builds an independent, localized statistical distribution for each day, calculating the mean average range and the variance of those specific historical instances.
Standardized Deviation (Z-Score) Engine: The primary mathematical trigger relies on a rigorous Z-Score calculation. It compares the current session's confirmed range against the historical DOW average, divided by the established standard deviation. This quantifies exactly how far the current volatility deviates from the empirical historical norm.
Structural Confluence and Market Character: To prevent the system from acting on anomalous volatility that lacks definitive directional intent, the logic engine requires a structural confirmation. It evaluates recent high and low boundaries, demanding that the closing price breaches these structural bounds to validate the statistical signal and confirm a genuine shift in market character.
● 🎨 Visual Guide
The visual interface is precision-engineered for rapid cognitive interpretation of complex statistical states, designed to relay critical data without cluttering the charting canvas.
Dynamic Heatmap Candles: The primary price action is overlaid with a responsive heatmap. Candlesticks are colored dynamically to reflect the internal bias of the active session, providing an immediate visual cue of the dominant buying or selling pressure.
Average Range Bounds: Subtle, non-intrusive bracketing lines are plotted symmetrically around the session open, projecting the historical average range. This creates a visual baseline for expected session expansion, allowing the user to see when price escapes the statistical norm.
Actionable Trade Levels: Upon the generation of a confirmed signal, the tool plots projected Entry, Stop Loss, and multiple Take Profit coordinates. Chart labels are meticulously configured to display raw value strings without percentage signs, ensuring a clean, distraction-free presentation of critical price levels.
Analytical Heads-Up Dashboard: A sophisticated data table is rendered on the chart, centralizing key real-time metrics. It details the active session, current directional bias, real-time Z-Score, Sample Size validity, and structural state. The dashboard is explicitly designed to display a matching, comprehensive evaluation of both long and short transaction outcomes, ensuring a perfectly balanced view of all potential market trajectories.
● 📖 How to Use
Interpreting the output of this tool requires a methodical, step-by-step approach, focusing heavily on the intersection of statistical deviation and structural shifts.
Monitor the on-chart dashboard for the Z-Score to definitively exceed the user-defined deviation threshold, which serves as the primary indicator of a statistically significant expansion in volatility.
Verify the directional bias of the current session using the Heatmap Candles and ensure this localized momentum aligns with the broader, macro market structure.
Wait for a confirmed structural breach signal that perfectly matches the directional bias of the initial statistical deviation, ensuring momentum is backed by actual price displacement.
Utilize the automatically plotted Trade Action Levels for strict risk management. The Stop Loss is dynamically calculated based on historical variance, and Take Profit levels offer scaled, mathematically logical target zones.
Exercise extreme caution and avoid executing signals during periods of severe price compression, or when the dashboard indicates that the sample size of historical data is insufficient to form a mathematically reliable statistical distribution.
● ⚙️ Inputs and Settings
The configuration panel is categorized logically to allow for the precise, modular tuning of both the statistical engine and the visual outputs.
Core Settings: Select the target session (Asia, London, New York) and define the lookback period for the seasonality model. Adjust the precise Deviation Threshold (Z-Score limit) to control the strictness and sensitivity of the generated signals.
Filters: Toggle specific confirmation layers, including the minimum required historical sample size, minimum expansion criteria, and specific structural requirements necessary to validate a move.
Trade Tools: Calibrate the multiplier values for the dynamically calculated Stop Loss and Take Profit levels, allowing the user to seamlessly align the tool with their individual risk parameters and payout models.
Visuals and Dashboard: Customize the display properties of the heatmap candles, the average range bands, and the spatial positioning of the analytical dashboard to suit personal workspace preferences.
● 🔍 Deconstruction of the Underlying Scientific and Academic Framework
The theoretical foundation of this analytical tool is deeply rooted in advanced Quantitative Finance, specifically drawing upon the established principles of Volatility Clustering and the Day-of-the-Week Anomaly. Academic literature frequently notes that financial markets exhibit leptokurtic distributions, wherein volatility is not a constant force but rather clusters densely in specific, predictable temporal windows. By employing a variance measurement technique akin to Standardized Moments, the script effectively normalizes session volatility.
This process allows the underlying algorithm to objectively classify current price action relative to an empirical baseline, entirely removing subjective human bias from the equation. Furthermore, the integration of structural pivot analysis introduces a deterministic filter to an otherwise probabilistic model. This synthesis ensures that statistical outliers are only deemed actionable when they are accompanied by a verifiable, measurable shift in the underlying supply and demand equilibrium.
⚠️ 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. Indicator

Indicator

ICT Everything Pro @SafarTradesICT Everything Pro
ICT Everything Pro consolidates multiple ICT time-based references into a single configurable indicator, allowing traders to monitor sessions, opening prices, key time markers, and higher timeframe reference levels without cluttering the chart or switching between multiple scripts.
Designed for intraday traders, the indicator centralizes the market timing concepts commonly used within the ICT methodology while providing extensive customization to match individual workflows.
Sessions
Display and customize the major trading sessions including Asia, London, AM, PM, London Close, and New York Lunch. Sessions can be displayed individually, highlighted using different styles, and limited to the current day or current week depending on your workflow.
CBDR, Asia & FLOUT
Visualize ICT session ranges including CBDR, Asia, and FLOUT. Each range supports independent visibility, colors, labels, and session definitions.
Time Markers
Display important ICT reference times using customizable vertical markers, including:
Midnight
London Open
New York Open
Equities Open
Each marker supports independent color, style, and width settings.
Opening Price Levels
Project important opening prices directly onto the chart, including:
Midnight Open
New York Open
Equities Open
Afternoon Open
RTH Open
Daily 50% Level
Each level supports customizable extensions, labels, colors, styles, and visibility.
Higher Timeframe Opening Levels
Optionally display Weekly and Monthly opening prices to maintain higher timeframe context while executing on lower timeframes.
Labels
Display day-of-week labels and a customizable chart label to improve chart organization and quickly identify trading sessions.
Customization
Every module can be configured independently, including:
Timezone selection
Session visibility
Session styles
Opening price extensions
Vertical line styling
Colors and labels
Historical display options
Higher timeframe opening levels
Intended Use
ICT Everything Pro is designed for traders who want a centralized ICT workspace without relying on multiple individual indicators. By combining session visualization, opening prices, higher timeframe references, and key time markers into a single configurable tool, it provides a cleaner and more efficient environment for market analysis and execution. Indicator

Indicator

1st Presented Fvg's [M1D]OVERVIEW
1st Presented Fvg's (M1D) isolates the very first Fair Value Gap each hourly window prints —
the one everything else in that hour reacts to — and tracks its full lifecycle: does it
hold, does it fail, does it invert, and does the inversion validate on a retest. Instead of
marking every FVG on the chart, it keeps only the one gap the model cares about per hour and
reports what happened to it.
It is a single-timeframe, event-tracking tool rather than a signal generator. It tags one
gap per hourly window, runs a strict hold / fail / invert / validate state machine on it, and
rolls a running Hold %, Inverted count and Valid IFVG count into a small dashboard so you can
see how the current session is actually behaving.
Detection and every state transition evaluate on confirmed bars only — nothing is decided
intrabar, and the chart requires an intraday timeframe of 60 minutes or less.
WHAT IT PLOTS
- 1st Presented FVG zone — a coloured box drawn from the exact three-candle gap, labelled
with its hourly window (e.g. "1st - 2pm") and an optional macro-window time suffix (e.g.
"1st - 2pm 1:50-2:10"). Zone colour cycles through your chosen palette by hour.
- NY Open tag — inside the 9:30-10:00 NY session specifically, the gap is labelled "1st -
NY Open" instead of the generic hour label, and only appears once price has swept a recent
pivot high or low first (see Key Definitions below).
- Inversion (IFVG) tag — a gap that held, then closed through, turns orange and is
relabelled IFVG.
- Valid IFVG tag (✔) — once an inverted gap is retested (price trades back into it), it
gains a check mark and a brighter fill, so a live, usable IFVG stands out from one still
forming.
- Failed gap (optional) — a gap that closed through without ever holding can be kept on
chart dimmed for context, or deleted outright; either way it is counted in the stats.
- Dashboard (M1D) — a small monospace table showing the current session, current time, and
a Today vs. Total read of gaps tagged, gaps held, Hold %, gaps inverted, and validated
IFVGs.
KEY DEFINITIONS
- Held — the point at which a 1st Presented FVG is considered to have defended its zone,
rather than just being tagged. Governed by the Hold Definition setting below.
- Reject & Close Away (default Hold Definition) — price must trade into the gap and then
close back outside its proximal edge before it counts as held. A tap that closes through
without that rejection is scored as a fail, not a hold — so Hold % reflects confirmed
rejections, not every incidental touch.
- Touch & Hold (alternate Hold Definition) — any trade into the gap that doesn't close
through it counts as held immediately, no rejection required.
- Inversion (IFVG) — a gap that held first, then later closed through it. This sequence is
mandatory: a gap that runs straight through without ever holding is a fail, never an
inversion.
- Valid IFVG — an inverted gap that price has subsequently traded back into.
- Hold % — held gaps ÷ gaps tagged, shown separately for Today and All-Time.
- NY Open liquidity sweep — inside the 9:30-10:00 New York session, the 1st Presented tag
runs on its own daily slot, separate from the normal hourly one, so an earlier random gap
in the same clock hour can't use up the slot before the open range even happens. That slot
only fills once price has swept a recent confirmed swing pivot — a low for a bullish gap,
a high for a bearish gap — immediately before the gap forms, so the tag reflects a genuine
liquidity grab rather than the first random three-candle gap after 9:30.
HOW TO USE IT
Reading the state of the current gap
- A live-coloured zone with no orange means the 1st Presented FVG is still fresh or holding
— treat it as an active zone.
- Orange means it has inverted — price closed through it after holding, so it now has the
opposite role.
- Orange with a ✔ means the inversion has been retested and validated — the strongest read
of the three, since price has both flipped the gap and come back to confirm it.
- A dimmed zone (if you keep failed gaps) means it closed through without ever holding —
context only, not a level to lean on.
Reading the dashboard
- Hold % (Today vs. All-Time) tells you how respected first-hour gaps have been — a low
reading suggests today's imbalances are being run through rather than defended.
- Inverted vs. Valid IFVG counts show how often a failed gap actually resolves into a
confirmed continuation level (✔) rather than just failing outright.
- Session tells you which killzone you're in without leaving the chart.
Choosing your settings
- Use Reject & Close Away when you only want gaps that show a confirmed rejection —
Touch & Hold is looser and counts the first touch, useful for comparing how often price
even reaches the gap versus how often it truly holds.
- Switch Mode to First Of Each Direction if you want to track a bullish and a bearish 1st
gap side-by-side within the same hour, instead of only the first of either.
- Turn on the Displacement Filter if you want the tag to skip small, low-conviction gaps in
favour of the next one that clears your ATR multiple.
- Leave NY Open: Require Liquidity Sweep on if you specifically want the opening-range gap
isolated from the generic hourly noise; adjust Pivot Lookback to make the swing-pivot
reference tighter (fewer bars, more sensitive) or wider (more bars, more established swings).
SETTINGS
- Detection — 1st FVG Mode (First Of Either / First Of Each Direction), Hourly Window
Timezone, Displacement Filter (ATR × multiple), Restrict To Time Window, NY Open (9:30-
10:00): Require Liquidity Sweep, Pivot Lookback.
- Inversion (IFVG) — Track Inversions toggle, Hold Definition (Touch & Hold / Reject &
Close Away).
- Labels — Show Labels, Label Text prefix, Show Macro Window Time, Label Size, Label
Colour.
- Colours — Colours In Cycle (2 or 3), the cycle colours, Inversion Colour, Zone
Transparency.
- Display — Gap Lifetime (Until Invalidated / End Of Hour / End Of Day), Keep Failed Gaps
(Dimmed), Max Gaps On Chart.
- Stats Table — Show Stats Table, Position, Text Size.
This is a decision-support and context tool for discretionary ICT trading. It does not
generate buy or sell signals and does not place trades. This is not financial advice, and no
market's past behaviour is indicative of future results.
Indicator

XI0033 Williams FractalA Williams fractal confirms late by definition: the pattern is complete only after the bars to its right have closed, so the marker always appears in the past. This script keeps the classic fractal template — three- or five-bar — and adds the one thing the classic version cannot show: the bar that is about to become a fractal, before the confirmation arrives.
It draws triangles for confirmed fractal highs and lows, plus one highlighted triangle for the last potential fractal on the live edge. Nothing else: no lines, no levels, no signals.
Confirmed fractals
A fractal high is a bar whose high stands above the highs of its neighbours; a fractal low mirrors that on the lows. The 3-bar mode compares one neighbour on each side, the 5-bar mode two on each side — the original Bill Williams definition. The Periods input sets how many bars back the reference bar sits. Confirmed fractals are painted as muted grey triangles above the highs and below the lows, and once the pattern that produced them is closed, they are history: they do not move and do not disappear.
Confirmed fractal highs and lows in the muted default colour: every triangle marks a bar whose extreme beat its neighbours on both sides, printed only after the pattern completed.
The last potential fractal
This is the addition. One bar to the right of the last confirmable centre there is always a candidate: a bar already higher (or lower) than its closed neighbours, waiting only for the current bar to keep its distance. The script highlights that candidate with an orange triangle — pointing down above a potential high, pointing up below a potential low — so the developing swing is visible before it becomes official.
The highlight exists only on the live bar. It is recalculated tick by tick, disappears the moment price violates the candidate, and is deliberately dropped on the bar's final update, so it never leaves a trace in the chart history. Scroll back and you will find only confirmed fractals.
Left: the orange triangle under the newest low is the last potential fractal. Right, a few bars later: that low now carries a grey confirmed triangle — the preview left no trace — and a new potential fractal already sits above the latest high.
What repaints, and what does not
The potential marker repaints by design — that is its job. It is a live preview that appears, moves and vanishes with the current bar, and it is intentionally not committed to history. Confirmed fractals in the default 3-bar mode are built from closed bars only, so once a triangle prints, it is final. In the 5-bar mode with the default period, the newest confirmation still involves the forming bar's extreme, so it can appear and be withdrawn until that bar closes; after the close it is final. And every confirmed fractal is late by definition — the triangle appears above a bar that is already in the past, because that is what confirmation means.
What is reused, and what is new
The confirmed-fractal logic is the classic Bill Williams fractal template as coded by Mit Nayi, reused open-source with attribution in the source header. What this edit adds: the port to Pine Script v6, and the whole potential-fractal layer — the candidate detection one bar to the right of the confirmable centre, and the barstate mechanism that shows the preview on the live bar only and drops it on the bar's final update, so it never piles up in history.
What it does not do
It gives no signals. A fractal marks a local extreme, and most local extremes get traded through; on their own they are not entries. This is a structural marker — swing logic, liquidity maps and ICT-style analysis use fractals as raw material, and the potential marker only tells you where the next one may appear. The decision stays yours.
The Inputs allow you to set:
Periods: how many bars back the fractal centre sits; the triangles are drawn on that centre bar
3 or 5 Bar Fractal: one or two neighbours compared on each side
Show last potential fractal: the live-edge preview on or off
Potential down and up fractal colours
About the chart
BYBIT:BTCUSDT.P, 5-minute chart. The only script on it is this one, with default settings: muted grey triangles mark confirmed fractal highs and lows across the chart, and the orange triangle at the right edge is the last potential fractal, not yet confirmed. No other indicators, no drawings. Indicator

Indicator

Fractal Timeframe Collision Node [MarkitTick]💡 The financial markets operate across multiple interacting timeframes, creating complex structural geometries that cannot be accurately analyzed through a single, isolated lens. The tool presented here acts as a comprehensive multi-timeframe aggregation engine, designed to isolate highly significant structural support and resistance clusters. By evaluating pivot points across four distinct time spans and merging them based on volatility-adjusted proximity, this system identifies high-probability reaction zones where structural exhaustion is most likely to occur. It is built strictly for the modern Pine Script environment, utilizing an entirely non-repainting architecture that respects the highest standards of data integrity and execution logic.
● ✨ Originality and Utility
Standard pivot or support/resistance scripts typically plot historical swing highs and lows independently. This creates chart clutter and often leaves the analyst guessing which level holds the most technical weight. This tool introduces the concept of "Collision Nodes." Instead of simply drawing every pivot, the algorithm scans higher timeframe data, identifies structural extremes, and clusters them together using a dynamic, adaptive mechanism.
When multiple higher timeframes project a pivot at the exact same price zone, a structural "Collision Node" is formed.
The utility lies in its objective strength grading: a node formed by the confluence of the 1-hour, 4-hour, and Daily charts mathematically demands more respect than a single localized swing point on a lower timeframe.
By filtering out the noise and only projecting nodes that meet a user-defined minimum strength threshold, the analyst is presented with a remarkably clean chart displaying only the most critical, high-liquidity zones.
Furthermore, the script automatically generates full trade execution parameters (Entry, Stop Loss, and multiple Take Profits) directly on the chart when a valid structural rejection occurs.
● 🔬 Methodology and Concepts
• Multi-Timeframe Pivot Extraction
The core engine relies on detecting localized extrema (Pivot Highs and Pivot Lows) over a user-defined lookback window. The script fetches these pivot values simultaneously from three higher timeframes plus the current chart's timeframe. To ensure absolute data integrity and prevent any future data leakage (repainting), the algorithm strictly requests historical, confirmed data using offset historical referencing.
• Volatility-Normalized Spatial Clustering
Once the pivots are extracted, the algorithm must determine if they "collide" or overlap. Because absolute price distance is irrelevant across different assets, the script uses a dynamic clustering mechanism normalized by the Average True Range (ATR).
A tolerance band is calculated by multiplying the current ATR by a user-defined coefficient.
If a newly discovered higher timeframe pivot falls within this exact tolerance band of an existing pivot cluster, it is merged into that cluster, and the cluster's "strength" rating is incremented.
If it falls outside the tolerance band, a new independent node is registered.
• Memory Management and Age Pruning
Financial markets possess a memory, but structural relevance decays over time. The script incorporates a memory management protocol that continually monitors the age of all registered nodes. If a node has not been tested or updated within a specific bar count limit, it is automatically pruned from the active array, ensuring that only highly relevant, modern liquidity pools are analyzed.
• Automated Signal Validation
A visual node is not a signal; it is an area of interest. The script validates trade signals by combining spatial location with price action. A valid signal requires the price to close inside the tolerance zone of a high-strength node, accompanied by a rejection candle (where the wick constitutes a significant percentage of the total candle range), and a structural close confirming the directional bias.
● 🎨 Visual Guide
• Collision Nodes
Teal Horizontal Lines: Represent bullish support nodes. The opacity of the line dynamically shifts based on the strength of the node (darker/more solid lines indicate higher timeframe confluence).
Red Horizontal Lines: Represent bearish resistance nodes. Like the bullish nodes, their visibility scales with structural strength.
Diamond Labels (◆×2, ◆×3): Attached to the end of the node lines, these labels explicitly display the node's strength rating. A "◆×3" label means three separate timeframes have confirmed a pivot at this exact mathematical level.
• Trade Execution Box
Dashed Blue Line: Indicates the exact Entry price upon signal confirmation.
Solid Red Line: Represents the dynamic Stop Loss, which is placed behind the collision node with an added ATR-based buffer to avoid premature liquidation.
Dashed Teal Lines (TP1, TP2, TP3): Represent calculated Take Profit levels projected automatically based on the user's defined Risk-to-Reward (RR) multipliers.
Red Background Fill: Visually maps the total risk zone between the Entry and the Stop Loss.
Teal Background Fill: Visually maps the total reward zone extending from the Entry up to the final Take Profit target.
• Real-time Dashboard
Located by default in the top right corner, this data table provides an instant summary of the market structure.
Bias: Displays the current active signal direction (LONG, SHORT, or NONE).
Active Nodes & Strengths: Lists the exact price levels of the nearest active bull and bear nodes, accompanied by visual progress bars displaying their respective strengths (Green for high strength, Yellow for medium, Red for low).
Trade Tracking: Displays the currently active Stop Loss and primary Take Profit levels if a trade configuration is locked on the chart.
● 📖 How to Use
Apply the indicator to your chart and set your three preferred higher timeframes in the settings (e.g., if trading on the 15-minute chart, you might select 1-Hour, 4-Hour, and Daily).
Observe the chart for the formation of high-strength Collision Nodes (look for ◆×3 or ◆×4 labels). These are your primary zones of interest.
Wait for price action to approach these nodes. Do not place blind limit orders.
Allow the script's internal logic to identify a structural rejection. When a valid rejection candle forms and closes at a node, a trade execution box will automatically populate on the chart.
Use the provided Entry, Stop Loss, and Take Profit lines to format your position sizing and manage the trade according to the mapped risk-to-reward parameters.
Optionally, link the script's advanced JSON webhook alerts to an external execution platform for automated trade routing.
● ⚙️ Inputs and Settings
• Core Settings
Pivot Lookback: The structural length required to confirm a swing high or low.
TF 1, TF 2, TF 3: The three higher timeframes used to scan for structural confluence.
Include Chart TF: Determines if the current chart's timeframe should also contribute to node strength.
Node Tolerance (×ATR): The spatial bandwidth used to cluster pivots together, measured as a multiplier of current volatility.
Min Node Strength: The minimum number of overlapping timeframes required for a node to be rendered on the chart.
• Filters
Require Rejection Candle: Enforces strict price action criteria, demanding that signals only fire if the candle displays a prominent rejection wick.
Min Wick % of Range: The exact percentage of the candle that must be composed of the wick to validate a rejection.
Max Node Age (bars): The duration a node remains active without being re-tested before being permanently purged from memory.
• Trade Tools
SL Buffer (×ATR): Adds a dynamic volatility buffer beyond the structural node to determine the absolute invalidation point.
TP1, TP2, TP3 (×SL Risk): The respective risk-to-reward multipliers used to dynamically project profit targets.
Lock Current Trade Levels: Freezes the visual risk/reward box on the chart until the trade hits either the final target or the stop loss, ignoring subsequent signals.
• Dashboard & Alerts
Show Dashboard: Toggles the visibility of the real-time data table.
Alert Actions: Customizable text fields allowing users to define specific JSON payload strings for long, short, and exit triggers.
● 🔍 Deconstruction of the Underlying Scientific and Academic Framework
The architectural foundation of this algorithm is heavily rooted in the Fractal Market Hypothesis (FMH), which posits that financial markets exhibit self-similar statistical structures across varying scales of time. In practical terms, a distribution pattern on a 5-minute chart mathematically resembles a distribution pattern on a Weekly chart. By aggregating pivot extrema from multiple independent time scales, this script exploits these fractal geometries to identify areas of harmonic resonance—price zones where liquidity pools overlap across different cohorts of market participants.
To resolve the spatial clustering problem, the system utilizes a volatility-normalized one-dimensional grouping algorithm conceptually akin to Density-Based Spatial Clustering of Applications with Noise (DBSCAN). Instead of utilizing fixed scalar distances (which fail as asset prices scale), the algorithm calculates an epsilon distance bounded by the Average True Range (ATR). This ensures that the clustering logic expands and contracts organically with market entropy. The ultimate output is a mathematically objective reduction of structural noise, isolating only the highest-density liquidity nodes that possess the greatest statistical probability of halting directional momentum.
⚠️ 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. Indicator

EQH/EQL Liquidity Sweep | AlphaScript⚖️ EQH/EQL Liquidity Sweep
Detects clusters of equal highs (EQH) and equal lows (EQL) the resting-liquidity pools that price hunts and tracks exactly what happens to each one: swept, broken, or still active. Then it measures the real sweep rate so you can see your actual edge.
🎯 Why equal highs and lows matter
When price makes a high, pulls back, then makes another high at the same level, stops pile up just beyond that level — breakout orders, protective stops, resting liquidity.
The more times price taps the same level, the more orders accumulate there. Those pools are what larger participants hunt. This tool maps them automatically and then tells you whether each pool got raided or genuinely failed.
🔍 How pools form
The indicator finds swing highs and lows, then groups any that sit within a configurable tolerance of each other into a single pool.
A pool needs at least a minimum number of touches (default 2) to display. The pool line is drawn at the extreme of the cluster — the highest of the equal highs, or lowest of the equal lows — because that is where the stops actually rest. A small × marks each individual swing that built the pool, and the line thickness and badge show the touch count.
Each pool resolves in one of these ways:
⚡ SWEPT — price wicks through the pool extreme but the bar closes back on the original side. Stops were taken, but the level held on a closing basis. A liquidity raid.
💥 BROKEN — a bar closes through the pool extreme. The level genuinely failed — continuation, not a raid. Breaks are shown separately and never labeled as sweeps.
🛡️ Active — the pool has neither been swept nor broken and is still in play. Pools that go too long without resolving expire and are removed.
First qualifying event wins: one outcome per pool. If a bar both wicks through and closes through, it counts as a break — a close through the level can never be a sweep.
📊 Sweep-rate table | know your real edge
This is what separates the tool from every other equal-highs indicator: instead of just drawing levels, it measures what actually happens to them. The table breaks down every resolved pool by touch count (2 / 3 / 4+) and shows the real sweep and break percentages for each group — computed live from your own instrument, timeframe, and history.
That means you can answer the question that matters before taking a trade: do the pools you're watching actually get swept, or do they break? If 3-touch pools on your instrument sweep far more often than they break, that's a measured edge you can trade around. If 2-touch pools are a coin flip, you know to demand more confluence. The numbers come from the chart, not from a claim on a marketing page.
Only fully resolved pools are counted, active pools are excluded, so the rates can never be inflated by in-progress levels. The denominator is honest: what you see is what actually happened.
⚙️ Settings
-Swing lookback, and equal tolerance in ATR multiples (instrument-independent) or fixed ticks.
-Minimum touches to form a pool, maximum pool age, and how many active pools to track per side.
-Optional minimum wick penetration (ATR-based) to filter marginal sweeps. Does not apply to breaks.
-Optional "Strict Virgin Liquidity" mode: discards a forming level if price closes decisively beyond it before a second touch, so only levels that were never truly broken can pair. Off by default.
-Full display control: pool zones, touch badges, × touch markers, colors, line styles and widths, and how many resolved pools remain on the chart.
-Sweep-rate table with position options.
🔔 Alerts
Per-side sweep alerts (EQH and EQL), separate break alerts, and a combined "Any Pool Swept" alert. All alerts fire on the close of the event bar.
📌 Notes and limitations
-Designed for intraday and swing timeframes. Very low timeframes produce many small pools; adjust tolerance and swing lookback to suit.
-Detection uses standard swing pivots. A peak whose neighboring bar wicks slightly higher may not register as a separate pivot, so not every visual high becomes a pool — tune the swing lookback and tolerance to match how you read structure.
-The equal tolerance is the single most important setting. Too tight and genuine equal levels are missed; too loose and unrelated highs merge. Start moderate and adjust to your instrument.
-The sweep-rate table describes the pools on your loaded chart history. It is a measurement of what happened, not a prediction of what the next pool will do.
✅ Why no repaint
-Pivots are confirmed only after the swing lookback completes, and all pool detection runs on closed bars only. A sweep or break tag will never appear intrabar and then vanish.
-A pool is only evaluated for sweep or break once it has fully formed. A level still building cannot be resolved.
-No request.security() calls are used anywhere. All detection is chart-timeframe state. Indicator

CandelaCharts - MTF FVG Alignment📝 Overview
The CandelaCharts - MTF FVG Alignment indicator detects Fair Value Gaps (FVGs) across up to four customizable timeframes and visualises them directly on the chart. A Fair Value Gap is a three-candle pattern where price moved so rapidly that an unfilled area remains between the high of the first candle and the low of the third candle, representing a price imbalance the market often returns to fill.
The core strength of this indicator is Confluence . An alignment signal is generated only when every enabled timeframe shows FVGs in the same direction (all Bullish or all Bearish), giving traders a powerful multi-timeframe confirmation before taking a position.
📦 Features
Four-Timeframe Analysis : Track up to four independent timeframes simultaneously with per-TF toggle and FVG count.
Confluence Alignment : Automatic detection of Bullish or Bearish alignment across all enabled timeframes.
Bias Filter : Filter displayed FVGs to show only Bullish, only Bearish, or both (Neutral).
FVG Mitigation : FVGs are automatically invalidated and removed from the chart once they are fully filled by price action.
Hide Overlapped : Clean up chart clutter by automatically hiding lower-timeframe or older FVGs that overlap with others.
Fibonacci Levels : Optional Fibonacci retracement levels (0.236, 0.382, 0.5, 0.618, 0.65, 0.705, 0.786) drawn inside each FVG with a highlighted Golden Pocket zone (0.705–0.786).
FVG Visuals : Semi-transparent boxes showing active FVGs for each timeframe, with configurable borders and midlines.
Status Dashboard : A clean table showing the current directional status (Bullish / Bearish / None) for each enabled timeframe.
⚙️ Settings
Timeframes
TF 1–4: Each timeframe row has a toggle (show/hide), a timeframe selector, and an FVG count (1–10) controlling how many recent FVGs are displayed for that timeframe. Defaults are 1D, 4H, 1H, and 15m.
Settings
Bias Filter: Filter displayed FVGs by direction — Neutral (show all), Bullish (show only bullish FVGs), or Bearish (show only bearish FVGs).
Bull / Bear Colors: Customise the colours used for bullish and bearish FVG zones.
Border: Toggle the FVG box border and configure its style (Solid, Dotted, Dashed) and width (1–5).
Midline: Toggle the Consequent Encroachment midline inside each FVG and configure its style and width. When enabled, the timeframe label moves outside the box.
Fibonacci: Toggle the drawing of Fibonacci retracement levels inside each FVG, including the highlighted Golden Pocket (0.705–0.786).
Hide Overlapped: Toggle whether to hide overlapping FVGs across different timeframes to keep the chart clean (prioritising higher timeframes).
Dashboard
Show: Toggle the multi-timeframe status dashboard.
Position: Choose the dashboard corner — Top Right, Top Left, Bottom Right, or Bottom Left.
⚡️ Showcase
Multi-Timeframe FVG Boxes
Fibonacci Levels & Golden Pocket
Status Dashboard
🔎 Usage
Trend Identification : Glance at the dashboard to see the current bias of each higher timeframe at a glance.
Confluence : When all enabled timeframes align in the same direction, it provides strong multi-timeframe confluence for a directional trade.
Fibonacci Entries : Use the Fibonacci levels inside each FVG — particularly the Golden Pocket (0.705–0.786) — for precise entries when price retraces into the gap.
Bias Filtering : Set the Bias Filter to Bullish or Bearish to remove counter-trend FVGs and keep the chart focused on your directional thesis.
Execution : Use the alignment as confirmation for your existing strategy. Bullish alignment suggests upward momentum; Bearish alignment suggests downward momentum.
⚠️ Disclaimer
Trading involves significant risk, and many participants may incur losses. The content on this site is not intended as financial advice and should not be interpreted as such. Decisions to buy, sell, hold, or trade securities, commodities, or other financial instruments carry inherent risks and are best made with guidance from qualified financial professionals. Past performance is not indicative of future results.
Indicator

Liquidity Sweep & Golden Zone [StrixEDGE]Overview
Liquidity Sweep & Golden Zone is a multi-timeframe structural analysis tool built for traders who use Smart Money Concepts (SMC) and ICT methodology. It identifies liquidity sweeps at confirmed swing levels, maps the Fibonacci Golden Zone (OTE), and presents a real-time confluence dashboard across 15-minute, 1-hour, 4-hour, and daily timeframes.
The indicator answers three questions at a glance: where is the liquidity?, has it been swept?, and do multiple timeframes agree on direction?
How It Works
Liquidity Sweep Detection
The engine tracks confirmed swing highs and swing lows using pivot detection. These pivots represent resting liquidity pools — areas where stop-loss orders accumulate:
- Buy-Side Liquidity (BSL) sits above swing highs, where short sellers place their stops. When price wicks above a swing high and closes back below, a BSL sweep is triggered — signaling that buy-side stops were hunted. This typically precedes bearish continuation.
- Sell-Side Liquidity (SSL) sits below swing lows, where long traders place their stops. When price wicks below a swing low and closes back above, an SSL sweep is triggered — signaling that sell-side stops were hunted. This typically precedes bullish reversal.
Each sweep event displays the estimated volume in USDT at the moment of the sweep. This is calculated as `volume × close` on the sweep bar and serves as a proxy for the magnitude of liquidations that occurred. Higher volume sweeps tend to produce stronger reversals.
After a sweep, the level is updated to the new extreme — preventing duplicate signals and establishing a fresh liquidity reference.
Support & Resistance (Pivot-Based)
Active (un-swept) pivot levels are drawn on the chart as structural Support and Resistance:
- A line extending from the bar where the pivot formed to the current price area
- A zone band (ATR × 0.15) around the level, representing the area of influence
- Origin labels showing "Buy-Side Liquidity SWEEP" or "Sell-Side Liquidity SWEEP" with the USDT volume
- Price labels on the right edge for quick reference
These levels update dynamically: when a new pivot is confirmed, the line starts from the new origin. When a sweep occurs, the level shifts to the sweep bar.
Golden Zone (Fibonacci OTE: 0.618 – 0.786)
The Golden Zone represents the Optimal Trade Entry area — the 61.8% to 78.6% Fibonacci retracement of the most recent price range. Unlike pivot-based calculations, this indicator uses a **lookback-based approach**: it finds the highest high and lowest low over a configurable number of bars, then derives the zone from that range.
The zone is visualized with:
- A filled box between the 0.618 and 0.786 levels (transparency adjustable)
- Dashed border lines at 0.618 and 0.786
- A dotted midline at the 0.702 level
- Price labels showing exact values
- A centered "GOLDEN ZONE" tag
This approach produces a stable, always-visible zone that doesn't depend on individual pivot detection, making it reliable across all market conditions.
Multi-Timeframe Heatmap
The core of this indicator is a 7-column heatmap table that evaluates market conditions across four timeframes simultaneously:
| Column | What It Shows | Bullish | Bearish |
|--------|--------------|---------|---------|
| SWEEP | Recent liquidity sweep direction | ● BULL (SSL swept) | ● BEAR (BSL swept) |
| GZ | Price position relative to Golden Zone | ▲ ABOVE | ▼ BELOW |
| S/R | Price position vs. pivot S/R midpoint | ▲ BULLISH | ▼ BEARISH |
| BIAS | EMA 21/50 trend direction | ▲ BULL | ▼ BEAR |
| RSI | RSI(14) value with decimal precision | Color-coded by zone | Color-coded by zone |
| SIGNAL | Composite of all conditions | LONG ▲ | SHORT ▼ |
Signal Logic: The SIGNAL column counts four conditions per timeframe — RSI above/below 50, price in/above the Golden Zone, price above/below the S/R midpoint, and EMA bias direction. When 3 or more conditions align bullish, the signal reads LONG. When 3 or more align bearish, it reads SHORT. Otherwise, NEUTRAL.
A confluence bar at the bottom aggregates all timeframes. When the majority of conditions across all four timeframes agree, it displays STRONG BULLISH or STRONG BEARISH CONFLUENCE.
RSI Color Coding
| RSI Range | Color | Meaning |
|-----------|-------|---------|
| > 70 | Orange | Overbought |
| 50 – 70 | Green | Bullish momentum |
| 30 – 50 | Red | Bearish momentum |
| < 30 | Blue | Oversold |
Settings
Structure Settings
| Setting | Default | Description |
|---------|---------|-------------|
| Pivot Lookback Length | 5 | Bars left and right to confirm a swing pivot. Higher values produce fewer but stronger levels |
| Sweep Active Memory | 10 | How many bars a sweep signal remains active on the heatmap after detection |
Golden Zone
| Setting | Default | Description |
|---------|---------|-------------|
| Lookback Period | 20 | Number of bars to find highest high and lowest low for Fibonacci calculation |
| Show Golden Zone | On | Toggle zone visibility on chart |
| Fill Golden Zone | On | Shade the area between 0.618 and 0.786 |
| Fill Transparency | 88 | Opacity of the filled zone (50–98) |
| Golden Zone Color | Gold | Color for all Golden Zone elements |
Support & Resistance
| Setting | Default | Description |
|---------|---------|-------------|
| Show S/R on Chart | On | Toggle S/R lines, zone bands, and labels |
| Support Color | Teal | Color for support level and SSL elements |
| Resistance Color | Red | Color for resistance level and BSL elements |
| Line Width | 2 | Thickness of S/R lines (1–4) |
| Line Style | Solid | Solid, Dashed, or Dotted |
| Show Price Labels | On | Display price values at the right edge of each level |
Sweep Event Labels
| Setting | Default | Description |
|---------|---------|-------------|
| Show Sweep Labels | On | Toggle sweep event markers on chart |
| Bullish Sweep Color | Green | Color for SSL sweep labels (bullish reversal) |
| Bearish Sweep Color | Red | Color for BSL sweep labels (bearish reversal) |
Heatmap Table
| Setting | Default | Description |
|---------|---------|-------------|
| Show Heatmap Table | On | Toggle the entire dashboard |
| Table Position | Top Right | 9 position options across the chart |
| Table Cell Size | Normal | Tiny, Small, Normal, Large, or Auto |
Alerts
Five alert conditions are built in and ready to use:
1. Bullish Liquidity Sweep — SSL swept, potential bullish reversal
2. Bearish Liquidity Sweep — BSL swept, potential bearish reversal
3. Bull Sweep + Golden Zone — SSL swept while price is inside the OTE zone (high-probability long)
4. Bear Sweep + Golden Zone — BSL swept while price is inside the OTE zone (high-probability short)
5. Price in Golden Zone — Price enters the 0.618–0.786 zone on any bar
Disclaimer
This indicator is a technical analysis tool designed to assist in identifying potential areas of interest based on market structure and liquidity concepts. It does not constitute financial advice. The USDT volume figures are approximations, not verified liquidation data. Always use proper risk management and combine this tool with your own analysis. Past performance of any signal or pattern does not guarantee future results. Trade at your own risk. Indicator
