Smart Money Fibonacci OTE Engine [ChartPrime]🔶 OVERVIEW
In the world of Smart Money Concepts (SMC), finding a "cheap" or "expensive" price is not enough—you need to find the Optimal Trade Entry (OTE). The Smart Money Fibonacci OTE Engine is an automated structural analysis tool that identifies trend shifts and projects institutional retracement zones in real-time.
Unlike traditional Fibonacci tools that require manual drawing, this engine detects Break of Structure (BOS) events and automatically anchors a Fibonacci grid to the most relevant swing points. It specifically highlights the OTE zone, where institutional buying or selling typically occurs after a trend confirmation.
🔶 CORE MECHANICS: AUTOMATED ANCHORING
The engine operates on a sophisticated "Pivot and Shift" logic:
Swing Detection: The script monitors price for structural Swing Highs and Swing Lows based on your chosen pivot length.
Fibonacci Direction Shift Recognition: A direction shift is confirmed when pivot price exceeds the previous Swing Pivot High (Higher High), and a down direction shift is confirmed when price drops below the previous Swing Pivot Low (Lower Low).
Dynamic Stretching: Once a direction is established, the Fibonacci grid "breathes" with the market. If the trend continues to make new highs or lows, the grid automatically stretches to include the new extension, ensuring your retracement levels are always mathematically accurate.
🔶 THE OPTIMAL TRADE ENTRY (OTE) ZONE
The OTE zone is the primary focus of this indicator. Based on ICT (Inner Circle Trader) concepts, the OTE represents the "sweet spot" of a retracement.
The Range: By default, the zone is plotted between the 0.618 and 0.786 Fibonacci levels.
Institutional Discount/Premium: In a bullish trend, price retreating into the OTE zone is considered "buying at a discount." In a bearish trend, a rally into the OTE is "selling at a premium."
Visual Clarity: The zone is highlighted with a colored box (teal for bull, red for bear), making it easy to identify exactly where to look for price action reversal signals.
🔶 KEY VISUAL FEATURES
Structure Labels: Automatically marks HH (Higher High) and LL (Lower Low) points with Break-of-Structure (BOS) lines.
Swing Diagonal: A dotted line connects the two anchor points of the Fibonacci grid, providing a clear visual representation of the current swing's slope and magnitude.
Extended Levels: Horizontal Fibonacci lines (0.236, 0.382, 0.5, etc.) are projected across the chart, with price-sensitive labels that update every tick.
Historical Mode: Toggle "Show Previous Fibs" to see where past OTE zones were respected, helping you backtest the current asset's adherence to Fibonacci levels.
🔶 INDICATOR INPUTS
Pivot Length: Adjust this to filter between micro-structure (short length) and macro-structure (long length).
OTE Upper/Lower Levels: Fully customizable boundaries for your entry zone.
Visual Styles: Change line styles (Solid, Dashed, Dotted) and colors for the grid, labels, and structure shifts to match your chart theme.
🔶 TRADING UTILITY
High-Probability Entries: Instead of "chasing" a breakout, wait for the Smart Money Fibonacci Engine to identify the higher high or lower low, then wait for price to return to the OTE box.
Confluence Tool: Use the OTE zone in conjunction with Order Blocks or Liquidity Sweeps. When an OTE zone aligns with a previously swept EQL or EQH, the probability of a reversal increases significantly.
Objective Profit Taking: Use the 0.0 (origin) and various extension levels as objective targets for scaling out of positions.
🔶 CONCLUSION
The Smart Money Fibonacci OTE Engine removes the subjectivity from drawing Fibonacci retracements. By automating the detection of market structure and highlighting the most statistically relevant entry zones, it allows traders to focus on execution rather than chart drawing. Indicateur

ATH/ATL Fibonacci Retracement - Labels, Golden Pocket & AlertsPlots Fibonacci retracement levels anchored to the all-time high and all-time low of the loaded chart history. The range updates automatically as new highs or lows print, so the levels always reflect the full extent of price action without manual redrawing.
Features:
- Auto ATH/ATL tracking — the 0% and 100% anchors update dynamically across all available history.
- Flip toggle — switch 0% between the top (all-time high) and the bottom (all-time low) to suit your bias or the direction of the move you're measuring.
- Standard Fib levels — 0%, 23.6%, 38.2%, 50%, 61.8%, 78.6%, and 100%, each color-coded.
- On-chart labels — every level shows its retracement percentage alongside the exact price, placed to the right of the last bar. Adjustable offset.
- Golden pocket shading — the 61.8%–78.6% reaction zone is highlighted for quick visual reference. Toggle on/off.
- Built-in alerts — alert conditions on crosses of each major level, plus a golden-pocket entry alert, ready to wire up from the Create Alert dialog.
Notes: Levels are based on the chart's loaded history, so the all-time high/low depends on how far back your data goes and your timeframe. This is an analysis tool, not financial advice — use it alongside your own process and risk management. Indicateur

All-Time High/Low Fibonacci Retracement (with Flip)Tired of manually dragging the Fibonacci tool across macro charts every time an asset makes a new high or low? This indicator automates the entire process. It scans the absolute historical data of any asset to identify its true All-Time High (ATH) and All-Time Low (ATL), then dynamically projects standard Fibonacci retracement levels between them.
Whether you are analyzing a stock's decades-long macro cycle or looking for major historical support and resistance levels, this script keeps your charts perfectly anchored without the manual clutter.
Key Features
100% Automated Tracking: Uses historical state variables (var) to lock onto the ultimate lowest and highest prices ever printed on your current chart.
Real-Time Dynamic Updates: If the asset breaks out into price discovery (new ATH) or capitulates to a new bottom (new ATL), the script recalculates and shifts all Fibonacci lines instantly.
One-Click Flip Toggle: Built-in calculation flip. Measure retracements from the top down (bearish retracement) or flip it from the bottom up (bullish expansion) right from the settings menu.
Clean Visuals: Hard-coded with classic Fibonacci ratios (23.6%, 38.2%, 50.0%, 61.8%, 78.6%) using a subtle, non-intrusive color gradient that won't crowd your daily price action.
How to Use the Settings
Flip Retracement (Checkbox): * Unchecked (Default): Places 0% at the All-Time High and 100% at the All-Time Low (Ideal for finding support levels during a pullback from macro highs).
Checked: Places 0% at the All-Time Low and 100% at the All-Time High (Ideal for tracking major resistance levels and targets on the way back up).
💡 Pro-Tip: Because TradingView loads a limited number of historical bars on lower timeframes (like 5-minute or 15-minute charts), always load this indicator on a Daily (D), Weekly (W), or Monthly (M) chart first. This ensures the script catches the true historical inception highs and lows of the asset! Indicateur

Elaris Auto Trend Fibonacci ProElaris Auto Trend Fibonacci Pro
Overview
Elaris Auto Trend Fibonacci Pro is an advanced market structure and Fibonacci analysis tool designed to automatically identify directional trends, detect significant swing points, and project professional-grade Fibonacci retracement and extension levels directly on the chart.
Unlike manual Fibonacci drawing tools that require traders to constantly adjust anchor points, this indicator continuously analyzes confirmed swing structure and automatically maps the most relevant Fibonacci framework based on the current market trend.
The goal is to help traders quickly identify potential pullback zones, trend continuation areas, profit targets, and key reaction levels without manually redrawing Fibonacci levels throughout the trading session.
---
How The Indicator Works
1. Swing Structure Detection
The indicator first identifies confirmed swing highs and swing lows using a configurable pivot confirmation algorithm.
A swing is only considered valid after confirmation, which helps eliminate many false or premature swing points that often appear during volatile market conditions.
The minimum swing size can also be filtered using ATR-based validation, ensuring that insignificant market fluctuations are ignored.
---
2. Trend Identification
After detecting valid market structure, the indicator determines the dominant directional trend.
Bullish trends are identified when recent confirmed swing lows lead into higher confirmed swing highs.
Bearish trends are identified when recent confirmed swing highs lead into lower confirmed swing lows.
An optional EMA trend filter can be enabled to require alignment between price structure and moving average direction.
This additional layer helps reduce counter-trend Fibonacci projections.
---
3. Automatic Fibonacci Mapping
Once a valid trend is detected, Fibonacci levels are automatically projected between the most relevant confirmed swing points.
The indicator plots:
• 0.236 Retracement
• 0.382 Retracement
• 0.500 Midpoint
• 0.618 Golden Ratio
• 0.786 Deep Retracement
• 1.000 Retracement
These levels represent areas where pullbacks, reactions, trend continuations, or reversals may occur.
---
4. Golden Zone Highlighting
The area between the 50% and 61.8% retracement levels is automatically highlighted as the Golden Zone.
Many traders monitor this region because it often represents an area where institutional participants may re-enter an existing trend after a pullback.
The highlighted zone provides a quick visual reference for potential trend continuation opportunities.
---
5. Extension Targets
The indicator can optionally project Fibonacci extension levels beyond the current trend.
Available extension targets include:
• 1.272 Extension
• 1.618 Extension
• 2.000 Extension
These levels can be used as potential profit-taking areas, trend continuation objectives, or future reaction zones.
---
6. Trend Dashboard
A built-in dashboard provides real-time information including:
• Current trend direction
• Swing strength relative to ATR
• Fibonacci anchor direction
• Golden zone status
• Indicator operating mode
The dashboard helps traders evaluate current market conditions without needing additional analysis tools.
---
How To Use
Trend Continuation
1. Wait for a confirmed bullish or bearish trend.
2. Allow price to retrace toward the highlighted Fibonacci levels.
3. Monitor the Golden Zone for potential continuation setups.
4. Use extension levels as potential target areas.
Pullback Analysis
The 38.2%, 50%, and 61.8% retracement levels can help identify areas where temporary corrections may end and the primary trend may resume.
Target Projection
The Fibonacci extensions can be used to estimate possible future trend objectives after a successful continuation move.
---
Important Notes
• The indicator uses confirmed swing points and does not rely on future-looking calculations after confirmation.
• Fibonacci levels automatically update when a new confirmed market structure is established.
• The indicator is designed for trending markets and may generate fewer meaningful projections during prolonged ranging conditions.
• This tool is intended for technical analysis and should not be used as a standalone trading system.
---
Best Markets
The indicator can be applied to:
• Cryptocurrency Markets
• Forex Markets
• Stock Markets
• Index Markets
• Commodity Markets
It is particularly effective on higher liquidity instruments where market structure tends to be more consistent.
---
Best Timeframes
Recommended timeframes:
• 15 Minutes
• 1 Hour
• 4 Hours
• Daily
Higher timeframes generally produce more reliable market structure and Fibonacci projections.
---
Alerts
The indicator includes alerts for:
• Trend direction changes
• Golden Zone interactions
• Key Fibonacci level breaks
These alerts can be integrated into trading workflows for additional monitoring and confirmation.
---
Thank you for using Elaris Auto Trend Fibonacci Pro.
Indicateur

