Indicator

Gap AnalysisDescription:
This indicator automates the tracking of session gaps, providing real-time data on gap fills, historical context, and exhaustion risk. It is built specifically for day traders and swing traders who use gap-fill strategies during Regular Trading Hours (RTH).
Core Functionality:
The script captures the closing price (settle) of the previous RTH session and measures it against the open of the current RTH session. If a gap exceeds your minimum point threshold, it maps the gap zone on your chart and tracks price action against the settle line until the gap is filled.
Key Features:
Dynamic Fill Tracking: Monitors unfilled gaps bar-by-bar. It calculates the exact percentage of the gap filled and displays how many bars it took to reach completion.
Exhaustion Risk Detection: Tracks consecutive gaps in the same direction. If the market gaps in the same direction three or more times consecutively, the script flags an "Elevated Exhaustion" risk on the display panel.
Clean Chart Management: Automatically shades the gap zone and draws the target settle line. You can toggle a setting to instantly hide gaps once they are 100% filled, preventing chart clutter.
Heads-Up Display Table: An on-chart dashboard provides immediate access to the current session's gap direction, fill status, specific target price, and elapsed time.
Historical Gap Review: Displays up to 20 historical session gaps, allowing you to backtest how often and how quickly an asset fills its gaps.
Integrated Alerts: Supports automated alerts for two conditions: when a new qualifying gap is formed at the session open, and the moment a gap is entirely filled.
Configuration & Setup:
RTH Session: Define your specific trading hours (default is 0830-1500 America/Chicago). The indicator requires this to accurately lock in the previous day's settle.
Minimum Gap Size: Filter out market noise by setting a minimum point threshold. Gaps smaller than this value will be ignored.
Visual Customization: Full control over bull/bear zone colors, line styles, text sizes, and table positioning.
Usage Notes:
This script relies on timeframe data to establish session boundaries. It is optimal for intraday timeframes (e.g., 1m, 5m, 15m, 1H). Indicator

Gap Analyzer[KG] Overview:
Gap Analyzer is a statistical research tool that scans every bar on your chart, identifies significant gap-down and gap-up events beyond a user-defined threshold, and summarizes what historically happens inside those gap bars — from open to high, open to low, and open to close.
What is a Gap?
A gap occurs when a bar's open is meaningfully higher or lower than the prior bar's close, leaving an empty zone on the chart with no traded price. This indicator flags:
Gap Down — when (Open − Prior Close) / Prior Close × 100 is at or below your threshold (default: −1%)
Gap Up — when the same calculation is at or above your threshold (default: +1%)
Visual Markers on the Chart:
Every qualifying gap is marked directly on the price pane with three layers:
Gap Zone Box — a semi-transparent dashed box fills the exact price area between the prior close and the current open, making the gap size immediately visible
Bar Highlight — a subtle background tint on the gap bar itself (red for gap down, teal for gap up)
Arrow + Label — a triangle arrow above/below the bar paired with the exact gap percentage printed inside the gap zone box (e.g. −6.43% or +5.91%)
Statistical Tables:
Two summary tables are rendered in the price pane — one for gap downs (bottom right by default) and one for gap ups (opposite corner). Each table contains 10 columns across 3 rows:
Gap Down Table:
Column Meaning Coun Total number of gap-down bars detectedΦGapAverage gap size across all qualifying bars O>C %% of gap-down bars that closed bearish (continuation) ΦO→HAverage % move from Open to High on continuation barsΦO→LAverage % move from Open to Low on continuation bars ΦO→CAverage % move from Open to Close on continuation bars O C)
All percentage values are colour-coded — teal for positive, red for negative — for instant readability.
The Φ Notation-
The symbol Φ (Phi) denotes an average (mean) across all qualifying bars in that category. So ΦO→H means "the average percentage move from the Open to the High across all gap bars in this group" — a measure of how much intraday upside was available on average after the gap open.
Inputs:
Input Default Description Gap-Down Threshold−5%Minimum gap size to qualify as a gap down Gap-Up Threshold+5%Minimum gap size to qualify as a gap up Table Position Bottom Right Where to anchor the gap-down table (gap-up table auto-mirrors) Show Gap % Label On Toggles the arrow and % label on each gap bar
Use Cases:
Intraday traders — know statistically how far price tends to travel from open toward the high or low after a gap, helping size entries and targets
Swing traders — quickly assess whether gaps on your instrument tend to fill (bounce) or continue, and by how much on average
Back testing context — apply to any timeframe and ticker to build a historical gap behavior profile before trading a live gap event
Notes:
Works on any ticker and any timeframe
All statistics are computed from the full visible history loaded on the chart; extending your chart history will give more robust sample sizes
Past statistical behavior does not guarantee future results — use as context, not as a signal in isolation Indicator

Indicator

Strategy

Indicator

Indicator

Indicator

Indicator

Strategy

Indicator

Indicator

Indicator

Indicator

Indicator

Indicator

Indicator