Impulse Correction Balance Map [AGPro Series]Impulse Correction Balance Map
🧠 Core Idea
Is the current correction still healthy compared with the prior impulse, or is the impulse losing structural balance?
📌 Overview / What it does
Impulse Correction Balance Map is a rule-based impulse and correction visualization tool designed to compare the current pullback with the prior directional swing leg.
The script identifies a valid bullish or bearish impulse, measures correction depth, maps the healthy-to-balanced correction pocket, and highlights whether price is still respecting the impulse structure or moving into failure risk.
It does not predict price direction, automate trades, or guarantee continuation after a pullback. It is a structured market-structure and wave-analysis tool for reading impulse strength, correction depth, balance, continuation, and failure context.
🎯 Purpose & Design Philosophy
Many pullback tools mark a retracement or draw generic Fibonacci levels.
This script was built to answer a more practical question:
Is the correction proportionate to the impulse that created it?
The design goal is to help traders evaluate pullbacks as part of a complete impulse-correction relationship instead of treating every retracement as equal.
⚡ Why This Script Is Different
Most tools focus on static retracement levels, generic trend strength, or simple pullback labels.
This script does NOT mark every pullback as a clean opportunity.
Instead, it builds the impulse leg first, measures the correction against that leg, separates healthy correction, balanced pullback, deep correction, continuation, and failure risk, then displays the story through premium chart visuals and a compact AG Pro panel.
⚙️ Methodology
1. Swing Detection
The script uses confirmed swing pivots to identify meaningful bullish or bearish impulse legs.
2. Impulse Validation
An impulse must meet a minimum ATR-normalized size before it becomes the active reference leg.
3. Correction Mapping
After the impulse forms, the script tracks the deepest correction point and calculates retracement depth as a percentage of the impulse.
4. Balance Evaluation
Correction depth is classified into healthy, balanced, deep, continuation, or failure states.
5. Visual Output
The chart displays the impulse box, correction pocket, depth ladder, centered pocket label, right-side tags, event labels, alerts, and a compact AG Pro decision panel.
🗺️ How to Read the Chart
Impulse Box = the prior validated directional swing leg.
Correction Pocket = the projected healthy-to-balanced retracement area.
Depth Ladder = reference rails for shallow, balanced, and deep correction zones.
Centered Pocket Label = the main visual anchor for the active balance pocket and quality score.
Right-Side Tags = current correction depth, balance state, and continuation reference.
Event Labels = key moments such as healthy correction, deep correction, continuation, or correction failure.
Panel = summarizes balance state, impulse direction, correction depth, impulse size, quality score, next context, and timeframe.
🚦 Signals & States
• HEALTHY CORRECTION → correction depth remains shallow relative to the impulse.
• BALANCED PULLBACK → correction is deeper but still inside the normal balance area.
• DEEP CORRECTION → correction is pressing into a riskier retracement zone.
• HIGH FAILURE RISK → correction is beyond the preferred balance area.
• CONTINUATION → price extends beyond the impulse end in the impulse direction.
• CORRECTION FAIL → price invalidates the impulse start area.
• WAIT IMPULSE → no valid impulse reference is active yet.
🔔 Alerts Logic
Alerts trigger when a major impulse-correction state appears.
• Healthy Correction → correction remains inside the healthy retracement area.
• Deep Correction Risk → correction depth moves into the deep-correction risk area.
• Continuation Trigger → price breaks beyond the impulse end in the impulse direction.
• Correction Failure → correction invalidates the impulse start area.
Alerts are attention markers, not trade instructions.
🧩 Confluence Logic
The context becomes stronger when:
• The impulse leg is large enough relative to ATR
• Correction depth remains proportionate
• Price respects the balance pocket
• Continuation appears after a controlled correction
• The panel state agrees with the event label
• Broader trend structure supports the impulse direction
If these elements do not align, the script avoids forcing a continuation interpretation.
📊 When to Use
• Trend continuation analysis
• Pullback evaluation
• Swing structure review
• Crypto, forex, stocks, and index markets
• Wave-style impulse and correction studies
• 1H, 4H, and daily charts
• Markets with clear directional legs and retracement behavior
⚠️ When NOT to Use
• Very low-liquidity symbols
• Extremely choppy markets with no clear swing structure
• News-driven candles where pivots may be distorted
• Ultra-low timeframes with excessive noise
• Markets where every pullback is immediately invalidated by volatility
• Situations where a single retracement should not be treated as a standalone decision
🎛️ Key Inputs
• Swing Pivot Length → controls how swing highs and lows are confirmed.
• Minimum Impulse ATR → defines how large the impulse must be before it becomes active.
• ATR Length → normalizes impulse size, label spacing, and correction context.
• Healthy Correction Max % → defines the upper boundary of the shallow correction zone.
• Balance Correction Max % → defines the upper boundary of the balanced correction zone.
• Deep Correction Max % → defines the deep-correction risk boundary.
• Projection Bars → controls how far correction pockets, rails, and tags project.
• Label Font Size → controls chart label and tag text size.
• Panel Font Size → controls panel text size.
🖥️ Interface & Visual Design
The visual hierarchy is built around the impulse-correction relationship.
The impulse box shows the directional leg.
The correction pocket shows where a controlled retracement can remain balanced.
The depth ladder shows where the correction becomes shallow, balanced, deep, or risky.
The centered badge makes the pocket readable at first glance.
The AG Pro panel summarizes the current state without forcing the user to inspect every level manually.
🧪 Practical Usage Workflow
1. Wait for a valid impulse leg to appear.
2. Check the correction pocket and depth ladder.
3. Read the current balance state in the panel.
4. Watch whether the correction stays healthy, becomes deep, or fails.
5. Look for continuation only after the correction context remains controlled.
6. Interpret the result inside broader trend, liquidity, and volatility context.
🔍 Interpretation Guidelines
A healthy correction does not guarantee continuation. It means the retracement is still proportionate to the prior impulse.
A deep correction does not guarantee reversal. It means the pullback is approaching an area where the original impulse is less structurally clean.
A continuation trigger does not guarantee follow-through. It means price extended beyond the impulse end according to the script's rule set.
A correction failure is a structural warning, not a trading command.
🚫 What This Script Is NOT
This script is not a prediction engine.
It is not financial advice.
It is not an auto-trading system.
It does not provide guaranteed entry or exit signals.
It is not a standard Fibonacci retracement tool.
It is not a full Elliott Wave counter.
⚠️ Limitations & Transparency
Swing detection depends on pivot confirmation, so signals can appear after pivots are confirmed.
Timeframe differences can change impulse and correction structure.
High volatility may cause correction depth to expand quickly.
Low-liquidity markets may produce unreliable swing pivots.
The script is designed for structured interpretation, not certainty.
🧠 Market Context Notes
Impulse-correction behavior is strongest when the market has a clear directional leg, a readable retracement, and enough liquidity for swing structure to matter.
The same correction depth can mean different things in a strong trend, a range, or a volatility shock.
The script should be read together with broader structure, volume, volatility, and market regime.
🧾 Use Case Examples
• If a bullish impulse forms and the correction remains shallow, the map may show healthy correction context.
• If a bearish impulse forms and price retraces deeply against it, the map may show deep correction or failure risk.
• If price breaks beyond the impulse end after a controlled correction, the map may show continuation.
🧱 System Philosophy
Impulse Correction Balance Map is part of the AGPro Series approach to decision-support tools:
clear structure, premium chart readability, honest interpretation, and no promise of certainty.
The goal is to help traders understand the relationship between impulse strength and correction depth without turning analysis into signal spam.
🔐 Non-Promise Statement
No script can know the future.
No correction depth guarantees continuation or reversal.
No signal should be interpreted without broader market context.
📉 Risk Disclosure
Trading involves risk.
Markets can move unpredictably.
This script is for educational and analytical purposes only.
It does not provide financial advice or guaranteed trading outcomes.
Users remain responsible for their own decisions.
📚 Educational Note
Use this script to study how impulses and corrections relate to each other.
The value is not only in the label. The value is in learning whether a pullback is proportionate, stretched, balanced, or structurally weak compared with the impulse that came before it.
Indicateur

Reversal Scalper - Adib NooraniThe Reversal Scalper is an indicator designed to identify potential reversal zones based on supply and demand dynamics. It uses smoothed stochastic logic along with ATR bands, to reduce noise and highlight areas where momentum may be weakening, signaling possible market turning points.
🔹 Smooth, noise-reduced stochastic oscillator
🔹 Custom zones to highlight potential supply and demand imbalances
🔹 Non-repainting, compatible across all timeframes and assets
🔹 Visual-only tool — intended to support discretionary trading decisions
This oscillator assists scalpers and intraday traders in tracking subtle shifts in momentum, helping them identify when a market may be preparing to reverse — always keeping in mind that trading is based on probabilities, not certainties.
📘 How to Use the Indicator Efficiently
For Reversal Trading:
Buy Setup
– When the blue line dips below the 20 level, wait for it to re-enter above 20.
– Look for reversal candlestick patterns (e.g., bullish engulfing, hammer, or morning star).
– Enter above the pattern’s high, with a stop loss below its low.
Sell Setup
– When the blue line rises above the 80 level, wait for it to re-enter below 80.
– Look for bearish candlestick patterns (e.g., bearish engulfing, inverted hammer, or evening star).
– Enter below the pattern’s low, with a stop loss above its high.
🛡 Risk Management Guidelines
Risk only 0.5% of your capital per trade
Book 50% profits at a 1:1 risk-reward ratio
Remaining 50% at 1:2 risk-reward ratio
Indicateur

Black Tie Fibonacci OTE MTFMulti-timeframe Fibonacci retracement with Optimal Trade Entry (OTE) zone highlighting. Reads the previous closed candle from a higher timeframe, detects whether it was bullish or bearish, and projects retracement levels accordingly.
The 0.618 - 0.786 zone is highlighted as the OTE: the deepest acceptable pullback before a trend continuation setup is considered failed.
LEVELS
0.236 / 0.382 Shallow retracements, indicate strong momentum
0.500 Equilibrium, mid-point of the range
0.618 Top of the OTE zone, primary pullback target
0.786 Bottom of the OTE zone, deepest acceptable pullback
In a bullish HTF candle, retracement is measured downward from the high. In a bearish HTF candle, retracement is measured upward from the low. The bias is detected automatically from the previous closed HTF candle.
USAGE
Use this on its own as a pullback entry tool, or in combination with a trend filter (HTF moving average, market structure, etc).
When price enters the OTE zone in alignment with HTF trend direction, that is the textbook setup. When price rejects the OTE zone aggressively (long upper or lower wick), it can be a mean-reversion signal in the opposite direction.
The 0.618 alone is also a common shallow-retracement entry for traders who want to capture more of the move at the cost of a wider stop.
SETTINGS
Reference Timeframe controls the HTF used for bias detection and range calculation. Default Daily; use Weekly for swing and Monthly for position trades.
HTF High and Low lines are plotted by default as primary liquidity targets.
HTF Open and Close lines available as optional references.
The OTE zone has a customizable background color Indicateur

Low Volume Pullback Zones [AGPro Series]Low Volume Pullback Zones
🔷 Overview
Low Volume Pullback Zones is a trend-continuation overlay built for one very specific market behavior: a trend is already established, price retraces in a controlled way, volume dries up during that retracement, and the market later reclaims a continuation trigger.
The default profile is tuned for daily swing charts, where low-volume retracements usually form cleaner structural pockets and the chart has enough space for the boxes to read properly. A 4H Active preset is included for traders who want more frequent mapping, while Custom mode exposes the raw controls.
Many pullback tools focus only on price touching a moving average, a SuperTrend line, or a generic support/resistance area. This script is intentionally narrower. It looks for the quieter part of a trend: the moment where participation contracts during a retracement, the pullback stays shallow relative to the prior impulse, and a clean continuation pocket can be mapped with a visible invalidation boundary.
The goal is not to mark every trend candle. The goal is to isolate the cleaner pauses inside trend conditions where the pullback behaves like controlled absorption instead of aggressive reversal pressure.
🟩 What The Script Detects
The engine combines five layers:
1. Trend Side
The script first checks whether the market has a clean bullish or bearish trend profile using EMA alignment, EMA slope, DI direction, and ADX strength. If the trend is flat or mixed, the script avoids mapping low-quality pullbacks.
2. Low RVOL Retracement
During a pullback, the script measures relative volume against a rolling volume baseline. A stronger dry-up score means the retracement is happening with lighter participation, which often creates a cleaner continuation context than high-volume countertrend pressure.
3. Shallow Pullback Depth
The pullback is measured against the prior impulse reference range. Controlled retracements receive higher scores, while deep retracements move toward failure risk.
4. Continuation Trigger
The script waits for price to reclaim beyond the pullback pocket boundary with a small ATR buffer and relative-volume recovery. This prevents the chart from filling with premature pullback labels before the structure actually confirms.
5. Invalidation Boundary
Every active dry-up pocket has a structural boundary beyond the deepest pullback extreme. If price breaks that boundary, the pocket is treated as invalid rather than leaving an old setup on the chart.
🟦 Chart Visuals
The main visual layer is the Dry-Up Pullback Pocket.
When a valid pullback begins, the script draws a compact rectangular pocket around the retracement range. If the pocket confirms, the script projects a tighter functional retest/hold zone instead of extending the entire historical pullback range. This makes the zone easier to use: bullish zones focus on the reclaimed upper pocket area, bearish zones focus on the reclaimed lower pocket area, and the dotted invalidation boundary remains beyond the failed side of the structure.
Dry-Up Watch labels can appear before final confirmation when the pullback already has strong volume contraction and acceptable structure. Rejected context boxes are optional and disabled by default because they are diagnostic, not actionable hold zones. Trigger labels remain compact and controlled by cooldown logic. The default behavior keeps the chart active enough to be useful without making it feel crowded or noisy.
🟨 Info Panel
The panel summarizes the current state:
Trend Side - bullish trend, bearish trend, or no clean trend.
Dry-Up Score - how strongly volume contracted inside the active or most recent pocket.
Pullback Depth - retracement depth relative to the prior impulse.
Trigger State - mapping, triggered, expired, boundary lost, trend lost, or waiting.
Failure Risk - a compact risk read based on depth, volume behavior, and pullback duration.
The panel location, panel theme, panel font size, and label font size are configurable from settings. The first panel row follows the AGPro Series standard format with a single merged blue header row.
🟪 What Makes This Different
This script is not a generic trend meter.
It is not a SuperTrend reaction tool.
It is not a broad continuation score dashboard.
It is not a volume spike or climax detector.
Low Volume Pullback Zones is focused on the relationship between trend continuation and volume contraction during the retracement itself. That makes the script different from tools that only measure trend strength, moving-average reclaim, breakout quality, support/resistance reactions, or high-volume pressure events.
The core question is:
Did the pullback become quiet enough, shallow enough, and controlled enough to justify a mapped continuation pocket?
That narrow question is what gives the script its identity.
🧭 How To Read It
Bullish dry-up pocket:
The trend filter is bullish, price retraces into the EMA lane, average RVOL contracts, depth remains controlled, and price reclaims the upper pocket boundary.
Bearish dry-up pocket:
The trend filter is bearish, price retraces upward into the EMA lane, average RVOL contracts, depth remains controlled, and price reclaims the lower pocket boundary.
Failure risk:
Failure risk rises when the pullback becomes too deep, too long, or too active in volume terms. A higher failure risk means the retracement is no longer behaving like a quiet continuation pause.
Invalidation boundary:
The dotted boundary marks the structural area where the active pocket is no longer considered valid.
⚙ Key Settings
Engine Preset:
Daily Swing is the default and is designed for cleaner publication-grade structure. 4H Active keeps more frequent lower-timeframe pockets. Custom uses the direct input values.
Fast / Mid / Slow EMA Lengths:
Control the trend structure used by the pullback engine.
Minimum ADX and Minimum EMA Slope:
Help the script avoid mapping dry-up pockets in flat conditions.
Relative Volume Length:
Defines the baseline used to measure volume dry-up.
Preferred Pullback RVOL:
Controls how quiet the pullback should be to receive full dry-up credit.
Preferred Max Depth:
Defines the ideal shallow retracement threshold.
Trigger Buffer:
Adds a small ATR-based confirmation buffer beyond the pullback pocket.
Pocket Projection Bars:
Controls how far completed pockets extend to the right.
Functional Zone Width:
Controls how much of the original pullback range is projected after confirmation. Smaller values create a tighter retest/hold pocket; larger values keep more of the original pullback structure.
Label Cooldown and Max Structures:
Keep the overlay readable and publication-clean.
📌 Best Use
This indicator is best used on markets that already show directional structure. It is designed for traders who study trend continuation, relative volume behavior, pullback quality, and invalidation-based chart structure.
It can be used across crypto, forex, indices, equities, and commodities, but the most useful results generally appear when the market has enough trend strength for low-volume retracements to matter.
🟧 Design Philosophy
Low Volume Pullback Zones was built to keep the chart premium and readable:
Clean pocket boxes instead of noisy background clutter.
Restrained watch and trigger labels instead of constant marker spam.
Visible invalidation boundaries instead of ambiguous zones.
Professional RVOL and depth scoring instead of simple moving-average touches.
Configurable panel and label sizing for different chart layouts.
The script is intentionally selective. Its strongest value comes from filtering out ordinary pullbacks and highlighting the ones where trend, volume dry-up, shallow depth, and continuation confirmation align.
Indicateur

VP + OTE ZonesHow To Use VP + OTE Zones — Plain English
What Is This Thing Even Doing?
Imagine price just made a big fast move up or down. That move is called a displacement. After a big move like that, price almost always comes back to "retest" part of that move before continuing. This indicator automatically finds those big moves, draws a box over the zone where price is most likely to pull back into, and labels the key levels inside that zone. That's it. Your job is to wait for price to come back into the box and look for a reason to enter.
Step 1 — Set Your Timeframe
This works best on intraday charts. Start here:
NQ / ES futures → use the 1 minute, 3 minute, or 5 minute chart
Forex pairs → use the 5 minute or 15 minute chart
Crypto → use the 5 minute or 15 minute chart
If you are a swing trader, try the 1 hour or 4 hour chart. The indicator works on any timeframe but was built with intraday in mind.
Step 2 — Understand What You Are Looking At
When the indicator draws a box on your chart, here is what it means:
🟢 Green box — Price made a big move UP. The indicator is saying "if price pulls back down into this green zone, that is a potential buy area."
🔴 Red box — Price made a big move DOWN. The indicator is saying "if price pulls back up into this red zone, that is a potential sell area."
The lines inside the box are Fibonacci levels. They are labeled on the right side of the box:
0.618 — The start of the zone. Shallow retracement.
0.650 — Just inside the zone.
0.705 — The midpoint. The bold line. This is the most watched level inside the zone.
0.790 — Deeper into the zone.
0.886 — The far edge of the zone. If price closes beyond this, the zone is cancelled automatically.
Think of the zone like a window. You want price to enter the window. The 0.705 level is the center of the window and usually the highest probability spot inside it.
Step 3 — Wait For Price To Enter The Box
Do not chase price. Do not enter before price gets to the box. Simply watch and wait.
When price starts moving toward a box, get ready. When it enters the box, start looking for your entry trigger. Your trigger is NOT this indicator — this indicator only tells you WHERE to look. You still need a reason to pull the trigger such as:
A candlestick pattern (engulfing, rejection wick, inside bar)
A market structure shift on a lower timeframe
A confluence with another level like a session high/low or a previous support/resistance
Step 4 — Know When The Zone Is No Longer Valid
The indicator handles this automatically, but you should understand the logic:
❌ Zone gets cancelled if price closes hard beyond the 0.886 level. That means the move went too deep and the zone failed. The box will disappear on its own. Do not try to hold a trade in a cancelled zone.
⏳ Zone ages out if price never came back to it after a set number of bars. Old zones that price ignores are automatically removed to keep your chart clean.
✅ Zone stays active as long as price has not violated it and it has not expired. Multiple zones can be on your chart at once. Focus on the freshest ones closest to current price.
Step 5 — Settings To Know
Open the indicator settings. Here are the only ones you really need to worry about as a beginner:
Pivot Length (default 14)
This controls how sensitive the indicator is to swing points. Lower number = more zones drawn but more noise. Higher number = fewer zones but only the big obvious ones. Start at 14 and only change it if you feel like you are getting too many or too few boxes.
Min Leg Size in Points (default 25)
This is the minimum size a move has to be before the indicator draws a zone. If you are trading NQ you may want to raise this to 50 or 75 so you only get zones from really significant moves. If you are trading a slower instrument like forex you may want to lower it.
Require LVN in OTE Zone (default ON)
This is a volume filter. When it is on, the indicator only draws a zone if there is a low volume pocket inside it — meaning price flew through that area fast without much trading happening, which makes it more likely to act as a magnet later. Leave this ON. Only turn it off if you feel like you are missing too many zones.
Max Zone Age (default 150 bars)
Zones older than this disappear automatically. If you want zones to stay on screen longer raise this number. If your chart feels cluttered lower it.
Label Bar Offset (default 3)
This controls how far to the right the level labels sit outside the box. If the labels feel too close to price or overlapping other things, increase this number.
Step 6 — The Simple Workflow Every Session
Open your chart and let the indicator load
Look at which boxes are currently on the chart and closest to price
Identify if price is above or below those boxes
If price is above a green box — watch for a pullback down into it
If price is below a red box — watch for a pullback up into it
When price enters the box — zoom into a lower timeframe and look for your entry trigger
If price blows through the 0.886 and the box disappears — move on, that zone failed
Common Mistakes To Avoid
🚫 Do not enter just because price touched the box. Wait for confirmation. The box is a area of interest, not a guaranteed reversal.
🚫 Do not ignore the direction of the box. A green box is a potential buy zone. Do not try to short into a green box just because price is there.
🚫 Do not ignore your higher timeframe bias. If the daily chart is clearly bearish, be very selective about taking buys from green zones on the 5 minute chart.
🚫 Do not trade every zone. Be selective. Look for zones that line up with other things you already use — session levels, previous highs and lows, news events.
🚫 Do not panic if a zone disappears. That just means it got invalidated or aged out. There will always be new zones forming.
The One Sentence Summary
Price makes a big move, this indicator draws a box where it is most likely to retrace to, you wait for price to come back to the box, and you look for a reason to enter in the direction of the original move. Indicateur

AG Pro Premium Discount Zone Engine [AGPro Series]AG Pro Premium Discount Zone Engine
Overview / What it does
AG Pro Premium Discount Zone Engine is a dealing-range and retracement context overlay built to map relative value inside a selected swing. Instead of treating price as a sequence of isolated candles, the script frames current price location against an active high-low range and highlights where price is trading relative to equilibrium, premium, discount, and the OTE area.
The core purpose of this tool is organizational. It is designed to help traders read where price is positioned inside a live swing and how price reacts when it moves into higher-value or lower-value retracement zones. This is especially useful when a chart is moving inside a pullback, when trend continuation is being evaluated, or when users want to distinguish between shallow retracements and deeper repricing within an existing range.
The script supports multiple ways to define the active range. Users can work with an automatically detected swing, a higher-timeframe dealing range, or a manual-lite anchor mode based on bar offsets. Once a valid range is identified, the script projects premium and discount territory, marks the 50% equilibrium, and highlights the OTE area using the 61.8, 70.5, and 78.6 retracement levels.
The output is intentionally visual, structured, and restrained. Premium and discount zones are shown as clean value blocks. The OTE area is treated as the main focus zone rather than a minor detail. The panel summarizes the active bias, current location, zone state, equilibrium level, and OTE boundaries so that users can read the chart quickly without relying on aggressive signal language.
Unique Edge
What makes this script different is that it is not built as a market-structure detector, imbalance mapper, liquidity event scanner, or order-block locator. Its job is narrower and more specific: it organizes relative price location inside a defined dealing range.
That distinction matters. Many overlays attempt to explain everything on the chart at once. This script does not. It does not try to label breaks of structure, detect fair value gaps, mark liquidity sweeps, or classify institutional zones. Instead, it answers a more focused question: where is price trading inside the current swing, and how is it behaving as it enters or leaves important retracement territory?
This also separates the script from other AG Pro tools. Some AG Pro overlays are built around structure transitions, some around imbalance behavior, some around reaction quality, and some around event detection. AG Pro Premium Discount Zone Engine is built around valuation context. It does not compete with those tools directly. It complements them by adding a relative-value map around a selected range.
Another difference is the zone-state logic. The script does not stop at drawing premium and discount blocks. It also tracks how price interacts with the OTE area and classifies that interaction using a simple state model such as Fresh, First tap, Retested, Rejected, Accepted, and Invalidated. This creates a more contextual read than a static retracement overlay.
Methodology
The script begins by identifying an active swing range. In Auto Swing mode, it uses pivot-based range detection. In HTF Swing mode, it builds the range from a higher-timeframe high-low window. In Manual-Lite Swing mode, it uses bar-offset anchors to let the user define a practical swing reference without requiring manual drawing tools.
Once the active range is available, the script calculates the internal value map:
- Swing High
- Swing Low
- 50% Equilibrium
- Premium territory above equilibrium
- Discount territory below equilibrium
- OTE zone using 61.8, 70.5, and 78.6 retracement levels
The script then monitors how price behaves around those levels. This produces context states rather than directional promises. For example, price entering the OTE area is not treated the same as price rejecting from it, accepting beyond it, or invalidating the active range. These are intentionally different events because they describe different chart conditions.
The equilibrium level is included as a centerline reference, while the OTE band is given stronger visual emphasis. This helps distinguish broad valuation territory from the narrower retracement pocket that many users monitor more closely.
Signals & Alerts
The signals in this script are event-based and deterministic. They are not designed as standalone trade instructions. They are designed to describe interaction with the active range.
Available event logic includes:
- OTE Test
- OTE Reject
- OTE Accept
- Discount Reaction
- Premium Rejection
- Equilibrium Cross
- Range Invalidated
- OTE Failure
These events are intended to provide chart context. For example, an OTE Test simply means price entered the active OTE zone. A Premium Rejection means price traded into the premium side and closed back below the local premium threshold used by the script. A Discount Reaction means price interacted with the discount side and responded upward under the script's rules. These are context events, not guarantees of continuation.
Alerts follow the same philosophy. They are defined in a rules-based way so users can monitor range interaction without needing to watch the chart continuously. The alert layer is most useful when the script is used as a location filter inside a broader workflow.
Key Inputs
Swing mode
Lets the user choose between Auto Swing, HTF Swing, and Manual-Lite Swing depending on whether the goal is reactive automation, higher-timeframe framing, or a more controlled local range definition.
Auto pivot length
Controls how sensitive the pivot-based swing detection is in Auto mode.
HTF timeframe and HTF lookback
Used to define the broader dealing range in higher-timeframe mode.
Manual high bars back / manual low bars back
Used to create a manual-lite range by referencing earlier bars as anchors.
Render bars back / render bars forward
Controls how far the active range projection extends on the chart.
Zone opacity and theme
Used to refine the visual balance between premium, discount, and OTE areas.
Label controls
Used to reduce visual noise by controlling label cooldown, label render window, and maximum visible labels.
Panel controls
Allow the user to reposition the panel and adjust its text size to fit different chart layouts.
Limitations & Transparency
This script does not predict direction. It does not forecast reversals. It does not decide whether a chart should trend, break, or fail. It maps relative value inside a selected range and reports interaction events inside that framework.
The quality of the output depends on the quality of the active swing. If the selected or detected range is not meaningful for the user's workflow, the valuation map will also be less meaningful. This is especially important in highly compressed, extremely noisy, or structurally unclear conditions.
Auto Swing mode is practical, but like any automated swing model, it depends on pivot confirmation and may update as newer pivots become available. HTF mode provides broader context but may feel less reactive on smaller charts. Manual-Lite mode gives more control but still depends on the user choosing sensible anchor distances.
OTE logic is range-relative. It does not incorporate unrelated concepts such as order blocks, liquidity pools, fair value gaps, session models, or external structure classifications unless the user combines those ideas manually in a separate workflow.
This script is best understood as a valuation-context overlay. It is not a complete strategy, not a full decision engine, and not a substitute for risk management.
How this differs from other AG Pro scripts
AG Pro Premium Discount Zone Engine is intentionally not a structure-break tool, not a CHoCH/BOS detector, not a liquidity sweep scanner, not an FVG engine, and not an order-block mapper.
Its role inside the AG Pro family is to answer a different question:
Where is price trading inside the active dealing range, and what is the quality of its interaction with that value map?
That makes it particularly useful for users who already understand direction from another process and want cleaner execution context. In other words, some tools focus on structural change, some focus on imbalance, and some focus on reaction events. This one focuses on valuation location.
Risk Disclosure
This script is for chart analysis and educational use only. It does not provide financial advice, investment advice, or guaranteed trade signals. Any use of this tool should be combined with independent analysis, risk controls, position management, and market-specific judgment.
The presence of an alert, label, premium zone, discount zone, or OTE interaction does not imply that price must react in a specific way. Markets can continue, reverse, compress, or invalidate a range without warning. Users should treat this script as a context tool, not as a promise of outcome.
Indicateur

Hash Auto Fibonacci## Overview
Hash Auto Fibonacci eliminates the most time-consuming part of Fibonacci trading — drawing the levels yourself. Drop it on any chart and it automatically detects the most recent significant swing high and swing low, then instantly draws a complete Fibonacci retracement web anchored to those pivots. No manual drawing, no subjectivity, no missed setups.
Built for active traders who use Fibonacci as a core part of their strategy, this tool is engineered to keep up with fast-moving markets through a volatility-adaptive detection engine, a highlighted Golden Pocket zone, a built-in stop-loss reference, and optional multi-timeframe confirmation.
## Key Features
**Automatic Swing Detection**
The indicator uses a pivot-based algorithm to identify swing highs and lows in real time. A pink dot marks the swing high and a green dot marks the swing low on the chart — always showing only the current active pair, never cluttering your screen with historical markers.
**Dynamic Lookback Engine**
Rather than using a fixed lookback period, Hash Auto Fibonacci automatically adjusts its sensitivity based on current market volatility. During high-volatility conditions (fast trending moves, breakouts), the lookback shortens to detect swings quickly. During low-volatility conditions (consolidation, ranging markets), it lengthens to filter out noise and identify only meaningful pivots. This is calculated using the ratio of a 50-period ATR to a 10-period ATR, scaled by a user-adjustable multiplier. You can also switch to a fixed manual lookback at any time.
**Fibonacci Retracement Levels**
The following retracement levels are drawn automatically:
- 0 (swing high anchor)
- 0.236
- 0.382
- 0.5
- 0.618
- 0.65
- 0.786
- 1.0 (swing low anchor)
Optional extension levels (1.272, 1.618, 2.618) can be enabled for targets beyond the swing low.
**The Golden Pocket Zone**
The 0.618–0.65 confluence zone is highlighted as a gradient-filled amber band directly on the chart. This region — known as the Golden Pocket — is widely regarded as the highest-probability reversal zone within any Fibonacci retracement. The zone enforces an ATR-based minimum thickness so it remains visible even on assets with small absolute price ranges.
**ATR Stop-Loss Reference**
A dashed red line is automatically drawn below the swing low (bullish setup) or above the swing high (bearish setup) at a distance of 2× ATR-10. This gives a data-driven starting point for your stop-loss placement without requiring a separate indicator.
**Multi-Timeframe Confirmation**
When the current chart's swing pivot aligns within 0.5% of a confirmed pivot on a higher timeframe (default: 4H), the entire Fibonacci web is visually upgraded — lines become bolder, a confirmation badge appears, and an alert can be triggered. MTF-confirmed webs represent structurally significant levels that multiple timeframes agree on, which historically carry more weight as support and resistance.
**Direction Detection**
The indicator automatically determines whether the current setup is bullish (retracing upward from a low) or bearish (retracing downward from a high) by comparing which pivot — the high or the low — was confirmed most recently. You can override this manually if needed.
**Info Dashboard**
A clean navy dashboard in the corner of your chart displays:
- Current swing high and swing low prices
- 0.5 and 0.618 Fibonacci levels
- Golden Pocket price range
- Suggested ATR-based stop-loss price
- Active lookback period (and whether it's dynamic or manual)
---
## How To Use
**Basic setup**
Add the indicator to any chart. It works on all timeframes and all assets — crypto, stocks, forex, futures. The Fibonacci web draws automatically. The Golden Pocket zone is the primary area to watch for price reactions.
**Reading the chart**
- Price pulling back into the Golden Pocket (0.618–0.65 zone) in a bullish setup is the classic high-probability long entry zone
- Price rejecting from the Golden Pocket in a bearish setup is a potential short entry or profit-taking zone
- The 0.5 level acts as the midpoint — a close above (bullish) or below (bearish) confirms continuation of the retracement
- The 0.786 level is deep — a sweep past this level often signals the retracement is becoming a full reversal
**Using the stop-loss line**
The dashed red SL line is a reference, not a guaranteed stop placement. Use it as a starting point and adjust to your own risk tolerance. On volatile assets, consider placing your stop slightly beyond it to avoid wicks triggering your exit prematurely.
**Multi-timeframe confirmation**
When the ◆ MTF badge appears, the swing that anchors the current web also exists on the higher timeframe. These setups tend to produce cleaner reactions at Fibonacci levels because they represent areas where both short-term and institutional timeframe participants are watching the same price zone.
**Alerts**
Five alert conditions are available:
- New swing high detected
- New swing low detected
- MTF confirmation active
- Price entering the Golden Pocket
- Price at the 0.382 level
- Price at the 0.786 level
Set these in the Alerts panel to get notified without watching the chart constantly.
---
## Settings Reference
**Swing Detection**
| Setting | Default | Description |
|---|---|---|
| Dynamic lookback | On | Automatically adjusts pivot sensitivity based on volatility |
| Manual lookback | 10 | Fixed lookback used when dynamic mode is off |
| Dynamic multiplier | 9 | Controls the average lookback length in dynamic mode |
| Direction mode | Auto | Auto, Bullish, or Bearish override |
| Show swing markers | On | Displays pivot dots on the chart |
**Multi-Timeframe Confirmation**
| Setting | Default | Description |
|---|---|---|
| MTF confirmation | On | Enables higher timeframe pivot alignment check |
| HTF timeframe | 240 (4H) | The timeframe used for confirmation pivots |
**Fibonacci Levels**
| Setting | Default | Description |
|---|---|---|
| Retracement levels | On | Draws the standard 0–1 retracement web |
| Extension levels | Off | Adds 1.272, 1.618, 2.618 extension targets |
| Ratio labels | On | Shows ratio numbers next to each level |
| Golden Pocket zone | On | Highlights the 0.618–0.65 zone |
| ATR stop-loss line | On | Draws the 2× ATR stop reference |
**Info Table**
| Setting | Default | Description |
|---|---|---|
| Show info table | On | Displays the dashboard |
| Position | Top Right | Corner placement of the dashboard |
---
## Notes
- This indicator is an overlay — it draws directly on the price chart
- Works on all timeframes, all markets, and all asset classes available on TradingView
- The dynamic lookback is calibrated on BTC/USDT 1H data and performs well across most liquid crypto and equity instruments
- Past Fibonacci levels do not guarantee future price reactions — use this tool as part of a broader trading system, not as a standalone signal
- This indicator does not repaint. Swing pivots are confirmed before being drawn and are not subject to change after confirmation
---
## By Hash Capital Research
Indicateur

W.D. Gann Toolkit [UAlgo]W.D. Gann Toolkit is a multi tool market structure overlay built to project several classic Gann concepts directly from confirmed pivot points. Instead of focusing on only one angle or one timing idea, the script combines Gann Fan, Gann Box, Square of 9 levels, Master Time Factor markers, Gann retracements, and a live swing charting layer inside a single framework.
The indicator begins with confirmed pivot highs and pivot lows. Once a new pivot is detected, it becomes a structural anchor from which the selected Gann tools are drawn. This makes the toolkit adaptive to changing market structure rather than forcing the user to manually place every anchor point. The user can also decide how many historical pivots should remain active, which helps balance chart detail and readability.
One of the most important parts of any Gann based study is scale. A 1x1 angle only has meaning if the price per bar relationship is defined in a sensible way. For that reason, this script includes several scale methods. It can estimate scale from the broader chart range, from the most recent swing, from ATR, or from a fully manual input. This makes the toolkit flexible enough for different markets and chart styles while still keeping the geometry grounded in visible price behavior.
The Gann Fan module projects the classic angle family such as 1x8, 1x4, 1x3, 1x2, 1x1, 2x1, 3x1, 4x1, and 8x1. The Gann Box creates a ninety bar by scaled price box from the pivot. The Square of 9 module projects rotational price levels from the pivot using square root based calculations. The Master Time Factor module adds important future bar intervals from the pivot. The retracement module draws classic Gann proportional levels between two pivots. A simple Gann style swing chart is also included to visualize directional swing progression on the live chart.
In practical use, W.D. Gann Toolkit is useful for traders who want one structured environment for price, angle, time, and proportion analysis without manually recreating each Gann tool from scratch.
🔹 Features
🔸 Automatic Pivot Anchoring
All tools are drawn from confirmed pivot highs and pivot lows. This lets the toolkit respond to live market structure and keeps the drawings tied to meaningful turning points.
🔸 Multiple Scaling Methods
The script supports Auto Chart Range, Auto Swing, Auto ATR, and Manual scale modes. This is especially important for Gann work because angle interpretation depends on a stable price per bar relationship.
🔸 Gann Fan Projection
The indicator draws the classic Gann angle family from each selected pivot, including the key 1x1 line and the faster and slower angle groups around it.
🔸 Gann Box
A ninety bar box is projected from the pivot using the active scale. This gives the chart a combined time and price measurement zone.
🔸 Square of 9 Price Levels
The script projects Square of 9 levels such as 180°, 360°, 540°, and 720° from the pivot price using the square root transformation method.
🔸 Master Time Factor Markers
Vertical time markers are projected from each pivot at important intervals such as 30, 45, 90, and 180 bars.
🔸 Gann Retracements
When two pivots are available, the script draws classic Gann retracement levels such as 12.5%, 25%, 33.3%, 50%, 66.7%, 75%, and 87.5%.
🔸 Gann Swing Charting
A live swing line tracks directional shifts based on higher highs with higher lows or lower highs with lower lows, creating a simple structural swing map.
🔸 Historical Pivot Control
The user can choose how many recent pivots remain active for tool projection. This keeps the chart cleaner when needed.
🔸 Modern Color Theming
Different tool families use their own color groups, which makes it much easier to separate angles, price levels, time levels, retracements, and swing structure visually.
🔹 Calculations
1) Detecting Confirmed Pivot Highs and Lows
float ph = ta.pivothigh(high, i_piv_len, i_piv_len)
float pl = ta.pivotlow(low, i_piv_len, i_piv_len)
bool is_new_pivot = false
Pivot new_pivot = na
if not na(ph)
new_pivot := Pivot.new(time , bar_index , ph, true)
is_new_pivot := true
else if not na(pl)
new_pivot := Pivot.new(time , bar_index , pl, false)
is_new_pivot := true
This is the structural entry point of the whole toolkit.
The script waits for a confirmed pivot high or pivot low using the chosen pivot length on both sides. Once a pivot is confirmed, it stores the pivot time, bar index, price, and whether it is a high or low.
That pivot then becomes the anchor for all Gann tools. So the entire toolkit is driven by real confirmed turning points rather than by arbitrary chart positions.
2) Storing Recent Active Pivots
if is_new_pivot
active_pivots.unshift(new_pivot)
if active_pivots.size() > i_history + 1
active_pivots.pop()
Whenever a new pivot appears, it is pushed to the front of the active pivot list.
The script keeps only the most recent pivots needed for the selected historical depth. This prevents excessive clutter and ensures that the drawings stay focused on the most relevant recent anchors.
So the toolkit is always working from a controlled pivot memory rather than an unlimited list of old pivots.
3) ATR Based Scaling
float tr_atr = ta.atr(i_atr_len)
float scale_atr = nz(tr_atr, ta.tr) * i_atr_mult
This block creates the ATR based price per bar scale.
The script first calculates ATR over the selected length. That ATR value is then multiplied by the chosen multiplier to produce the scale.
This approach adapts the Gann geometry to current volatility. When ATR expands, the scale expands as well. When ATR contracts, the scale becomes tighter.
So ATR scaling is useful for traders who want the toolkit to stay responsive to the current volatility regime.
4) Chart Range Based Scaling
float price_range = ta.highest(high, i_range_len) - ta.lowest(low, i_range_len)
float scale_chart = price_range / i_range_len
This is the chart range scaling method.
The script measures the total price range across the selected number of bars, then divides that range by the same bar count. The result is an average price per bar scale.
This is often the safest automatic scaling choice because it ties the Gann geometry to the visible chart environment and helps avoid extreme or unrealistic slopes.
So chart range scaling is a balanced default when the user wants a stable visual relationship between price and time.
5) Swing Based Scaling
float scale_swing = na
if active_pivots.size() >= 2
Pivot p_curr = active_pivots.get(0)
Pivot p_prev = active_pivots.get(1)
int bars_diff = math.abs(p_curr.bar_index - p_prev.bar_index)
if bars_diff > 0
scale_swing := math.abs(p_curr.price - p_prev.price) / bars_diff
This method derives scale from the most recent completed pivot to pivot move.
The script measures the price distance between the two latest pivots and divides that by the bar distance between them. The result is a recent swing price per bar ratio.
This makes the Gann angles more sensitive to the latest market structure than the broader chart range method.
So swing scaling is useful when the user wants the geometry to follow the most recent active move more closely.
6) Choosing the Final Active Scale
float current_scale = switch i_scale_method
"Auto (Chart Range)" => scale_chart
"Auto (Swing)" => nz(scale_swing, scale_chart)
"Auto (ATR)" => scale_atr
"Manual" => i_manual_scale
=> i_manual_scale
This is the scale selection engine.
Depending on the user setting, the script picks:
chart range scale,
swing scale,
ATR scale,
or manual scale.
If swing scale is selected but there are not yet enough pivots to calculate it, the script falls back to chart range scale.
This is one of the most important parts of the indicator because all fan angles, box projections, and price projections depend on this final scale value.
7) Gann Fan Slope Logic
array names = array.from("1x8", "1x4", "1x3", "1x2", "1x1", "2x1", "3x1", "4x1", "8x1")
array dy_arr = array.from(1.0, 1.0, 1.0, 1.0, 1.0, 2.0, 3.0, 4.0, 8.0)
array dx_arr = array.from(8.0, 4.0, 3.0, 2.0, 1.0, 1.0, 1.0, 1.0, 1.0)
float slope = dir * scale * (dy_arr.get(i) / dx_arr.get(i))
This is the mathematical foundation of the Gann Fan.
Each fan line is defined by a price over time ratio. For example:
1x1 means one unit of price per one unit of time,
2x1 means two units of price per one unit of time,
1x2 means one unit of price per two units of time.
The script multiplies the selected scale by the angle ratio to produce the actual slope of each line. Direction is positive for low based pivots and negative for high based pivots.
So the fan is not drawn with arbitrary visual angles. It is drawn from a real price per bar relationship.
8) Limiting Fan Projection Distance Safely
float max_y_dist = recent_range <= 0 ? p.price * 0.05 : recent_range * 1.0
float target_y_delta = slope * 100
int safe_bars = 100
if math.abs(target_y_delta) > max_y_dist
safe_bars := int(math.max(1, math.round(max_y_dist / math.abs(slope))))
This safety logic prevents the fan lines from projecting to unrealistic extremes.
The script estimates a maximum reasonable vertical travel based on the recent chart range. If a projected line would travel too far over a standard forward distance, the script shortens the number of bars used for the initial anchor segment.
This helps keep fast angles readable and prevents extreme slopes from distorting the chart.
So the fan remains visually controlled even when scale is large or price is volatile.
9) Drawing the Fan Lines
float future_price = p.price + (slope * safe_bars)
int future_bar = p.bar_index + safe_bars
line ln = line.new(p.bar_index, p.price, future_bar, future_price, color=line_col, style=line.style_solid, extend=extend.right)
Once the slope is known, the script calculates the projected price after a safe number of bars and draws the line from the pivot to that future point. The line is then extended to the right.
This means every fan ray begins from the pivot and continues forward as an active angular support or resistance guide.
10) Gann Box Calculation
float dir = p.is_high ? -1.0 : 1.0
int span = 90
float target_price = p.price + (dir * scale * span)
int target_bar = p.bar_index + span
box bx = box.new(p.bar_index, p.price, target_bar, target_price, border_color=c_box, bgcolor=color.new(c_box, 90), border_style=line.style_dashed)
The Gann Box uses a fixed time width of ninety bars.
The price height of the box is determined by:
scale × ninety
If the anchor is a high pivot, the box projects downward.
If the anchor is a low pivot, the box projects upward.
So the box combines price and time into a balanced projection area using the active scale.
11) Square of 9 Price Projection
float sqrt_p = math.sqrt(p.price)
array offsets = array.from(0.5, 1.0, 1.5, 2.0)
array names = array.from("Sq9 180°", "Sq9 360°", "Sq9 540°", "Sq9 720°")
float new_price = math.pow(sqrt_p + (dir * offsets.get(i)), 2)
This is the core Square of 9 calculation.
The script takes the square root of the pivot price, adds or subtracts a rotational offset, then squares the result again to get the projected price level.
The offsets correspond to:
180°,
360°,
540°,
and 720° style steps.
If the pivot is a high, the offsets project downward.
If the pivot is a low, they project upward.
So the Square of 9 module transforms the pivot price through the classic square root rotation concept associated with Gann price geometry.
12) Drawing Master Time Factor Levels
array intervals = array.from(30, 45, 90, 180)
for i = 0 to intervals.size() - 1
int b_idx = p.bar_index + intervals.get(i)
if b_idx <= bar_index + 100
line ln = line.new(b_idx, p.price, b_idx, p.price * (p.is_high ? 0.95 : 1.05), color=c_mtf, style=line.style_solid, extend=extend.both)
The Master Time Factor module projects important future time counts from the pivot.
The selected intervals are:
30 bars,
45 bars,
90 bars,
and 180 bars.
Each one is drawn as a vertical time marker. These are not price targets by themselves. They are timing references that may align with future reversals, reactions, or acceleration points.
So this module adds the time side of Gann analysis to the toolkit.
13) Gann Retracement Levels
float high_p = math.max(p1.price, p2.price)
float low_p = math.min(p1.price, p2.price)
float rng = high_p - low_p
array percents = array.from(0.125, 0.25, 0.333, 0.50, 0.667, 0.75, 0.875)
array p_names = array.from("12.5%", "25%", "33.3%", "50% (Key)", "66.7%", "75%", "87.5%")
float lvl_price = low_p + (rng * percents.get(i))
This is the retracement engine.
Given two pivots, the script measures the price range between them and then calculates key Gann proportional retracement levels inside that range.
The plotted levels are:
12.5%,
25%,
33.3%,
50%,
66.7%,
75%,
and 87.5%.
The 50% level is emphasized more strongly because it is one of the most widely watched Gann reference levels.
So this module gives the toolkit a proportional price structure layer between two pivot anchors.
14) Gann Swing Chart Logic
bool up_swing = high > high and low > low
bool dn_swing = high < high and low < low
This is the directional trigger for the swing chart.
A bullish swing condition requires both the high and the low of the current bar to be above the previous bar.
A bearish swing condition requires both the high and the low of the current bar to be below the previous bar.
So the swing chart changes direction only when the bar structure shows a clear full shift in both extremes.
15) Starting a New Swing Segment
if up_swing and swing_dir != 1
swing_dir := 1
int start_x = na(last_swing_line) ? bar_index : line.get_x2(last_swing_line)
float start_y = na(last_swing_line) ? low : line.get_y2(last_swing_line)
last_swing_line := line.new(start_x, start_y, bar_index, high, color=c_swg, width=2)
else if dn_swing and swing_dir != -1
swing_dir := -1
int start_x = na(last_swing_line) ? bar_index : line.get_x2(last_swing_line)
float start_y = na(last_swing_line) ? high : line.get_y2(last_swing_line)
last_swing_line := line.new(start_x, start_y, bar_index, low, color=c_swg, width=2)
When the swing direction changes, the script starts a new swing segment.
If the direction turns bullish, it starts a line toward the current high.
If the direction turns bearish, it starts a line toward the current low.
The starting point is either the previous bar’s extreme or the end of the last swing line if one already exists.
So the swing chart forms a connected directional structure rather than isolated markers.
16) Extending the Active Swing Segment
else
if swing_dir == 1 and not na(last_swing_line) and high > line.get_y2(last_swing_line)
line.set_xy2(last_swing_line, bar_index, high)
else if swing_dir == -1 and not na(last_swing_line) and low < line.get_y2(last_swing_line)
line.set_xy2(last_swing_line, bar_index, low)
If the current swing direction stays the same, the script extends the active swing line when a new extreme is made.
For bullish swings, it updates the end of the line to a new higher high.
For bearish swings, it updates the end of the line to a new lower low.
So the swing chart behaves like a live directional staircase that keeps extending until a new opposite swing begins.
17) Using Historical Pivots to Draw Multiple Tool Sets
for i = 0 to math.min(active_pivots.size() - 1, i_history - 1)
Pivot p = active_pivots.get(i)
GannElement f_el = fan_elements.get(i)
GannElement b_el = box_elements.get(i)
GannElement s_el = sq9_elements.get(i)
GannElement m_el = mtf_elements.get(i)
f_el.drawFan(p, current_scale, global_recent_range)
b_el.drawBox(p, current_scale)
s_el.drawSq9(p, current_scale)
m_el.drawMTF(p)
This loop is what makes the toolkit multi layer.
For each recent pivot within the selected history depth, the script redraws the fan, box, Square of 9 levels, and Master Time Factor markers.
So the chart can display tools from several recent pivots at once instead of only the latest anchor.
18) Drawing Retracements From Consecutive Pivots
if active_pivots.size() > i + 1
GannElement r_el = ret_elements.get(i)
Pivot p2 = active_pivots.get(i + 1)
r_el.drawRetracements(p, p2)
Retracements need two pivots, not one.
This block takes each pivot and the next older pivot, then draws the Gann retracement levels between them. That means retracement structure is always built from a real completed price range between two confirmed turning points.
So the retracement module is linked directly to pivot progression rather than floating independently on the chart. Indicateur

Fibonacci Imbalance Zones [JOAT]Fibonacci Imbalance Zones
Introduction
Fibonacci Imbalance Zones is an open-source overlay indicator that merges automatic Fibonacci retracement with Fair Value Gap (FVG) detection and order block identification to find high-probability confluence zones where institutional concepts overlap. When a Fibonacci level aligns with an unmitigated FVG or an active order block, the indicator highlights that zone as a confluence point and optionally generates entry signals. It bridges the gap between classical Fibonacci analysis and modern Smart Money Concepts.
Built with Pine Script v6, the indicator uses custom types for Fibonacci levels, FVG zones, confluence points, swing points, order blocks, and institutional levels.
Why This Indicator Exists
Fibonacci retracement and FVG analysis are both widely used, but they are almost always applied as separate tools. Traders manually eyeball whether a Fibonacci level happens to overlap with an FVG, which is subjective and error-prone. This indicator automates that process by:
Auto-Fibonacci calculation: Automatically identifies the most recent significant swing high and swing low using pivot detection, then draws Fibonacci levels between them — no manual drawing required
FVG lifecycle tracking: Detects bullish and bearish FVGs, filters them by minimum size (ATR-based), tracks mitigation, and classifies them as premium or discount relative to fair value
Confluence detection: Programmatically checks whether any active Fibonacci level falls within a configurable ATR tolerance of any unmitigated FVG or order block, and calculates a confluence strength score
Entry signal generation: When price enters an FVG zone that overlaps with a key Fibonacci level (0.500-0.786 range), the indicator generates a directional entry signal
Core Components Explained
1. Automatic Fibonacci Levels
The indicator uses pivot detection to find the most significant recent swing high and swing low. The pivot strength parameter (default 5) controls how many bars on each side must be lower/higher for a point to qualify as a swing. Once swings are identified, Fibonacci levels are calculated:
calcFibLevel(float swingH, float swingL, float ratio, int direction) =>
float level = na
if direction > 0
level := swingL + (swingH - swingL) * ratio
else
level := swingH - (swingH - swingL) * ratio
level
Standard levels include 0.236, 0.382, 0.500, 0.618, and 0.786, each toggleable independently. Extensions at 1.618 and 2.272 are also available. When harmonic ratios are enabled, additional levels at 0.127, 0.414, 0.707, and 0.886 are drawn, covering the full spectrum of Fibonacci and harmonic trading levels.
Each level is drawn as a dashed line extending from the swing range to the right of the chart, with a label showing the ratio. Harmonic ratios receive a glow effect (thicker line, lower transparency) to visually distinguish them from standard levels.
2. FVG Detection with Premium/Discount Classification
Fair Value Gaps are detected using the standard three-bar pattern: a bullish FVG forms when the current bar's low is above the high from two bars ago. The indicator filters FVGs by a minimum size threshold (default 0.3x ATR) to avoid plotting insignificant gaps.
Each FVG is classified as premium or discount relative to the fair value of the middle candle:
Premium FVG: The gap's midpoint is above fair value — sellers may have an edge
Discount FVG: The gap's midpoint is below fair value — buyers may have an edge
FVGs are drawn as colored boxes. Premium FVGs use a gold color, discount FVGs use cyan, and neutral FVGs use the standard bull/bear colors. When mitigation tracking is enabled, the indicator monitors each FVG and updates its visual style (dotted border, faded color) when price fills the gap's midpoint.
Chart showing auto-drawn Fibonacci levels between swing high and swing low, with FVG boxes classified as premium (gold) and discount (cyan), and confluence diamonds where Fibonacci levels overlap with FVGs
3. Order Block Detection
The indicator identifies order blocks as the last opposing candle before a significant swing point, filtered by volume. A bullish order block is the last bearish candle before a swing high, but only if the volume on that candle exceeds 1.5x the 20-period volume average. This volume filter ensures that only institutionally significant order blocks are tracked.
Order blocks are drawn as semi-transparent boxes and monitored for sweeps. When price breaks through an order block, it is marked as swept and its visual is updated to a neutral, dotted style.
4. Confluence Detection Engine
The confluence engine is the core innovation of this indicator. It iterates through all active Fibonacci levels and checks each one against all unmitigated FVGs and active order blocks:
tolerance = atrVal * confluenceTol
for fib in fibLevels
if fib.isActive
for fvg in fvgZones
if not fvg.isMitigated
if math.abs(fib.price - fvg.mid) < tolerance
confStrength += 1
Each confluence point receives a strength score based on how many factors align:
Fibonacci level + FVG = base confluence
Add +1 if the Fibonacci level is a harmonic ratio (0.382, 0.618, etc.)
Add +1 if the FVG is in the premium or discount zone
Add +1 if the FVG has above-average volume
Add +1 if an order block also overlaps
Confluence points are drawn as labeled boxes showing which factors are present (e.g., "Harmonic+Discount+Volume"). A minimum confluence strength threshold (default 2) filters out weak confluences.
5. Entry Signal Generation
When entry signals are enabled, the indicator generates a bullish entry when price enters a bullish FVG zone that overlaps with a Fibonacci level in the 0.500-0.786 range (the "golden pocket") and the current candle closes bullish. The bearish entry is the inverse. These signals are plotted as circles below (bullish) or above (bearish) the price bars.
Visual Elements
Fibonacci Lines: Dashed lines at each active ratio with labels, harmonic ratios get glow effect
FVG Boxes: Color-coded by direction and premium/discount status, updated on mitigation
Order Block Boxes: Semi-transparent boxes with sweep tracking
Confluence Boxes: Highlighted zones where Fibonacci and FVG/OB overlap, with strength labels
Entry Signals: Circle markers for bullish/bearish entries at confluence zones
Structure Line: Line connecting the swing high and swing low
Background Coloring: Subtle trend-direction background tint
Dashboard: Displays current Fibonacci range, trend direction, active FVG count, confluence count, and entry status
Input Parameters
Fibonacci Settings:
Swing Lookback (default 50) and Pivot Strength (default 5)
Toggle each standard level (0.236, 0.382, 0.500, 0.618, 0.786) and extensions
FVG Detection:
FVG Max Age (default 50 bars)
Track Mitigation toggle
Min FVG Size (default 0.3 ATR)
Confluence Settings:
Confluence Tolerance (default 0.3 ATR)
Show Entry Signals and Confluence Strength
Min Confluence Strength (default 2)
Advanced Fibonacci:
Show Harmonic Ratios (0.127, 0.414, 0.707, 0.886)
Show Institutional Levels (volume-based levels near swings)
Show Smart Money Concepts and Order Blocks
Show Premium/Discount classification
Visual Settings:
Color Scheme: Quantum, Classic, Professional, or Minimal
Show Structure Lines, Dashboard, Glow Effects, Animation
Max Visual Elements (default 30)
How to Use This Indicator
Step 1: Let the indicator automatically identify the current swing range and draw Fibonacci levels. The structure line shows the swing high to swing low connection.
Step 2: Identify the trend direction from the structure line. In an uptrend (swing low formed after swing high), look for bullish setups at discount Fibonacci levels (0.618, 0.786). In a downtrend, look for bearish setups at premium levels.
Step 3: Watch for confluence diamonds. When a Fibonacci level overlaps with an unmitigated FVG, the confluence box appears. Higher strength confluences (3+) are more significant.
Step 4: If entry signals are enabled, wait for price to enter the confluence zone and print a confirming candle (bullish close for longs, bearish close for shorts).
Step 5: Use order blocks within the confluence zone as precise entry levels. The order block's range provides a natural stop-loss area (below the OB for longs, above for shorts).
Close-up of a high-strength confluence zone showing a 0.618 Fibonacci level overlapping with a discount FVG and a bullish order block, with an entry signal circle below the bar
Indicator Limitations
Automatic Fibonacci levels depend on pivot detection, which has an inherent delay. The swing points update only after the pivot is confirmed.
Fibonacci levels are drawn between the two most recent significant swings. In choppy markets with many equal swings, the selected range may not be the most relevant one.
FVG detection uses the standard three-bar pattern, which can produce many gaps on volatile instruments. Use the minimum size filter to manage this.
Confluence detection is proximity-based. A Fibonacci level near an FVG does not guarantee a price reaction — it identifies a zone of potential interest.
Entry signals are mechanical and do not account for broader market context. They should be used as alerts for further analysis, not as standalone trade triggers.
The indicator draws many visual elements. On busy charts, consider using the Max Visual Elements setting and disabling less critical features.
Originality Statement
This indicator is original in its automated confluence detection between Fibonacci analysis and Smart Money Concepts. While Fibonacci tools and FVG indicators exist separately, this indicator is justified because:
It programmatically detects overlap between Fibonacci levels and FVG zones, eliminating subjective visual assessment
The confluence strength scoring system quantifies how many institutional factors align at each zone
Premium/discount FVG classification adds a fair-value context layer to standard FVG detection
Volume-filtered order block detection integrated with Fibonacci levels creates a three-way confluence system
Harmonic ratio support extends beyond standard Fibonacci to cover the full spectrum of institutional trading levels
The entry signal system combines Fibonacci position, FVG presence, and candle confirmation into a structured trigger
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice or a recommendation to buy or sell any financial instrument. Trading involves substantial risk of loss. Fibonacci levels and FVG analysis are interpretive tools, not predictive guarantees. Always use proper risk management. The author is not responsible for any losses incurred from using this indicator.
-Made with passion by officialjackofalltrades
Indicateur

Indicateur

Fractal Retracement [Jamallo](2025)
Intro
FRAMA is a moving average that adapts its speed based on fractal geometry — specifically, the fractal dimension (D) of recent price action. When price is trending strongly (low fractal dimension), it moves fast. When price is choppy/ranging (high fractal dimension), it slows down. This makes it far more responsive than a standard EMA or SMA.
Breakdown:
The indicator wraps this with a continuous range logic layer: the filtered line = k only moves if price breaks beyond the FRAMA ± ATR-based range, creating a stepped/ratcheting effect that filters out noise.
Two sets of bands are plotted around the filtered line, scaled by ATR multiplied by user-defined multipliers (tight at 0.5×, medium at 1.0×). They're smoothed with a short EMA to reduce jitter, and filled with gradient colors for visual clarity.
Direction is simply determined by whether k is rising or falling, and colors everything green (uptrend) or pink/red (downtrend).
END
In short, it's a noise-filtered trend indicator useful for identifying trend direction, dynamic support/resistance , and gauging how far price has retraced from the trend baseline. Indicateur

Indicateur

Fibonacci Confluence Grids (Levels + Time Zones) [Metrify]This script is built around a simple but often-misused idea: Fibonacci levels are only useful when the reference swing is meaningful. In practice, most traders do not fail because they “used the wrong ratio,” but because they anchored the Fib to a weak or inconsistent swing. A 0.618 level drawn from noise is still noise.
The core design of this indicator is therefore not “draw more levels” but to formalize three simple steps that we usually do inconsistently by eye:
identify an A→B swing,
filter that swing for significance, and
project both price levels and timing windows from that swing.
Once a valid swing is accepted, the script projects a configurable set of price Fibonacci levels (retracements and/or extensions) and a separate configurable sequence of time gates (bar offsets projected forward from point B). The price levels define a vertical map of potential reaction zones. The time gates define a horizontal map of potential timing windows. Used together, they create a 2D framework: not only where price may become sensitive, but also when the probability of a market event tends to increase.
Time gates: temporal structure and why “events cluster” around them
The time gate projects vertical markers forward from point B using a bar sequence (commonly Fibonacci-like). The key idea is not random, but practical timing structure.
Markets often exhibit rhythm: impulsive legs, pullbacks, consolidations, and expansions frequently have characteristic durations.
Time gates should be interpreted as attention windows: periods where you should expect the probability of a notable market event to be higher than usual. “Event” here is intentionally broad, because direction is not guaranteed:
acceleration / continuation burst
pullback completion and resumption attempt
volatility expansion after compression
reversal attempt (successful or failed)
fakeout / stop run / liquidity sweep
structural break and regime shift
This is why it’s accurate to say that significant events often occur around time gates. Not because the gate forces a reversal, but because it’s a timing checkpoint where participation and auction dynamics frequently change. Your edge comes from combining the gate with context: price location near a major Fib level, session behavior, and confirmation from price action/structure.
How to use it as a manual framework
A strong discretionary workflow is to treat this as a 2D confluence map: price zone × time window.
Start by asking: “Is the active A→B swing meaningful?” If it looks like chop, tighten filters (increase Min Size / Min Bars, or increase ZigZag reversal / pivot length). Once the swing quality is good, treat the map as a set of planned observation points.
When price approaches a major retracement (0.5/0.618/0.786) or extension (1.272/1.618), check whether a time gate is also nearby. If yes, you should expect higher information density so you watch for confirmation rather than forcing prediction.
Confirmation can be whatever your style uses: structure break, reclaim, rejection candle quality, volatility expansion, etc.
If price is mid-range (far from major fibs) and far from gates, that’s often low-quality territory for forcing trades —> your standards should be higher, not lower. Indicateur

Midnight Open Retracement [LuxAlgo]The Midnight Open Retracement indicator highlights the 12:00 AM ET opening price and provides real-time probability statistics for price retracing to this level during the New York session.
Designed specifically with NQ (Nasdaq 100) futures data in mind, the tool helps traders identify high-probability "magnet" levels for New York open scalps based on historical performance.
🔶 USAGE
The Midnight Open is a cornerstone of ICT concepts, acting as a "true" daily open that often serves as a point of institutional re-accumulation or distribution. This script automates the identification of this level and provides a dashboard to help traders decide when to expect a retracement.
🔹 Identifying the Bias
The script compares the New York opening price (9:30 AM ET) to the Midnight opening price:
If NY opens above the Midnight Open, the indicator identifies a potential bearish retracement bias toward the level. If NY opens below the Midnight Open, the indicator identifies a potential bullish retracement bias toward the level.
🔹 Using as a Profit Target
Because the Midnight Open is retraced to frequently, it serves as an ideal Take Profit (TP) target for opening range scalps. The indicator marks the exact moment a retracement occurs with a visual marker, confirming the level has been tested.
🔶 DETAILS
The statistics integrated into this tool are based on extensive backtesting of NQ futures over 6-month periods. Understanding these probabilities allows traders to filter out low-conviction setups and focus on high-probability days.
🔹 The Core Probabilities
When price opens above the midnight level, it retraces to touch it 74% of the time. When price opens below the midnight level, it retraces to touch it 63% of the time.
🔹 Weekday Variance
Not all trading days are equal. The script accounts for "By Weekday" statistics:
High Probability (Wednesdays): On Wednesdays, retracement probabilities can jump as high as 89% for opens above the midnight level. Low Probability (Mondays): Mondays often exhibit "Avoid" criteria, with retracement probabilities frequently falling below 60%.
The dashboard dynamically updates the "Probability of Retracement" based on the current day of the week, helping you stay aligned with historical data.
🔶 SETTINGS
🔹 Session Settings
Timezone Mode: Choose between Exchange time or "America/New_York" (recommended for ICT concepts). Midnight Open Time: The specific time used to set the daily baseline. NY Open Time: The time used to determine the session opening bias. NY Session Range: Defines the boundary for the New York session box.
🔹 Visual Settings
Show Midnight Level: Toggles the horizontal line representing the midnight price. Show Retrace Circle: Displays markers on the chart when the retracement goal is met. Show NY Session Box: Draws a dynamic box for the NY session that changes color based on the current price relative to the open.
🔹 Dashboard Settings
Show Insights Report: Toggles the statistics dashboard on the chart. Position/Size: Controls the UI placement and scale of the data table. Indicateur

Indicateur

Retracement Strategy [OmegaTools]Retracement Strategy is a systematic trend–retracement framework designed to identify directional opportunities after a confirmed momentum shift, and to manage exits using either trend reversals or overextension conditions. It is built around a smoothed RSI regime filter and a simple, price-based retracement trigger, making it applicable across a wide range of markets and timeframes while remaining transparent and easy to interpret.
The strategy begins by defining the underlying trend through a two-stage RSI signal. A standard RSI is computed over the user-defined Length input, then smoothed with a short moving average to reduce noise. Two symmetric thresholds are derived from the Threshold parameter: an upper band at 100 minus the threshold and a lower band at the threshold itself. When the smoothed RSI crosses above the upper band, the environment is classified as bullish and the internal trend state is set to uptrend. When the smoothed RSI crosses below the lower band, the environment is classified as bearish and the trend state becomes downtrend. When RSI moves back into the central zone between the two bands, the trend is considered neutral. In addition to the current trend, the strategy tracks the last non-neutral trend direction, which is used to detect genuine trend changes rather than transient oscillations.
Once a trend is established, the strategy looks for retracement entries in the direction of that trend. For long setups in an uptrend, it computes the lowest low over the previous Length minus one bars, excluding the current bar. A long signal is generated when price dips below this recent low while the trend state remains bullish. Symmetrically, for short setups in a downtrend, it computes the highest high over the previous Length minus one bars and enters short when price spikes above this recent high while the trend state remains bearish. This logic is designed to capture pullbacks against the prevailing RSI-defined trend, entering when the market tests or slightly violates recent extremes, rather than chasing breakouts. The candles are visually coloured to reflect the detected trend, highlighting bullish and bearish environments while keeping neutral phases distinguishable on the chart. An ATR-based measure is used solely to position the “UP” and “DN” labels on the chart for clearer visualisation of entry points; it does not directly influence position sizing or stop calculation in this implementation.
Take profit and stop loss behaviour are fully parameterized through the “Take Profit” and “Stop Loss” inputs, each offering three modes: None, Trend Change and Extension. When “Trend Change” is selected for the take profit, the strategy will only exit profitable positions when a confirmed trend reversal occurs. For a long position, this means that the strategy will close the trade when the trend state flips from uptrend to downtrend, and the last recorded trend direction validates that this is a genuine reversal rather than a neutral fluctuation; the same logic applies symmetrically for short positions. When “Extension” is selected as the take profit mode, the strategy closes profitable long trades when the smoothed RSI reaches or exceeds the upper threshold, interpreted as an overbought extension within the bullish regime, and closes profitable short trades when the smoothed RSI falls to or below the lower threshold, interpreted as an oversold extension within the bearish regime. When “None” is chosen, the strategy does not apply any explicit take profit logic, leaving trades to be managed by the stop loss settings or by user discretion in backtesting.
The stop loss parameter works in a parallel way. With “Trend Change” selected as stop loss, any open long position is closed when the trend flips from uptrend to downtrend, regardless of whether the trade is currently in profit or loss, and any open short is closed when the trend flips from downtrend to uptrend. This turns the RSI trend regime into a hard invalidation rule: once the underlying momentum structure reverses, the position is exited. With “Extension” selected for stop loss, long positions are closed when RSI falls back below the upper band and moves towards the opposite side of the range, while short positions are closed when RSI rises above the lower band and moves towards the upper side. In practice, this acts as a dynamic exit based on the oscillator moving out of a favourable context for the existing trade. Selecting “None” for stop loss disables these automatic exits, leaving only the take profit logic, if any, to manage the position. Because take profit and stop loss configuration are independent, the user can construct different profiles, such as pure trend-change exits on both sides, pure overextension exits, or a mix (for example, take profit on overextension and stop loss on trend reversal).
This strategy is designed as an analytical and backtesting framework rather than a finished plug-and-play trading system. It does not include position sizing, risk-per-trade controls, multi-timeframe confirmation, volatility filters or instrument-specific fine-tuning. Its primary purpose is to provide a clear, rule-based structure for testing retracement logic within RSI-defined trends, and to allow users to explore how different exit regimes (trend-change based versus extension based) affect performance on their instruments and timeframes of interest.
Nothing in this script or its description should be interpreted as financial advice, investment recommendation or solicitation to buy or sell any financial instrument. Past performance on backtests does not guarantee future results. The behaviour of this strategy can vary significantly across symbols, timeframes and market conditions, and correlations, volatility and liquidity can change without warning. Before considering any live application, users should thoroughly backtest and forward test the strategy on their own data, adjust parameters to their risk profile and instrument characteristics, and integrate proper money management and trade management rules. Use of this script is entirely at the user’s own risk.
Stratégie

Metallic Retracement LevelsThere's something that's always bothered me about how traders use Fibonacci retracements. Everyone treats the golden ratio like it's the only game in town, but mathematically speaking, it's completely arbitrary. The golden ratio is just the first member of an infinite family of metallic means, and there's no particular reason why 1.618 should be special for markets when we have the silver ratio at 2.414, the bronze ratio at 3.303, and literally every other metallic mean extending to infinity. We just picked one and decided it was magical.
The metallic means are a sequence of mathematical constants that generalize the golden ratio. They're defined by the equation x² = kx + 1, where k is any positive integer. When k equals 1, you get the golden ratio. When k equals 2, you get the silver ratio. When k equals 3, you get bronze, and so on forever. Each metallic mean generates its own set of ratios through successive powers, just like how the golden ratio gives you 0.618, 0.382, 0.236 and so forth. The silver ratio produces a completely different set of retracement levels, as does bronze, as does any arbitrary metallic number you want to choose.
This indicator calculates these metallic means using the standard alpha and beta formulas. For any metallic number k, alpha equals (k + sqrt(k² + 4)) / 2, and we generate retracement ratios by raising alpha to various negative powers. The script algorithmically generates these levels instead of hardcoding them, which is how it should have been done from the start. It's genuinely silly that most fib tools just hardcode the ratios when the math to generate them is straightforward. Even worse, traditional fib retracements use 0.5 as a level, which isn't even a fibonacci ratio. It's just thrown in there because it seems like it should be important.
The indicator works by first detecting swing points using the Sylvain Zig-Zag . The zig-zag identifies significant price swings by combining percentage change with ATR adjustments, filtering out noise and connecting major pivot points. This is what drives the retracement levels. Once a new swing is confirmed, the script calculates the range between the last two pivot points and generates metallic retracement levels from the most recent swing low or high.
You can adjust which metallic number to use (golden, silver, bronze, or any positive integer), control how many power ratios to display above and below the 1.0 level, and set how many complete retracement cycles you want drawn. The levels extend from the swing point and show you where price might react based on whichever metallic mean you've selected. The zig-zag settings let you tune the sensitivity of swing detection through ATR period, ATR multiplier, percentage reversal, and additional absolute or tick-based reversal values.
What this really demonstrates is that retracement analysis is more flexible than most traders realize. There's no mathematical law that says markets must respect the golden ratio over any other metallic mean. They're all valid mathematical constructs with the same kind of recursive properties. By making this tool, I wanted to highlight that using fibonacci retracements involves an arbitrary choice, and maybe that choice should be more deliberate or at least tested against alternatives. You can experiment with different metallic numbers and see which ones seem to work better for your particular market or timeframe, or just use this to understand that the standard fib levels everyone uses aren't as fundamental as they appear. Indicateur

Script_Algo - Fibo Correction Strategy🔹 Core Concept
The strategy is built on combining Fibonacci retracement levels, candlestick pattern confirmation, and trend filtering for trade selection. It performs well on the 1-hour timeframe across many cryptocurrency pairs. Particularly on LINKUSDT over the past year and a half, despite the not very optimal 1:1 risk/reward ratio.
The logic is simple: after a strong impulse move, the price often retraces to key Fibonacci levels (specifically, the 61.8% level). If a confirming candlestick (pattern) appears at this moment, the strategy looks for an entry in the direction of the main trend.
🔹 Indicators Used in the Strategy
ATR (Average True Range) — Used to calculate the stop-loss and take-profit levels.
EMA (9 and 21) — Additional moving averages for assessing the direction of movement (not directly used in entry conditions, but the logic can be expanded to include them).
SMA (Trend Filter, 20 by default) — The trend direction filter. Trades are only opened in its direction.
Fibonacci Levels — The 61.8% retracement level is calculated based on the high and low of the previous candle.
🔹 Entry Conditions
🟢 Long (Buy):
Previous Candle:
Must be green (close higher than open).
Must have a body not smaller than a specified minimum.
The upper wick must not exceed 30% of the body size.
→ This filters out "weak" or "indecisive" candles.
Current Candle:
Price touches or breaches the Fibonacci 61.8% retracement level from the previous range.
Closes above this level.
Closes above the Trend Filter (SMA) line.
A position is opened only if there are no other open trades at the moment.
🔴 Short (Sell):
Previous Candle:
Must be red (close lower than open).
Must have a body not smaller than a specified minimum.
The lower wick must not exceed 30% of the body size.
Current Candle:
Price touches or breaches the Fibonacci 61.8% retracement level from the previous range.
Closes below this level.
Closes below the Trend Filter (SMA) line.
A trade is opened only if there are no other open positions.
🔹 Risk Management
Stop-Loss = ATR × multiplier (default is 5).
Take-Profit = ATR × the same multiplier.
Thus, the default risk/reward ratio is 1:1, but it can be easily adjusted by changing the coefficient. Although, strangely enough, this ratio has shown the best results on some assets on the 1-hour timeframe.
🔹 Chart Visualization
Fibonacci level for Long — Green line with circles.
Fibonacci level for Short — Red line with circles.
Trend Filter line (SMA) — Blue.
🔹 Strengths of the Strategy
✅ Utilizes a proven market pattern — retracement to the 61.8% level.
✅ Further filters entries using trend and candlestick patterns.
✅ Simple, transparent logic that is easy to expand (e.g., adding other Fib levels, an EMA filter, etc.).
🔹 Limitations
⚠️ Performs better in trending markets; can generate false signals during ranging (sideways) conditions.
⚠️ The fixed 1:1 risk/reward ratio is not always optimal and could be refined.
⚠️ Performance depends on the selected timeframe and ATR parameters.
📌 Summary:
The strategy seeks corrective entries in the direction of the trend, confirmed by candlestick patterns. It is versatile and can be applied to forex pairs, cryptocurrencies, and stocks.
⚠️ Not financial advice. Pay close attention to risk management to avoid blowing your account. The strategy is not repainting — I have personally verified it through real testing — but it may not necessarily replicate the same results in the future, as the market is constantly changing. Test it, profit, and good luck to everyone! Stratégie

Smart Directional Fib Zone (Selectable Session)🎯 Overview
This indicator plots a dynamic Fibonacci zone between the 0.5 and 0.618 levels , calculated from the previous day’s price action , and is designed specifically for intraday traders.
It visually highlights key retracement or reaction areas where the market often pauses or reverses.
🔍 How it works
At the start of each day, the script automatically captures:
the previous day’s open (pdo),
high (pdh),
low (pdl),
and close (pdc).
It then determines if the previous day was bullish (Close > Open) or bearish (Close < Open).
Based on that:
If the previous day was bullish, it projects the Fibonacci levels down from the high (typical for expecting retracements).
If bearish, it projects them up from the low.
The two key levels are:
0.5 (50%) retracement / projection
0.618 (61.8%) retracement / projection
A colored zone is plotted between these levels to act as a leading guide for intraday setups.
⏰ Time filtering & session customization
A unique feature is the dynamic session filtering:
By default, the zone is only plotted during active market hours, keeping your chart clean outside trading hours.
The script provides a dropdown selector so you can quickly switch between:
India session (9:15 to 15:30)
Europe session (9:00 to 17:30)
US session (9:30 to 16:00)
Or even define your own custom session times.
This makes it ideal for intraday traders in any region.
🎨 Visual features
The fill zone changes color based on the previous day’s sentiment:
Green zone if the previous day was bullish
Red zone if the previous day was bearish
🚨 Alerts
The script includes an alert condition, so you can easily set up TradingView alerts to notify you when:
Price enters the Fibonacci zone.
This is extremely helpful for catching retracements or reversals without staring at the screen all day.
⚙️ How to use
✅ Works on any intraday timeframe (1 min, 5 min, 15 min, etc.).
✅ Simply add it to your chart, pick your session in the dropdown, and watch the Fibonacci zone automatically adjust to your selected market hours.
Use it as a confluence tool alongside other indicators like VWAP, EMAs, Bollinger Bands, or price action patterns to time entries and exits.
💪 Why this is powerful
This is more than a simple Fib retracement tool:
It dynamically adapts to the previous day’s sentiment, helping you trade in alignment with recent market psychology.
The session filtering ensures your charts are focused only on the periods Indicateur
