Sigma Structure [RWCS]What it is:
Sigma Structure is a confluence-based trading indicator that unifies three distinct analytical layers into a single, cohesive view: a Z-Score oscillator measuring price deviation from its 20 EMA, a normalized MACD histogram for momentum context, and an Order Block detection engine that identifies structural demand and supply zones directly on the price chart. The result is an indicator that tells you not just when price is statistically extended, but where that extension is occurring relative to meaningful price structure — giving every signal a location and every location a statistical weight.
How it works:
1. Z-Score layer: Price is measured as the number of standard deviations it sits above or below its 20-period EMA. This produces an oscillator that reads consistently across any asset or timeframe — a reading of +2 on Bitcoin means the same thing structurally as +2 on the S&P or EURUSD. The line color intensifies from faded to full aqua as it moves above zero, and faded to full fuchsia below, so the degree of extension is immediately legible at a glance. Fixed bands at ±1, ±2, and ±3 sigma define the statistical landscape.
2. MACD layer: A standard MACD histogram is computed normally, then linearly scaled so its rolling peak aligns with the ±3σ band. No calculation is modified — only the display axis is shared with the Z-Score. This means crossovers, divergences, and momentum shifts read identically to a standard MACD, but now live in the same visual space as the bands, letting you see momentum and mean-reversion context simultaneously.
3. Order Block layer: The indicator scans for order blocks using a sequential candle method — a bearish candle followed by a configurable number of consecutive bullish candles (demand), or a bullish candle followed by consecutive bearish candles (supply). Detected zones are drawn directly on the price chart as shaded regions with solid top boundaries and dashed bottom boundaries, color-coded aqua for demand and fuchsia for supply. Zones extend rightward bar by bar and self-invalidate the moment price closes through them, so what you see on the chart is always live and relevant.
4. Confluence signals: Two signal types fire when the Z-Score and Order Block layers align. An OB Reversal label appears when price is inside an Order Block while the Z-Score is at or beyond ±2σ — the statistical extension and the structural level are confirming each other as a fade opportunity. An OB Continuation label appears when price pulls back into an Order Block and the Z-Score reclaims zero — the trend is reasserting after a mean-reversion dip into demand or supply.
5. Volatility divergence: A background highlight layer compares price's rolling highs and lows against the rolling highs and lows of realized volatility (standard deviation of log returns). When price makes a new low without a corresponding expansion in realized volatility, a bullish divergence is flagged. The inverse flags bearish divergence. These are not entry signals on their own — they indicate moments where price action and volatility are telling different stories and warrant closer attention.
Possible ways to use it:
1. Reversal setups: When the Z-Score reaches ±2σ or beyond and price simultaneously tags an active Order Block zone, the statistical extension and structural level are aligned. The OB Reversal label marks these bars. Look for MACD histogram compression or a zero cross in the same window for additional confirmation before acting.
2. Trend continuation entries: In trending markets, price frequently pulls back into demand or supply zones and finds support exactly where it should. When the Z-Score crosses back through zero inside an active zone, the OB Continuation label fires — this is your structural retest with momentum confirmation.
3. Divergence as a filter: The volatility divergence highlights flag potential exhaustion in price moves that lack volatility confirmation. Use these as a reason to tighten risk or wait for the OB/Z-Score confluence before entering, rather than chasing the move.
4. EMA trend bias: The fast and slow EMA overlay on the price chart provides a quick structural read. Aligning your OB Reversal or Continuation signals in the direction of the EMA cross adds a higher-timeframe trend filter without requiring a second indicator.
5. Alert-driven scanning: Three configurable alerts cover the ±2σ Trade Zone cross, OB Reversal confluence, and OB Continuation setup. Set these across a watchlist to surface actionable conditions without manual chart monitoring.
Settings guide:
1. EMA / Std Dev Length: Both default to 20, matching a standard Bollinger Band configuration. Increase for smoother, slower signals on higher timeframes.
2. MACD Norm Lookback: Controls how far back the indicator looks to find the MACD histogram's peak for scaling. Higher values produce more stable scaling; lower values make the histogram more reactive to recent momentum.
3. Sequential Candles for OB: The number of consecutive candles required after the origin candle to confirm a block. Higher values produce fewer, higher-quality zones.
4. Max Active Zones: How many demand and supply zones can coexist on each side. Older zones are removed when the limit is reached.
5. Divergence Lookback: The rolling window for comparing price extremes against volatility extremes. Shorter values produce more frequent signals; longer values are more selective.
Disclaimer:
This indicator is published for educational and informational purposes only. Nothing presented here constitutes financial advice, a solicitation, or a recommendation to buy or sell any financial instrument. All trading involves risk, including the possible loss of principal. Past performance of any indicator or methodology is not indicative of future results. You are solely responsible for your own trading decisions. Always conduct your own research and consult a qualified financial professional before making any investment decisions. Indicator

Conflux 4 | AnonycryptousConflux 4 | Anonycryptous
Description & user manual
Why this indicator is different
Most signal indicators fire on one condition. Price crosses a moving average. RSI hits a level. A candle closes above a line. One condition. One trigger. And because one condition alone is never enough, the signals come constantly — in trends, against trends, in chop, in news spikes — with no filter for whether the setup actually makes sense.
Conflux 4 works differently.
It does not fire on one condition. It requires four independent filters to agree at the same moment, in the same direction, before anything appears on the chart. Trend, momentum, volatility structure, and trend strength. All four. If one filter disagrees, nothing is drawn. Not a reduced signal. Nothing.
The result is an indicator that is quiet most of the time — and deliberate when it speaks.
When a signal does appear, Conflux 4 does not just mark a dot and leave you to figure out the rest. It draws a complete trade block automatically: entry, stop, and up to four take profit levels. The stop trails dynamically after the first target is reached, moving to breakeven and continuing from there. The trade is managed visually until it resolves.
The dashboard shows the live state of every filter at all times, so you always know why a signal appeared — or why it did not.
Important notice
Conflux 4 generates signals based on technical filter alignment.
These signals are not financial advice.
They do not predict the future.
They do not guarantee profitability.
All trading decisions are made entirely by the user.
Always manage your own risk. Always apply your own judgment.
1. Overview
Conflux 4 is a four-filter confluence signal indicator. A signal only fires when all four filters align simultaneously in the same direction. When that happens, a complete trade block is drawn including entry, stop, and take profit levels.
What it includes:
- Four-filter confluence engine: trend, momentum, volatility structure, and trend strength
- Four presets: scalp, daytrader, swing, and manual
- Three stop modes: Supertrend trailing, ATR cap, and fixed percentage
- Automatic trade block with up to four take profit levels
- Dynamic trailing stop that activates after TP1 and moves to breakeven
- Live dashboard showing the state of every filter in real time
- Configurable signal cooldown, bar coloring, and background shading
- Alerts for bullish and bearish signal events
2. The four filters
A signal is only valid when all four conditions align.
2.1 Trend filter — VWMA and EMA alignment
Price must be above the volume weighted moving average and the fast EMA must be above the slow EMA for a bullish signal. Reverse for bearish. This confirms alignment with the prevailing macro trend before anything else is evaluated.
2.2 Momentum filter — RSI threshold
RSI must be above the configured bullish threshold (default 55) for long signals, or below the bearish threshold (default 45) for short signals. This filters out setups forming in low-momentum environments where follow-through is less reliable.
2.3 Volatility filter — Supertrend
The Supertrend indicator must confirm the same direction as the trend filter. Because Supertrend adapts to volatility using ATR, it naturally avoids triggering during minor fluctuations and choppy price action.
2.4 Trend strength filter — ADX
ADX must be above the configured threshold (default 25) to confirm a directional environment. Below this level, price is typically ranging and confluence signals carry less weight. The ADX filter can be disabled if you prefer to evaluate trend strength manually.
If any single filter is not in agreement, no signal is generated.
3. Presets
Conflux 4 includes four preset configurations that adjust the stop mode and risk/reward levels to suit different trading styles.
-Scalp
Designed for short timeframes and futures scalping.
Stop mode: ATR cap.
Take profit levels: 0.5R / 1.0R / 1.5R / 2.0R.
-Daytrader
Designed for mid-timeframe trading on 15 minute to 1 hour charts.
Stop mode: Supertrend trailing.
Take profit levels: 0.5R / 1.0R / 2.0R / 3.0R.
-Swing
Designed for higher timeframe trading on 4 hour and daily charts.
Stop mode: Fixed percentage.
Take profit levels: 1.0R / 1.5R / 2.5R / 3.5R.
-Manual
Full control over all parameters. No preset overrides apply.
4. Stop modes
4.1 Supertrend
The stop follows the Supertrend line dynamically for the duration of the trade. This allows the stop to trail price as long as momentum holds.
4.2 ATR cap
The stop is based on the Supertrend level but capped at a maximum distance defined by an ATR multiplier. This prevents the stop from becoming too wide in volatile conditions.
4.3 Fixed percentage
The stop is placed at a fixed percentage below the entry for long trades and above the entry for short trades. The distance does not change after entry.
5. Trade block logic
When a signal fires, the trade block is drawn automatically:
- Entry line at the signal bar close
- Stop line at the calculated level based on the active stop mode
- Up to four take profit lines at configurable risk/reward ratios
- Visual zone shading between entry and stop, and between entry and each take profit
Trailing behavior:
Before TP1 is reached, the stop holds its initial position. After TP1 is reached, the stop moves to breakeven and begins trailing dynamically. The stop only moves in the direction of the trade — it never moves against it.
The trade block remains active until the stop is hit or the Supertrend flips direction. After resolution, the block is cleared and the indicator is ready for the next setup.
6. Dashboard
The dashboard displays the live state of every filter and the current trade situation. It updates on every bar close.
Rows displayed:
- Trend — overall direction from VWMA and EMA alignment
- VWMA — whether price is above or below the VWMA
- EMA — whether the fast EMA is above or below the slow EMA
- RSI — current RSI value and whether the momentum threshold is met
- Supertrend — current Supertrend direction
- ADX — current ADX value and whether the trend strength threshold is met
- Confluence — number of filters currently in agreement
- Stop mode — active stop mode in use
- Last signal — how many bars since the last signal fired
- Cooldown — whether the cooldown period is still active
- Trade — current trade state: none, long, or short
- TP progress — which take profit levels have been reached
The dashboard header color reflects the current trend direction.
7. Settings
Trend filters
- VWMA length: period of the volume weighted moving average used as the primary trend filter
- Fast EMA / Slow EMA: periods of the two exponential moving averages used for secondary trend confirmation
- Show EMA lines: toggle EMA visibility on the chart
- EMA colors and line width: visual styling options
Momentum
- RSI length: period for the RSI calculation
- Bullish threshold: RSI must be above this level for a long signal (default 55)
- Bearish threshold: RSI must be below this level for a short signal (default 45)
Volatility and Supertrend
- ATR length: period for the ATR calculation used by the Supertrend
- Supertrend multiplier: sensitivity of the Supertrend — higher values produce fewer flips
- Show Supertrend line, fill, and color options
ADX
- Enable ADX filter: toggle the trend strength requirement on or off
- ADX length: period for the ADX calculation
- ADX threshold: minimum ADX value required for a signal (default 25)
Signal settings
- Signal cooldown: minimum number of bars between two signals
- Show signals, signal text, background shading, and bar coloring
Trade block
- Show trade block: toggle the full trade block visualization
- Stop mode: Supertrend, ATR cap, or fixed percentage
- ATR cap multiplier and fixed percentage stop size
- Take profit levels: four configurable RR ratios
- Visual styling for stop, entry, and take profit lines
Dashboard
- Position: top left, top right, bottom left, or bottom right
- Size: tiny, small, or normal
- Visibility toggle
8. How to use
Select a preset or switch to manual and configure the filters to match your trading style and timeframe.
Choose a stop mode. Supertrend is best for trending markets where you want the stop to follow price. ATR cap limits the maximum stop size. Fixed percentage suits swing trades where a known maximum loss matters more than trailing.
Set your risk/reward take profit levels.
Monitor the dashboard. When all four filters align, the confluence count reaches four and a signal fires. The trade block is drawn automatically.
A green marker indicates a bullish signal. A red marker indicates a bearish signal.
The trade block shows the full setup from entry to each take profit level. Decision-making remains entirely with the user.
9. Notes
Low signal frequency is intentional. Four filters aligning simultaneously is a selective condition. Signals will not appear on every bar or even every session. That is by design.
Higher timeframes generally produce more stable signals. On lower timeframes the ADX threshold may need to be lowered or disabled to account for faster price structure.
Signals are more meaningful when they form at key structural levels such as support, resistance, or liquidity zones. Conflux 4 does not evaluate those levels — that context comes from the trader.
The ADX threshold can be adjusted for markets that tend to range. Lowering it increases signal frequency. Raising it makes the filter more selective.
10. Disclaimer
This indicator is provided for educational and informational purposes only.
All outputs are based on historical price action calculations and do not guarantee future results.
Trading financial instruments involves significant risk of loss.
Past performance does not indicate future results.
Use at your own discretion.
Indicator

Berg A.M.The Moving Average Trend System is a clean, powerful, and easy-to-use technical analysis indicator designed to help traders identify market direction, trend strength, potential entry zones, and possible reversal areas using a structured moving average methodology.
This indicator is built around one of the most widely used concepts in technical analysis: moving averages. By smoothing price action and filtering out short-term market noise, moving averages allow traders to focus on the broader market structure and make more objective trading decisions.
The purpose of this tool is to provide a clearer visual representation of trend behavior across different market conditions. Whether the market is trending upward, trending downward, consolidating, or preparing for a possible breakout, this indicator helps traders interpret price movement with greater confidence. Indicator

Indicator

Volume Rejection Planner [AGPro Series]Volume Rejection Planner
🧠 Core Idea
Did unusual volume appear at rejection in a way that changes the current decision context?
📌 Overview / What it does
Volume Rejection Planner is a chart-first volume reaction tool built to evaluate wick-led rejection events that appear with elevated relative volume near a recent range edge.
The script maps a volume rejection zone, a risk edge, a follow-through trigger, a room guide, compact state labels, and a clean AGPro planning panel. It converts relative volume, wick quality, close location, range-edge context, follow-through progress, and time decay into a 0-100 rejection quality score.
It does not predict price, automate trades, or mark every volume spike as meaningful. Its purpose is to organize the decision window after volume appears at a rejection wick.
🎯 Purpose & Design Philosophy
This script was built for traders who want more context than a raw volume spike or a simple wick marker.
High volume at a wick can mean participation, absorption, rejection, or noise depending on where it appears and what follows next. The planner focuses on that next question: is the rejection being accepted by follow-through, or is the event failing at its risk edge?
The design supports a decision-engine mindset: identify the rejection, measure its quality, locate invalidation, monitor follow-through, and decide whether the context deserves review, patience, or dismissal.
⚡ Why This Script Is Different
Most tools focus on volume spikes, climax candles, or generic wick rejection labels.
This script does NOT clone a Volume Climax Detector, does not become a Rejection Block tool, and does not draw generic support/resistance zones.
Instead, it treats high-volume wick rejection as a short lifecycle: event, test, accepted follow-through, failed risk edge, expired window, or room-guide reach. The main output is not a raw signal; it is a structured planning state.
⚙️ Methodology
1. Context Detection
The script builds a recent range-edge reference and checks whether the rejection wick occurs near the upper or lower edge.
2. Reference Mapping
When a qualified event appears, it maps the rejection zone, risk edge, follow-through trigger, and room guide.
3. Reaction Evaluation
The model scores relative volume, wick ratio, wick size, close location, edge quality, room, follow-through progress, pressure against the event, and time decay.
4. Visual Output
The result is shown through centered zone text, compact event labels, risk/room guides, candle tint, alerts, and a premium AGPro decision panel.
🗺️ How to Read the Chart
Volume Rejection Zone = the wick-led rejection area created by elevated participation at a range edge.
Risk Edge = the invalidation boundary beyond the rejection wick.
Follow-Through Trigger = the distance price must move away from the rejection to show accepted context.
Room Guide = a forward planning reference used to judge whether the reaction has enough space to matter.
Labels = compact BULL VRP / BEAR VRP markers for primary volume rejection events. Optional secondary labels can show monitor, accepted follow-through, expiry, and room-guide reach when the user wants a more detailed chart.
Colors = teal highlights bullish rejection context, pink highlights bearish rejection context, amber highlights watch context, indigo highlights room/guide context, and red highlights invalidation.
Panel = summarizes Rejection Volume, Wick Quality, Follow-Through, Risk Edge, and Action.
The panel focuses on fresh active context only. Older historical zones can remain on the chart without forcing the panel to display stale invalidated events.
🚦 Signals & States
• Volume Rejection Event → elevated relative volume appears with a qualifying wick near a range edge.
• Testing → the event exists, but accepted follow-through is not confirmed yet.
• Monitor → the active score is high enough to keep the context under review.
• Accepted → price has moved away from the rejection wick enough to confirm follow-through context.
• Risk Edge Broken → the event has moved through its invalidation boundary.
• Window Expired → the event did not confirm within the selected follow-through window.
• Room Guide Reached → the accepted context reached its planning guide.
🔔 Alerts Logic
Alerts trigger when a qualified volume rejection event appears, when the active context reaches READY, when the state changes, when the risk edge is broken, or when the room guide is reached.
Alerts are attention markers only. They are not trade instructions, entry commands, exit commands, or automated strategy rules.
🧩 Confluence Logic
The strongest context appears when high relative volume, a clear wick ratio, a strong close back away from the wick, range-edge location, enough room, and quick follow-through align.
If price fails to move away from the rejection wick, presses back into the risk edge, or loses too much time, the planner downgrades the context.
📊 When to Use
• Range-edge reactions
• Wick rejection events with unusually high participation
• Failed pushes into recent highs or lows
• Markets where volume data is readable
• Situations where the next decision depends on whether rejection follows through
⚠️ When NOT to Use
• Very low-liquidity symbols with unreliable volume
• Extremely noisy micro-timeframes
• News spikes where wick behavior may distort quickly
• Markets where volume reporting is fragmented or unavailable
• Situations where the user expects a direct buy/sell signal
🎛️ Key Inputs
• Sensitivity → controls how strict the volume, wick, and edge requirements are.
• Range Edge Lookback → defines the recent high/low context used for rejection location.
• Minimum Rejection Score → controls which events are important enough to draw.
• Confirmation Mode → adjusts how quickly follow-through can be accepted.
• Follow-Through Window → controls how long the event remains active.
• Risk Edge Buffer → adjusts the invalidation boundary beyond the wick.
• Room Guide ATR → controls the planning guide distance.
• Visual settings → control zones, rails, primary labels, secondary labels, failure labels, candle tint, label density, and text size.
• Limit Historical Drawing / Historical Drawing Bars → controls how far back the script creates visual objects, improving load speed on long histories while preserving the current planning view.
• Adaptive HTF Events → slightly relaxes event thresholds on daily and weekly charts so higher timeframes do not look empty while intraday behavior stays stricter.
🖥️ Interface & Visual Design
The interface is designed to stay chart-first.
The rejection zone provides the visual anchor. The risk edge and room guide frame the planning context. Labels stay compact and offset away from candles so the chart remains active without becoming crowded.
The AGPro panel uses a merged blue title row and a compact five-row decision layout.
🧪 Practical Usage Workflow
1. Read the panel action state.
2. Check whether the rejection zone is bullish or bearish.
3. Review the wick quality and relative volume.
4. Compare current price against the follow-through trigger and risk edge.
5. Treat alerts as attention markers, then evaluate broader market context.
🔍 Interpretation Guidelines
Think in terms of event lifecycle, not prediction.
A stronger score means the rejection had better participation, wick structure, location, room, and follow-through behavior. A weaker or decaying score means the event is losing quality under the current rule set.
Accepted follow-through does not mean price must continue. It means the rejection event has met the script's conditions for stronger review context.
🚫 What This Script Is NOT
• Not a prediction engine
• Not financial advice
• Not auto trading
• Not guaranteed signals
• Not a generic volume spike marker
• Not a Rejection Block clone
• Not a Volume Climax Detector clone
⚠️ Limitations & Transparency
The script is rule-based and depends on recent price, volatility, wick structure, and volume behavior.
Different timeframes can change how rejection and follow-through appear. Volatility spikes can temporarily distort wick size and edge quality. Symbols with weak or unreliable volume may produce less useful readings.
Outputs should always be interpreted within broader structure, liquidity, volatility, and risk context.
🧠 Market Context Notes
Volume rejection is most useful when the wick appears at a meaningful location and the follow-up reaction is clear.
High volume alone is not enough. Location, close behavior, risk edge, and follow-through all matter.
🧾 Use Case Examples
When price pushes above a recent range edge, prints a strong upper wick with elevated RVOL, and then moves away from that wick, the planner may classify the context as accepted bearish rejection.
When price probes below a recent range edge, prints a strong lower wick with elevated RVOL, but then closes below the risk edge, the planner may classify the event as invalidated.
🧱 System Philosophy
AGPro planning tools are designed to help traders evaluate context before reacting.
This script follows that approach by turning high-volume wick rejection into a structured decision question: is the event valid, strong, risky, accepted, or fading?
🔐 Non-Promise Statement
No indicator can provide certainty.
This tool provides structured visual context and rule-based attention markers. It does not guarantee continuation, reversal, rejection, or follow-through.
📉 Risk Disclosure
Trading involves risk. Market conditions can change quickly, and no script can remove uncertainty.
Users are responsible for their own analysis, risk management, and decisions.
This script is for educational and analytical use only and does not provide financial advice.
📚 Educational Note
Use the planner to study how volume behaves at wick rejection points, how quickly follow-through appears after rejection, and how risk edges help separate valid context from failed reaction events.
Indicator

Nexus Global Initial Balance (IB)📝 Publication Description
Title: Nexus Global Initial Balance (IB) : Institutional Flow & Macro Confluence System
Overview
The Nexus Global Initial Balance (IB) is a sophisticated volatility-mapping engine designed for elite index and forex traders. It utilizes the Initial Balance (IB)—the critical first 60 minutes of the Tokyo, London, and New York sessions—to establish the "Structural DNA" of the trading day.
While most traders focus on simple breakouts, this indicator uncovers the hidden institutional "pivot zones" by overlapping session volatility with macro-structural Fibonacci context. It identifies where the "Big Money" is likely to defend positions and where trend expansions are mathematically projected to exhaust.
Key Institutional Features:
Triple-Session IB Architecture: Dynamic, color-coded 1-hour ranges for Tokyo (JST), London (GMT/BST), and New York (EST/EDT).
The Session Golden Zone: Automated shading of the 50% – 61.8% retracement area within each IB box, identifying the high-probability "Institutional Re-entry" zone.
Macro-to-Micro Confluence Engine: A master HTF source toggle that scans higher timeframes (15m to Daily) for structural Fibonacci levels and highlights them as "Institutional Pivots" when they intersect with your session range.
Trend-Based Expansion Projections: Algorithmic price targets based on Fibonacci extensions (0.618, 1.272, 1.618) to define precise take-profit areas.
Pro-Tier Visual Customization: Full control over line weights, styles (Dashed/Dotted/Solid), and session colors to maintain a clean, high-performance trading environment.
📈 The "Nexus Method": Professional Trading Rules
To trade this indicator successfully, follow these institutional protocols:
Rule 1: Establish the "Macro Bias"
The Check: Before the session opens, check the HTF 50% Level (the Daily or 4-hour midpoint).
The Rule: If the price is trading above the HTF 50%, look for Bullish IB breakouts. If below, look for Bearish IB breakdowns.
Rule 2: The "Golden Zone" Retest (Highest Probability)
Setup: Wait for the 1-hour IB range to form.
Action: If the price breaks out of the IBH (High), do not chase it. Wait for a pullback into the shaded Golden Zone (50-61.8%) within the box.
Confirmation: Look for an Institutional Pivot (Red line) sitting inside that Golden Zone.
Entry: Buy when price touches the confluence of the Golden Zone and the Institutional Pivot.
Stop Loss: 5 ticks below the IBL (Low).
Rule 3: The "Expansion Target" Protocol
Take Profit 1 (0.618 Ext): Move stop-loss to Breakeven. This is the "Safety Target."
Take Profit 2 (1.272 Ext): The institutional target for "Trend Days." Close 75% of the position here.
Take Profit 3 (1.618 Ext): The "Exhaustion Point." Close the remainder of the position.
Rule 4: The "Failed IB" (Mean Reversion)
The Setup: Price breaks the IBH but cannot reach the 0.618 extension and falls back into the box.
The Rule: This is a "Range Day." Target the opposite side of the box (IBL). This usually occurs when there is no confluence between the session range and the HTF levels.
Rule 5: Session Synergy
Always watch the Tokyo IB levels during the London open. If London opens inside the Tokyo Golden Zone, it often indicates a massive expansion move is coming as the two sessions' liquidity pools overlap. Indicator

Delta Pressure Ledger [JOAT]Delta Pressure Ledger
Introduction
Delta Pressure Ledger is an open-source lower-pane pressure model built entirely from chart-derived proxies. It combines anchored VWAP context, candle pressure, volume impulse, crowding stretch, volatility pressure, and settlement skew into a normalized composite ledger that classifies whether pressure is balanced, directional, crowded, or stressed.
The problem this script solves is hidden market pressure. Many traders rely on unavailable data feeds or vendor-only metrics to estimate crowding or liquidation risk. Delta Pressure Ledger uses only chart-accessible inputs and standardizes them through z-score normalization so pressure states can still be read in a consistent way across instruments.
Core Concepts
1. Chart-Derived Pressure Proxy
The script estimates directional pressure from candle settlement, intrabar range occupation, and volume impulse rather than external order flow feeds.
2. Anchored VWAP Context
Pressure is interpreted relative to anchored value, allowing the user to distinguish directional expansion from overstretched crowding.
3. Z-Score Normalization
All sub-engines are normalized over a configurable lookback, which makes the composite reading more portable across symbols and timeframes.
4. Crowding and Stress Logic
The script tracks when price and derived sentiment become stretched enough to imply elevated liquidation or unwind risk.
5. Composite Verdict
Pressure, crowding, volatility, and skew are merged into one verdict state so the user can quickly determine whether the market is orderly, imbalanced, or stressed.
Features
Anchored VWAP context: Session, weekly, or monthly value anchor
Pressure engine: Candle and volume-derived directional pressure model
Crowding engine: Stretch and behavioral excess detection
Volatility and skew layers: Pressure quality and instability are separated from raw direction
Normalized composite score: All sub-engines standardized into one comparable ledger
Risk meter: Liquidation-style stress estimate derived from crowding and instability
Confirmed-bar transitions: State changes and alerts are held to confirmed bars
Top-right dashboard: Regime, pressure, crowding, volatility, risk, composite score, and last confirmed flip
How to Use This Indicator
Step 1: Read the composite verdict
The verdict gives the fastest summary of whether the market is balanced, directionally pressured, or entering a crowded stress state.
Step 2: Separate pressure from crowding
A bullish pressure reading with low crowding is different from a bullish pressure reading with extreme crowding and high risk.
Step 3: Respect risk transitions
When the risk meter moves into elevated territory, directional continuation setups deserve more caution.
Indicator Limitations
This script uses chart-derived proxies rather than exchange-level liquidation or true open-interest feeds
Normalized readings can still behave differently across asset classes with unusual volume structure
Stress conditions can remain elevated for extended periods during strong trends
The script classifies pressure and risk context; it does not execute trades by itself
Originality Statement
Delta Pressure Ledger is original in the way it builds a portable, chart-derived pressure and crowding framework without depending on unavailable external feeds, while still organizing the result into a normalized composite and risk ledger.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Derived pressure and crowding models can be wrong, especially during atypical market events. Use proper risk management and independent judgment.
Indicator

Obsidian Divergence Ledger [JOAT]Obsidian Divergence Ledger
Introduction
Obsidian Divergence Ledger is an open-source divergence engine built around confirmed pivot logic and a composite oscillator. It tracks regular and hidden divergence, draws ledger lines between the relevant pivot points, and can optionally project those same relationships onto price. The design is meant to make divergence readable as a structured event instead of a vague visual impression.
The problem this script solves is that many divergence tools are either too loose or too noisy. They often compare incompatible pivots, ignore volatility context, or signal before the pivot is confirmed. Obsidian avoids that by waiting for confirmed pivot structures, enforcing minimum spread requirements, and optionally filtering signals through baseline context and volatility expansion.
Core Concepts
1. Composite Oscillator Construction
The script does not depend on one oscillator only. It blends RSI, CMO, and ROC into one composite measure, then normalizes and smooths it. This helps reduce the chance that one indicator-specific quirk dominates the entire divergence decision.
2. Pivot-Confirmed Divergence Logic
Divergence is only evaluated after `ta.pivothigh()` and `ta.pivotlow()` confirm the turning points. That means the signal appears later than an unconfirmed visual guess, but it also means the structure is stable and suitable for non-repainting use.
pricePivotHigh = ta.pivothigh(high, leftBars, rightBars)
pricePivotLow = ta.pivotlow(low, leftBars, rightBars)
3. Regular and Hidden Divergence
The script distinguishes between reversal-type divergence and continuation-type divergence:
Regular bullish: price makes a lower low while the oscillator makes a higher low
Regular bearish: price makes a higher high while the oscillator makes a lower high
Hidden bullish: price makes a higher low while the oscillator makes a lower low
Hidden bearish: price makes a lower high while the oscillator makes a higher high
4. Ledger Line Visualization and Divergence Zoning
Each confirmed event is recorded visually with lines on the oscillator pane. When enabled, price-side lines are also drawn on the main chart using `force_overlay = true`. Regular divergence and hidden divergence use different color families and line styles so reversal and continuation structures are easy to distinguish. Fresh divergence events can also paint oscillator-side pivot zones and price-side context boxes so the compared structure is visible as an area, not just a single line.
5. Context, Freshness, and Impulse Framing
The script tracks whether a divergence is still fresh, whether it aligns with baseline context, and whether current volatility supports the signal. A central impulse ribbon and intensity band expand and contract with current state strength so the pane itself carries more information even when the dashboard is kept compact.
Features
Composite oscillator: RSI, CMO, and ROC blended into one smoother divergence source
Confirmed pivots only: No divergence state is confirmed before pivot confirmation
Regular and hidden divergence: Reversal and continuation structures handled separately
Optional volatility filter: Can require expansion before accepting signals
Optional baseline filter: Can require directional context relative to a baseline
Oscillator and price ledger lines: Divergence is drawn in both the pane and the price chart when enabled
Oscillator pivot zones: Fresh divergence events can stamp colored zones around the compared oscillator pivots
Price context boxes: The related price swing area can be boxed directly on the chart for faster structural reading
On-chart divergence tags: Compact labels identify regular-vs-hidden bullish and bearish events on the chart itself
Impulse ribbon and intensity band: The pane carries fresh-state emphasis through layered fills, not only through text
Compact dashboard summary: State, freshness, oscillator bias, and context remain available in a smaller top-right panel
Input Parameters
Composite Oscillator:
RSI Length
CMO Length
ROC Length
Normalization Window
Oscillator Smoothing
Divergence Engine:
Pivot Left Bars and Pivot Right Bars
Hidden Divergence toggle
Maximum Ledger Lines
Quality Filters:
Volatility Expansion toggle and length
Baseline Context toggle and baseline length
Minimum Oscillator Pivot Spread
How to Use This Indicator
Step 1: Wait for a Confirmed State
Use the dashboard's State and Freshness rows first. The script is designed to treat confirmed divergence as the event, not the early suspicion of divergence.
Step 2: Separate Reversal From Continuation
Regular divergence is generally more useful when looking for exhaustion. Hidden divergence is generally more useful when looking for pullback continuation. The script keeps those two ideas separate on purpose.
Step 3: Read Context Before Weighting the Signal
A bullish divergence below a weak baseline can still fail. A bearish divergence into expanding volatility can still continue. Use the Context and Volatility rows before deciding how much weight to give the latest signal.
Step 4: Use the Zones, Not Only the Lines
The oscillator pivot zones and price context boxes are there to show the compared structure as an area. This is useful when a divergence is technically valid but forms in a narrow or low-importance pocket. A wider, cleaner zone often carries more practical significance than a tiny local pivot mismatch.
Step 5: Use the Price Overlay Lines as Reference
The overlay lines show the exact price pivots involved in the latest comparison. The companion price labels and boxes make it easier to judge whether the divergence formed in an important location or in minor local noise.
Indicator Limitations
Pivot confirmation creates intentional delay because the script waits for bars on the right side of each pivot
Divergence can persist through multiple additional swings before price meaningfully reverses
A composite oscillator reduces single-indicator bias but cannot eliminate false positives
Hidden divergence is context-dependent and is less useful if the broader trend is weak or unclear
Fresh divergence boxes and labels describe the compared structure, but they do not guarantee that the marked zone will react again
Originality Statement
Obsidian Divergence Ledger is original in the way it structures divergence as a confirmed ledger of relationships rather than a simple shape marker. The script combines a custom composite oscillator, explicit regular-vs-hidden separation, freshness tracking, context filters, synchronized pane-plus-price ledger lines, oscillator pivot zoning, and price-context divergence boxes into one coherent tool.
Disclaimer
This script is provided for educational and informational purposes only. It is not financial advice. Divergence is a contextual condition, not a guarantee of reversal or continuation. False signals can occur frequently, especially in strong trends and low-liquidity markets. Use independent confirmation and risk management.
Indicator

Asterion Regime Lattice [JOAT]Asterion Regime Lattice
Introduction
Asterion Regime Lattice is an open-source market regime oscillator designed to classify whether conditions are directional, transitional, or balanced by combining multiple independent measurements into one continuous score. Instead of relying on a single trend indicator, it evaluates trend displacement, momentum, volatility behavior, directional movement, efficiency, choppiness, entropy, and higher-timeframe confirmation.
The problem this script solves is regime ambiguity. Many entries fail because traders apply trend logic in rotational conditions or mean-reversion logic in expanding directional phases. Asterion Regime Lattice provides a higher-level state model first, so any downstream tool can be interpreted in the proper context. The pane output uses layered lattice bands, a smoothed score curve, regime shading, and a compact dashboard to make the current state readable at a glance without covering price.
Core Concepts
1. Composite Regime Scoring
The script builds a regime score from several independent components rather than one oscillator. It measures fast/slow trend displacement, momentum direction, volatility expansion, directional movement, efficiency ratio, choppiness, Shannon entropy, fractal dimension, RSI state, and ADX-derived trend strength. Each component is normalized, weighted, and added into a single signed score where positive values indicate bullish expansion and negative values indicate bearish expansion.
2. Higher-Timeframe Confirmation
Two higher timeframes are requested with `request.security()` using `lookahead = barmerge.lookahead_off`. This keeps the script non-repainting while allowing the current timeframe to compare itself against broader directional conditions. The higher-timeframe pack contributes trend bias, momentum bias, volatility bias, directional movement bias, slope, ROC, and ADX strength.
=
request.security(syminfo.tickerid, htfOne, f_htfPack(), lookahead = barmerge.lookahead_off)
3. Structure Quality and Noise Separation
The script uses efficiency, choppiness, entropy, and fractal-dimension style measurements to separate clean directional movement from noisy rotation. That matters because two markets can have similar momentum but very different trade quality. Asterion does not only ask "is price moving?" It also asks whether the move is organized enough to treat as a real regime.
4. Lattice Bands and Regime Zones
The oscillator uses inner and outer bands around the smoothed score curve to display soft and strong regime zones. When the score pushes beyond soft thresholds the state becomes directional. When it pushes through stronger thresholds with quality and higher-timeframe agreement, the state becomes more decisive. This layered presentation makes the transition from balance to expansion visible before and during the full move.
5. Confirmed State Transitions
Alerts and state changes are only confirmed on closed bars. This keeps the script suitable for live use and avoids intrabar state flips being treated as final.
Features
Composite regime score: Blends trend, momentum, volatility, efficiency, entropy, fractal behavior, RSI, and DMI/ADX context
Dual higher-timeframe confirmation: Uses two configurable timeframes with `lookahead_off`
Trend quality layer: Separates clean directional movement from noisy or choppy conditions
Inner and outer lattice bands: Visualize soft and strong directional zones
Pane regime shading: Background tint shifts with the current market state
Optional bar tinting: Can color price bars by current regime while keeping the oscillator in a separate pane
Dashboard summary: Reports regime, quality, HTF alignment, volatility, momentum, efficiency, entropy, and directional state
Confirmed-bar alerts: Bull, bear, soft bull, soft bear, and transition events trigger only after bar confirmation
Input Parameters
Core:
Fast Length and Slow Length: Trend displacement backbone
Momentum Length and Trend Slope Length: Speed and directional persistence measurements
Structure Length, Volume Length, Volatility Length: Core normalization windows
Efficiency Length, Choppiness Length, Entropy Length, Entropy Bins, Fractal Length: Noise and organization diagnostics
RSI Length and ADX Length: Directional strength and internal pressure inputs
Higher-Timeframe Confirmation:
Primary HTF and Secondary HTF
Strong ADX and Weak ADX thresholds
Visuals:
Pane shading toggle
Lattice band toggle
Score curve toggle
Bar tint toggle
Curve smoothing and band multipliers
How to Use This Indicator
Step 1: Read the Regime Row
Start with the Regime row in the dashboard and the position of the score relative to the soft and hard thresholds. This tells you whether the market is directional, balanced, or in transition.
Step 2: Check Quality Before Acting
A high-magnitude regime score with weak quality is less reliable than a slightly smaller score with strong quality. Use the Quality row to decide whether the move is organized enough to trust.
Step 3: Compare With Higher Timeframes
The HTF row helps determine whether the current timeframe is aligned with the broader backdrop or fighting it. Stronger follow-through usually appears when local and higher-timeframe states agree.
Step 4: Use It as a Context Filter
Asterion is best used as a regime filter. Trend systems generally perform better when the oscillator is directional and quality is strong. Mean-reversion logic is generally more appropriate when the score is near balance and noise metrics dominate.
Indicator Limitations
The script is a classifier, not a predictive model. It describes current conditions; it does not forecast future direction
Higher-timeframe confirmation can lag turning points because those bars must close before their state is final
In low-range grinding markets, the oscillator can remain transitional for extended periods
Any weighted composite reflects design choices; different markets may require threshold adjustments
Originality Statement
Asterion Regime Lattice is original in the way it combines directional scoring, higher-timeframe agreement, and multiple noise-quality measurements into one structured regime model. It is not a simple trend oscillator with a new color scheme. The script is built around the idea that regime is a blend of direction, organization, and alignment across timeframes, and its lattice presentation is designed to make those layers visible rather than hiding them behind a single line.
Disclaimer
This script is provided for educational and informational purposes only. It is not financial advice and does not guarantee any outcome. Regime measurements are based on historical price and volume behavior and can produce false or delayed readings, especially during sudden event-driven changes in market conditions. Always use independent judgment and risk management.
Indicator

Adaptive Wave Pressure Index [JOAT]Adaptive Wave Pressure Index
Introduction
Adaptive Wave Pressure Index is a normalized slope oscillator built to measure directional pressure through the relationship between regression slope and volatility. By scaling a manually calculated OLS slope with ATR, the script produces a dimensionless momentum reading that can be compared across instruments and timeframes much more cleanly than raw slope alone.
This indicator is designed for traders who want wave pressure, not just speed. It tracks directional force, smooths that force into fast and slow lines, colors the histogram using structural swing context, and adds divergence detection for potential exhaustion.
Why This Indicator Exists
Volatility-Normalized Momentum: Regression slope is scaled by ATR to improve comparability
Fast / Slow Pressure Read: Reveals acceleration and deceleration of directional force
Structure Overlay: Swing-sequence counts add context to histogram strength
Zone Framework: Overbought and oversold thresholds define pressure extremes
Divergence Layer: Flags when price reaches new extremes without matching pressure
Core Components Explained
1. Manual OLS Slope
rawSlope = f_olsSlope(regLength)
The script calculates slope directly from the last N closes rather than relying on a built-in regression shortcut. This provides more control over normalization and display logic.
2. ATR Normalization
normSlope = rawSlope / ta.atr(atrNormPeriod)
Dividing slope by ATR transforms it into a volatility-aware measure of pressure. A positive slope on a low-volatility asset and a positive slope on a high-volatility asset become more comparable after normalization.
3. Fast / Slow Pressure System
Two EMAs are applied to the normalized slope:
Fast Line: More responsive pressure state
Slow Line: More stable reference
Histogram: Spread between fast and slow, showing acceleration or fade
4. Structural Sequence Layer
The indicator also counts consecutive higher lows and lower highs in price. When structure strongly supports the current pressure direction, histogram colors intensify. This adds a valuable distinction between pressure that is statistically rising and pressure that is also structurally confirmed.
5. Divergence and Zone Logic
The script highlights:
Fast-line crosses of overbought and oversold thresholds
Fast/slow line crosses
Bullish and bearish divergences
Divergence lines are retained with a fixed cap so the pane stays readable over time.
Visual Elements
Histogram: Pressure spread with structural-intensity color logic
Fast Line: Main directional read
Slow Line: Reference pressure line
Zero Fill: Directional bias area fill
OB/OS Background: Soft zone shading for extreme pressure
Markers: Crosses and divergence markers
Dashboard: Raw slope, normalized slope, trend, structure sequence, divergence, and active zone
Input Parameters
Regression Length: Window for OLS slope calculation
ATR Norm Period: Volatility baseline used for normalization
Fast / Slow EMA: Pressure responsiveness controls
OB / OS Levels: Extreme pressure thresholds
Pivot Left / Right: Sensitivity for structural and divergence logic
How to Use This Indicator
Step 1: Read whether fast is above or below slow.
Step 2: Check the histogram to see whether pressure is expanding or contracting.
Step 3: Use the sequence readout to judge whether price structure agrees with the oscillator.
Step 4: Treat divergences as warnings that pressure may be weakening.
Step 5: Use OB/OS events to identify stretched pressure, especially after large runs.
Best Practices
Use on instruments with clean swings and sufficient range
Respect signals more when sequence direction agrees with fast/slow direction
Use divergence with structure, not by itself
Increase regression length for smoother wave pressure
Lower lengths react faster but create more noise
Indicator Limitations
Normalized slope improves comparison but does not eliminate market differences
Pressure can stay elevated in strong trends
Divergences can persist before price turns
Short settings increase false transitions
Structure counts are descriptive, not predictive
Technical Implementation
Built in Pine Script v6 using:
Manual OLS slope computation
ATR normalization
Dual-EMA pressure smoothing
Pivot-based structure counting
Capped divergence-line management
Confirmed-bar signal generation
Originality Statement
This indicator is original in the way it combines normalized regression slope, structural sequence intensity, and divergence management into a single wave-pressure framework. Its purpose is not just to show direction, but to show how forceful and how structurally supported that direction is.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Momentum and divergence tools can fail, especially during volatile transitions. Always use proper risk management and independent confirmation.
-Made with passion by officialjackofalltrades
Indicator

Volatility Compression Oscillator [JOAT]Volatility Compression Oscillator
Introduction
Volatility Compression Oscillator is a two-line momentum oscillator that measures where price is trading inside a dynamic volatility envelope, then tracks the compression and release of that positioning through line crosses, histogram rotation, and divergence. It is designed to show when price is quietly loading pressure, when that pressure starts to expand, and when expansion may be exhausting.
This script is useful for traders who want more than a standard bounded oscillator. It combines normalized price location, dual smoothing, histogram analysis, and divergence into one compact pane.
Why This Indicator Exists
Adaptive Normalization: Measures price against a volatility-sensitive envelope instead of a fixed formula
Two-Speed Momentum Read: Uses fast and slow lines to reveal early shifts in pressure
Compression / Release Logic: The histogram shows whether momentum is accelerating or fading
Exhaustion Markers: Histogram peaks and troughs help spot unstable extensions
Divergence Layer: Tracks when price makes a new swing but oscillator pressure does not confirm
Core Components Explained
1. Dynamic Volatility Envelope
offset = avgRange * scale * (1 + avgBody / avgRange)
The script centers the envelope around the candle midpoint average, then expands it with both average range and average body contribution. This makes the oscillator adaptive to both volatility and candle conviction.
2. Normalized Oscillator Calculation
rawOsc = 100 * (close - lowerBand) / bandWidth - 50
Price is transformed into a centered oscillator that measures whether price is trading in the upper or lower half of the active volatility envelope.
3. Dual-Smoothing Engine
The raw oscillator is processed through fast and slow smoothing chains. Their relationship drives the main trend reading:
Fast above slow = bullish pressure
Fast below slow = bearish pressure
Histogram expanding = pressure increasing
Histogram fading = pressure weakening
4. Signal Layers
The indicator produces several distinct signal families:
MA Cross Signals: Momentum handoff between fast and slow lines
OB/OS Crosses: Stretch events when Line 1 crosses the thresholds
Histogram Peaks / Troughs: Local exhaustion cues
Divergences: Price making a stronger swing while oscillator pressure weakens
5. Chart Cleanliness Controls
Divergence lines are retained with an internal cap so the script does not keep drawing indefinitely. This keeps the pane readable and reduces object-limit risk on long-running charts.
Visual Elements
Histogram Columns: Momentum spread between fast and slow lines
Fast Line: Main directional pressure line
Slow Line: Reference trend line
Zero Fill: Directional fill from Line 1 to the centerline
OB/OS Background: Soft shading in stretch conditions
Signal Markers: Circles, triangles, diamonds, and squares for different event types
Dashboard: Trend, line values, histogram value, regime, and divergence state
Input Parameters
Volatility Window: Lookback for midpoint, body, and range normalization
Band Scale %: Width multiplier for the adaptive envelope
OB / OS Levels: Stretch boundaries for Line 1
Line 1 / Line 2 Smoothing: Controls responsiveness of the dual-line engine
Pivot Length: Sensitivity for divergence and histogram turning points
Histogram Peak Levels: Defines stronger exhaustion zones
How to Use This Indicator
Step 1: Determine whether fast is above or below slow.
Step 2: Watch the histogram for acceleration or decay.
Step 3: Use MA crosses for timing only when they occur in sensible zones.
Step 4: Treat OB/OS signals as context for stretch, not automatic reversal commands.
Step 5: Respect divergences most when they align with histogram exhaustion.
Best Practices
Use higher pivot lengths when markets are noisy
Treat histogram turns near extremes as better-quality warnings
Use line crosses in the direction of the higher-timeframe trend
Avoid overreacting to every divergence in strong trends
Keep marker display on only if you actively trade the signal layer
Indicator Limitations
Oscillators can stay overbought or oversold in strong trends
Divergences are warning signs, not standalone trade systems
Short smoothing lengths will create more noise
Compression readings can fail to expand immediately
Signal quality depends heavily on market structure and instrument behavior
Technical Implementation
Built in Pine Script v6 using:
Adaptive volatility-band normalization
Dual-smoothed oscillator lines
Histogram spread calculation
Pivot-based divergence detection
Object-retention caps for divergence lines
Confirmed-bar signal logic
Originality Statement
This indicator is original in how it frames volatility compression and release through normalized envelope location, dual-line momentum, histogram exhaustion, and divergence management in one pane. Its value comes from synthesis and signal layering rather than from any single oscillator component alone.
Disclaimer
This indicator is provided for educational and informational purposes only. It is not financial advice. Oscillator signals can fail, especially in volatile or trendless conditions. Always use proper risk management and independent judgment.
-Made with passion by officialjackofalltrades
Indicator

Compression Breakout Readiness [AGPro Series]Compression Breakout Readiness
🧠 Core Idea
Is compression mature enough for a breakout watch state, or is the range still early, noisy, or structurally weak?
📌 Overview / What it does
Compression Breakout Readiness is a chart-first breakout planning tool designed to evaluate whether a compressed range has developed enough maturity to deserve active attention.
Instead of printing a generic breakout signal, the script studies range contraction, ATR compression, pivot tightening, volume dry-up, directional side bias, invalidation-edge distance, and projected breakout room. These components are converted into a 0-100 Readiness Score and a clear next-action state.
The script produces an active compression box, breakout watch corridor, invalidation edge, target guide, compact state labels, alerts, and a clean AGPro planning panel. It does not predict direction, automate execution, or guarantee that a breakout will follow through.
🎯 Purpose & Design Philosophy
This script was built for traders who want to evaluate the quality of compression before reacting to a breakout attempt.
Many breakout tools only mark the moment price crosses a level. The more useful planning question often comes earlier: is the range actually tight, mature, quiet, and biased enough to watch, or is the structure still too loose?
The design supports a decision-first workflow: identify compression, measure readiness, check risk edge, review the watch side, then decide whether the chart deserves attention.
⚡ Why This Script Is Different
Most tools focus on squeeze dots, breakout arrows, generic consolidation boxes, or simple high/low range breaks.
This script does NOT act as a generic squeeze indicator, a choppiness filter, a support/resistance mapper, or a direct buy/sell signal generator.
Instead, it evaluates compression maturity before and around the breakout edge. The main output is not a trade command. It is a readiness state that helps the user separate READY WATCH conditions from early, neutral, overheated, or invalidated compression contexts.
⚙️ Methodology
1. Context Detection
The script maps the active compression range and evaluates whether current volatility and range width are contracting relative to their baselines.
2. Reference Mapping
It builds the compression box, active breakout watch corridor, invalidation edge, and target guide from the current structure.
3. Reaction Evaluation
The model scores range contraction, ATR compression, pivot tightening, volume dry-up, side bias, and compression age. It also checks whether the invalidation edge is too tight, too wide, or balanced.
4. Visual Output
The result is shown through centered zone text, compact chart labels, clean edge lines, deterministic alerts, and a premium AGPro panel.
🗺️ How to Read the Chart
Compression Box = the active range being evaluated for breakout readiness.
Breakout Watch Corridor = the planning area beyond the active compression edge.
Invalidation Edge = the opposite-side reference used to judge risk context.
Labels = compact state markers such as READY WATCH, WATCH, EDGE REVIEW, PREMATURE, HOT RISK, and INVALID EDGE.
Colors = teal for bullish watch context, pink for bearish or invalid context, amber for caution, and indigo for watch/neutral emphasis.
Panel = the panel summarizes Compression Age, Readiness Score, Expansion Side, Risk Edge, and Action.
🚦 Signals & States
• READY WATCH → compression is mature, biased, and risk edge distance is balanced enough for active review.
• WATCH → compression is developing, but at least one readiness component remains incomplete.
• EDGE REVIEW → price has moved beyond the compression edge and the user should verify the close and broader context.
• PREMATURE → compression has not lasted long enough to build strong maturity.
• HOT RISK → volatility has expanded too aggressively for clean readiness interpretation.
• NO BIAS → compression exists, but the directional side is not clear enough in Auto mode.
• INVALID EDGE → price crossed the active invalidation edge and the prior context may need reset.
🔔 Alerts Logic
Alerts trigger when the planner enters READY WATCH, WATCH, EDGE REVIEW, HOT RISK, or INVALID EDGE state.
These alerts are attention markers. They are not trade instructions, entry signals, broker actions, or automated strategy commands.
🧩 Confluence Logic
The strongest readiness state appears when multiple components align:
Range contraction + ATR compression + pivot tightening + volume dry-up + directional side bias + balanced risk edge.
When those components improve together, the score can rise toward READY WATCH. If volatility becomes too hot, risk becomes distorted, or the active edge fails, the state downgrades.
📊 When to Use
• Before evaluating a possible breakout setup
• During narrow ranges where volatility is compressing
• Around coiling structures that need maturity review
• When comparing whether one compression range is cleaner than another
• On liquid symbols where range, ATR, and volume behavior are meaningful
⚠️ When NOT to Use
• Extremely low-liquidity markets
• Highly noisy micro-timeframes
• News-driven volatility spikes
• Symbols with unreliable or missing volume data
• Situations where the user wants a simple breakout arrow or automated trade signal
🎛️ Key Inputs
• Breakout Watch Side → selects Auto, Bullish Watch, or Bearish Watch evaluation.
• Compression Lookback → defines the active range used for readiness scoring.
• ATR Baseline → controls volatility compression comparison.
• Volume Dry-Up Length → evaluates whether participation is contracting inside compression.
• Minimum Compression Age → controls how mature a range must be before stronger readiness states appear.
• READY / WATCH Thresholds → adjust how selective the planner is.
• Visual settings → control compression box, breakout corridor, range edges, invalidation edge, projection length, labels, and candle tint.
• Panel settings → control panel visibility, location, theme, and font size.
🖥️ Interface & Visual Design
The interface is intentionally chart-first.
The compression box uses centered text so the user can read score and age directly inside the structure. The breakout corridor provides a clean forward planning reference without filling the chart with many competing levels.
The AGPro panel uses a single merged blue header row and a compact five-row decision layout. Label and panel font sizes are adjustable, with Normal as the default.
🧪 Practical Usage Workflow
1. Read the panel Readiness Score and Action.
2. Check whether the compression box is mature or premature.
3. Review the Expansion Side and breakout watch corridor.
4. Compare the Risk Edge with the visible structure.
5. Treat labels and alerts as review prompts, not trade commands.
🔍 Interpretation Guidelines
A higher score means the script sees stronger compression maturity according to its rule set.
READY WATCH does not mean price must break out. It means the compression context is organized enough to deserve attention.
WATCH means the structure may be developing but is not fully mature.
HOT RISK and INVALID EDGE are caution states. They warn that the range may no longer be clean enough for the same readiness read.
🚫 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 signals.
It is not a generic squeeze indicator.
It is not a choppiness dashboard.
It is not a support/resistance scanner.
It is not a direct breakout entry tool.
⚠️ Limitations & Transparency
Compression quality depends on the selected lookback, timeframe, volatility baseline, and market condition.
Volume dry-up may be less reliable on symbols with inconsistent exchange volume.
Fast volatility expansion can quickly change the readiness state.
Different timeframes can show different compression ranges and side-bias context.
The script is rule-based and should be interpreted as an analytical planning layer, not as certainty.
🧠 Market Context Notes
Compression by itself is not enough.
A useful breakout watch context also needs maturity, reduced noise, a readable side, and a practical invalidation edge.
This script keeps those elements visible so users can review breakout readiness before reacting emotionally to a candle crossing a range edge.
🧾 Use Case Examples
When a range contracts, ATR falls below baseline, volume dries up, and side bias becomes clear, the planner may move toward WATCH or READY WATCH.
When price pushes beyond the edge while readiness is acceptable, the script can mark EDGE REVIEW so the user can verify the close and broader context.
When ATR expands too aggressively before structure is mature, the planner can show HOT RISK instead of treating every move as a clean breakout context.
🧱 System Philosophy
Compression Breakout Readiness follows the AGPro Series decision-engine approach:
Context first.
Readiness before reaction.
Risk edge before target guide.
Attention markers instead of promises.
🔐 Non-Promise Statement
No script can remove uncertainty.
No state, score, label, alert, box, corridor, or line should be interpreted as guaranteed market direction.
📉 Risk Disclosure
Trading involves risk.
All decisions remain the responsibility of the user.
This script is for educational and analytical chart review only and does not provide financial advice.
📚 Educational Note
Use the script to study how compression matures, weakens, breaks, or invalidates around range edges. The strongest reading comes from combining the panel state with the visible chart structure and broader market context.
Indicator

ATC Bollinger Band Percentile v1.1What It Is
The ATC Bollinger Band Percentile (ATC BBP) is a dual-layer oscillator that tells you two things simultaneously: where price sits inside its Bollinger envelope right now, and whether the current volatility environment is compressing, neutral, or expanding — measured against real historical data, not a hardcoded threshold.
Most Bollinger Band tools give you the bands. This one gives you the context behind the bands.
________________________________________
Who It's Built For
ATC BBP is designed for retail traders who already use Bollinger Bands or have tried them but found the raw %B reading too noisy or too vague to act on. If you've ever looked at a squeeze setup and wondered whether the bands were actually tight or just tighter than yesterday, this indicator was built to answer that question directly.
It works best for traders who use volatility as a filter before entering trend or breakout trades, want a cleaner and less reactive version of %B, or are building toward understanding normalized, statistically-grounded indicators.
________________________________________
Core Concept
Bollinger Bands place price in a dynamic envelope built from a moving average and standard deviation. The %B reading converts that envelope into a 0–100 scale: 100 means price is sitting on the upper band, 0 means price is on the lower band, and 50 means price is at the midpoint.
That's useful, but the raw reading is noisy and the bands themselves don't tell you whether they're wide or narrow relative to history. A band can look visually compressed on your chart and still be wider than it's been 75% of the time — or vice versa.
ATC BBP solves both problems. It smooths %B with a Hull Moving Average to reduce reactive noise, and it scores the current bandwidth as a percentile against a rolling window of its own history — so you always know objectively whether compression is real.
________________________________________
ATC Upgrades Over Standard %B
HMA Smoothing on %B The raw %B line reacts sharply to every candle. ATC BBP applies a Hull Moving Average to %B before it's plotted, cutting noise while preserving responsiveness. The raw %B is still available in the data window for comparison, but the smoothed version drives everything you see. You can adjust the smoothing length or disable it entirely.
Bandwidth Percentile Scoring This is the core ATC enhancement. Instead of asking "are the bands narrow?", ATC BBP asks "are the bands narrow relative to the last 125 bars of bandwidth history?" The bandwidth percentile is computed by ranking the current bandwidth against every value in the lookback window. A reading of 8% means the bands are tighter right now than they've been on 92% of recent bars. That's a real squeeze signal — not an eyeball call.
Empirical Zone Thresholds with Hysteresis The %B zone boundaries are not hardcoded round numbers. The defaults are set at empirically sensible levels and are fully adjustable. More importantly, every state transition — both the squeeze state and the %B zone — uses a configurable hysteresis band so the indicator doesn't flicker at the edges. Once a state is entered, it takes a meaningful move to exit it.
________________________________________
What's on the Chart
ATC BBP plots in a separate pane below your price chart.
The %B Line The smoothed %B oscillator on a 0–100 scale. The line changes color dynamically to reflect the current zone: green shades when price is in the lower portion of the bands, red shades in the upper portion, neutral grey for mid-range. When price tags or exceeds either band, the color deepens to full intensity. A fill between the %B line and the 50-level midline gives an immediate read on whether price is in the upper or lower half of the range.
Horizontal Reference Lines Five levels mark the key zones: lower extreme (0), lower quartile (20), midline (50), upper quartile (80), and upper extreme (100). Low-opacity colored background shading tints each zone — red above the upper quartile, green below the lower quartile, neutral in the middle.
Squeeze Pressure Bar Along the bottom of the pane, a colored bar marks the current squeeze state. Amber indicates a tight squeeze — bandwidth in the lowest percentile tier. Light yellow indicates a developing or loose squeeze. Blue indicates active volatility expansion. When no state is active, the bar disappears — the absence of color is meaningful. Diamond markers appear at the bar when a squeeze begins and again when expansion starts, so state transitions are never missed on a busy chart.
________________________________________
HUD Breakdown
The corner HUD (top right by default) gives you a live read of both indicator layers without having to inspect chart values:
Volatility — current squeeze state label: Tight Squeeze, Loose Squeeze, Expansion, or Neutral, color-coded to match the pressure bar
BW %-ile — the bandwidth percentile as a number, followed by a 10-block progress bar showing where current bandwidth sits on a visual scale from fully compressed to fully expanded
%B Zone — a text label for where price is in the envelope: Below Lower Band, Lower Quartile, Mid Range, Upper Quartile, or Above Upper Band
%B Reading — the smoothed %B value as a number
The HUD supports dark and light themes and can be repositioned to any corner of the pane.
________________________________________
Logic Layers
The indicator runs two independent state machines, each with its own hysteresis logic.
Squeeze State Machine Four states: Tight Squeeze (bandwidth percentile below the tight threshold), Loose Squeeze (between tight and loose thresholds), Neutral (mid-range bandwidth), and Expansion (above the expansion threshold). State transitions require the bandwidth percentile to move beyond the threshold by the hysteresis amount before the state flips. This prevents toggling at the boundary on marginal readings.
%B Zone State Machine Five zones tracking price location within the envelope: Below Lower Band, Lower Quartile, Mid Range, Upper Quartile, and Above Upper Band. The same hysteresis logic applies — once price enters a zone, it stays classified there until it moves decisively into the next zone.
The two machines run independently. You can be in a tight squeeze while price is in the upper quartile — which is a very different setup than a tight squeeze with price at the midline. The HUD shows both readings simultaneously so you always have the full picture.
________________________________________
Alerts
Seven alert conditions are built in.
BBP: Tight Squeeze Started — fires when the squeeze state first enters the tight tier. Use this to monitor compression setups across instruments before they break.
BBP: Tight Squeeze Released — fires when the tight squeeze breaks. This is the exit from compression, which may precede expansion or resolve back to neutral — both are meaningful.
BBP: Expansion Started — fires when bandwidth percentile crosses above the expansion threshold, confirming that volatility is breaking out of compression.
BBP: Price Above Upper Band — fires when %B reaches or exceeds 100, meaning price has tagged or broken through the upper band.
BBP: Price Below Lower Band — fires when %B reaches or falls below 0, meaning price has tagged or broken through the lower band.
BBP: %B Cross Above 50 — fires when smoothed %B crosses above the midline. Price location bias has shifted to the upper half of the envelope.
BBP: %B Cross Below 50 — fires when smoothed %B crosses below the midline. Price location bias has shifted to the lower half.
________________________________________
How to Trade With It
ATC BBP is a context indicator, not a signal generator. It tells you the volatility environment and price location so you can filter and frame your setups — it does not issue buy or sell signals on its own.
Step 1 — Check the Squeeze State First Before anything else, look at the HUD Volatility row and the pressure bar. Tight Squeeze means the market is coiling. Expansion means it's already moving. Neutral means neither is happening. This single read tells you what kind of market you're in before you look at anything else.
Step 2 — Use Squeeze Context to Filter Breakout Setups A tight squeeze is the setup condition for a potential expansion — it does not tell you which direction. When bandwidth is in the lowest 8–10 percentile of its history, start watching price action for the break, but wait for directional confirmation from your primary setup criteria before trading it. The squeeze tells you energy is building. Your edge tells you which way it breaks.
Step 3 — Use %B to Read Location Within the Setup Once you have a directional bias, %B tells you where price currently sits in the envelope. If you're looking for a long entry and %B is already above 80, price is extended toward the top of the range — it may be better to wait for a pullback toward the 50 midline. If %B is mid-range or lower quartile heading into a long setup, there's more room to run before hitting band resistance.
Step 4 — Look for Squeeze-Plus-Zone Confluence The highest-value reads come when both layers line up. A tight squeeze with %B at mid-range or lower quartile means compression is present and price has room to move higher if the break is bullish — watch for expansion to confirm with %B rising through 50. Expansion with %B crossing above 50 means volatility is moving and location bias is shifting bullish simultaneously — often the clearest confirmation that a breakout is real. Expansion with %B above 100 means price is already through the upper band in an expanding environment — valid in strong trends, a caution flag in range conditions.
Step 5 — Use Alerts for Multi-Instrument Monitoring If you're running ATC BBP across multiple instruments or timeframes, set the Tight Squeeze Started and Expansion Started alerts. These fire the moment a state changes so you're never watching the wrong chart while a setup develops elsewhere.
________________________________________
Settings Reference
Bollinger Bands BB Length (default 30) — period for the moving average and standard deviation calculation. Optimized default for QQQ. Increase for slower, more structural readings; decrease for more reactive readings on faster instruments.
BB StdDev Multiplier (default 1.6) — number of standard deviations for the band width. Optimized default for QQQ. Lower values tighten the bands and will increase the frequency of upper/lower extreme readings.
BB Source (default Close) — price source for the band calculation.
Smoothing %B HMA Smoothing (default 8) — Hull Moving Average length applied to %B. Set to 1 to disable smoothing and plot the raw %B line.
Squeeze Quality Bandwidth Percentile Window (default 125) — rolling lookback used to rank the current bandwidth. Larger windows produce more stable percentile readings against longer historical context.
Tight Squeeze Threshold (default 8) — bandwidth percentile below this level is classified as a tight squeeze.
Loose Squeeze Threshold (default 25) — bandwidth percentile between the tight threshold and this level is classified as a developing squeeze.
Expansion Threshold (default 75) — bandwidth percentile above this level is classified as active expansion.
State Hysteresis (default 3.0) — neutral band around each threshold. A state must be exceeded by this amount before the classification changes, preventing flicker on marginal readings.
%B Zones Upper Quartile (default 80) — %B above this is classified as Upper Quartile zone.
Lower Quartile (default 20) — %B below this is classified as Lower Quartile zone.
Upper Extreme (default 100) — %B at or above this is classified as Above Upper Band. Lower
Extreme (default 0) — %B at or below this is classified as Below Lower Band.
Visuals Shade %B Zones — toggles the background zone tinting on the oscillator pane. Show Squeeze Pressure Bar — toggles the colored state bar and diamond markers at the bottom of the pane. Color inputs for all states are fully adjustable if you prefer a different palette.
________________________________________
Recommended Instruments and Timeframes
ATC BBP is tested and validated on ES, NQ, CL, GC, SPY, QQQ, major equities, and major FX pairs. Recommended timeframes are 5m, 15m, 1h, 4h, and 1D. Default settings are optimized for QQQ. When applying to other instruments, the BB Length, StdDev Multiplier, and Bandwidth Percentile Window are the primary settings to adjust for the instrument's typical volatility profile.
________________________________________
Indicator

Volatility Prism [JOAT]Volatility Prism
Introduction
Volatility Prism is an open-source dual Bollinger Band envelope system with percentile-based bandwidth squeeze detection and Stochastic RSI confirmation. It renders two independent envelopes — an inner band at a configurable standard deviation multiplier and an outer band at a wider multiplier — with gradient fills that color dynamically based on whether price is in a bullish or bearish position relative to the moving average basis. When the bandwidth compresses to a historically low percentile, a squeeze state is declared. When the squeeze releases, an expansion signal fires.
The problem Volatility Prism solves is that volatility states are cyclical: periods of compression (squeeze) reliably precede periods of expansion (breakout), and the direction of the breakout is where the opportunity lies. By combining a statistically-based squeeze detector — which uses percentile thresholds rather than fixed bandwidth levels — with Stochastic RSI extreme confirmation, Volatility Prism identifies both the compression state and the likely directional bias of the coming expansion simultaneously.
Core Concepts
1. Dual Bollinger Band Structure
Two separate Bollinger Band pairs share the same basis (SMA of the source) but use different standard deviation multipliers. The inner band (default 2.0x) is the primary envelope. The outer band (default 3.0x) defines the extreme extension zone. Price trading beyond the inner band but inside the outer band is in the elevated zone. Price trading beyond the outer band is in a statistical extreme:
basis = ta.sma(src, bbLen)
dev = ta.stdev(src, bbLen)
upper1 = basis + bbMult1 * dev // Inner upper
lower1 = basis - bbMult1 * dev // Inner lower
upper2 = basis + bbMult2 * dev // Outer upper
lower2 = basis - bbMult2 * dev // Outer lower
The trend bias is determined by whether the close is above or below the basis. When bullish, all envelope lines and fills render in the bullish color. When bearish, they render in the bearish color. This makes the trend state immediately visible from the envelope color alone.
2. Gradient Envelope Fills
Four gradient fills create the visual envelope structure. The inner fills gradient from a near-opaque shade at the band edge to a nearly transparent shade at the basis, creating a density effect that visually represents how far price is from the center. The outer fills extend this gradient into the extreme zone at reduced opacity, cleanly separating the normal, elevated, and extreme price zones:
fill(basisPlot, upper1Plot, upper1, basis, color.new(envCol, 85), color.new(envCol, 98), "Upper Inner Fill")
fill(upper1Plot, upper2Plot, upper2, upper1, color.new(envCol, 75), color.new(envCol, 88), "Upper Outer Fill")
3. Percentile-Based Bandwidth Squeeze Detection
The bandwidth (the width of the inner band as a percentage of the basis) is computed on each bar and added to a rolling history array of configurable length. The current bandwidth is compared to the percentile threshold of that history — if the current bandwidth is below the configured percentile (default 15th percentile), the squeeze state is active:
bandwidth = basis > 0 ? (upper1 - lower1) / basis * 100 : 0.0
// Sort history and find threshold at configured percentile
threshIdx = int(array.size(sorted) * sqzPctile / 100) - 1
sqzThreshold = array.get(sorted, threshIdx)
isSqueezing = bandwidth <= sqzThreshold
This approach adapts to the instrument and timeframe automatically — a 15th percentile squeeze on a low-volatility bond future and on a high-volatility crypto asset will both correctly identify when that specific instrument is in an unusually compressed state relative to its own history.
4. Stochastic RSI Extreme Confirmation
The Stochastic RSI (an oscillator that applies Stochastic logic to RSI values) provides momentum extreme confirmation. Overbought and oversold readings from the K and D lines confirm when band extremes coincide with momentum extremes, strengthening band rejection signals:
rsiVal = ta.rsi(src, rsiLen)
stochVal = ta.stoch(rsiVal, rsiVal, rsiVal, stochLen)
kLine = ta.sma(stochVal, smoothK)
dLine = ta.sma(kLine, smoothD)
stochOB = kLine > upperLim and dLine > upperLim // Overbought
stochOS = kLine < lowerLim and dLine < lowerLim // Oversold
5. Band Rejection Signals and Squeeze Breakout
Three signal types are generated. Bullish band rejection fires when price was below the inner lower band on the previous bar and closes back above it, with Stochastic RSI confirming oversold — a failed breakdown with momentum confirmation. Bearish band rejection fires on the symmetric condition above the inner upper band. Squeeze Breakout fires on the first bar that transitions from squeeze to non-squeeze state — the moment the bandwidth begins expanding:
bearRejection = close > upper1 and close <= upper1 and stochOB
bullRejection = close < lower1 and close >= lower1 and stochOS
sqzBreakout = isSqueezing and not isSqueezing
6. Band Price Labels at the Right Edge
All five band lines (U2, U1, MA, L1, L2) receive price labels at the right edge of the chart. These labels update every bar to show the current price of each level, eliminating the need to hover over lines or read the y-axis to determine band values:
if barstate.islast and showBandLbls
lblU2 := label.new(bar_index + 2, upper2,
"U2 " + str.tostring(upper2, format.mintick),
style=label.style_label_right, ...)
Features
Dual Bollinger Band envelopes: Inner and outer bands with independently configurable multipliers
Adaptive gradient fills: Four gradient fills (inner upper, inner lower, outer upper, outer lower) color dynamically with trend bias
Dynamic trend coloring: All envelope elements switch between bullish and bearish colors based on close vs. basis
Percentile-based squeeze detection: Bandwidth compared to a configurable percentile of its rolling history — adapts to any instrument's volatility profile
Configurable squeeze lookback: Rolling bandwidth history window from 20 to 500 bars
Squeeze background shading: Optional chart background shading during active squeeze state
Stochastic RSI confirmation: K and D line extreme zones confirm band rejection signal quality
Three signal types: Bull Rejection, Bear Rejection, and Squeeze Breakout markers with distinct shapes
Band price labels at right edge: Live price labels for all five band levels (U2, U1, MA, L1, L2) at bar_index + 2
Institutional dashboard (top right): 11-row table with Volatility state (SQUEEZE/EXPANDING), Bandwidth %, Trend, StochRSI state, K and D values, Basis price, and Envelope range
Fully configurable inputs: BB length, both multipliers, squeeze lookback and percentile, Stochastic RSI parameters, and all colors independently adjustable
Alerts: Bull Rejection, Bear Rejection, Squeeze Breakout, and Squeeze Entry alertconditions
Input Parameters
Bollinger Bands:
Source: Price source (default: close)
BB Length: MA and standard deviation period (default: 20)
Inner Mult: Standard deviation multiplier for inner bands (default: 2.0)
Outer Mult: Standard deviation multiplier for outer bands (default: 3.0)
Squeeze Detection:
Bandwidth Lookback: Rolling history window for percentile calculation (default: 120 bars)
Squeeze Percentile: Bandwidth percentile below which squeeze is active (default: 15th)
Stochastic RSI:
K Smoothing (default: 3), D Smoothing (default: 3)
RSI Length (default: 14), Stochastic Length (default: 14)
Overbought level (default: 80), Oversold level (default: 20)
Display:
Show Dashboard toggle
Squeeze Background toggle
Band Price Labels toggle
Bullish Envelope color, Bearish Envelope color, Basis Line color, Squeeze Background color
How to Use This Indicator
Step 1: Identify the Volatility State
The dashboard's Volatility row shows SQUEEZE (yellow) or EXPANDING (gray). When SQUEEZE is active, the chart background shades yellow. A squeeze state means bandwidth has compressed to a historically low percentile — the market is loading energy for a directional move.
Step 2: Watch for Squeeze Breakout Signals
The cross (x) marker appears at the first bar that exits a squeeze. This is the moment bandwidth begins expanding. The direction of the breakout bar (bullish or bearish candle) combined with the trend color of the envelope provides the directional lean for the expansion phase.
Step 3: Interpret Envelope Color for Trend Bias
When all envelope elements are teal, price is above the basis — bullish bias. When all elements are orange, price is below the basis — bearish bias. Use the envelope color as a continuous trend indicator overlaid directly on the price.
Step 4: React to Band Rejection Diamonds
Diamond markers at the band edge indicate price failed to sustain a move beyond the inner band and recovered inside, with Stochastic RSI confirming the extreme. These are mean-reversion entry signals — price rejected the statistical extreme with momentum confirmation.
Step 5: Reference Band Price Labels
The right-edge labels show the current price of each band level. Use these when planning take-profit targets (opposite band) or stop-loss placement (outer band beyond entry) without needing to manually read prices from band lines.
Indicator Limitations
The squeeze detector requires a minimum of sqzLen bars of bandwidth history to activate. On short charts or immediately after the indicator is applied, the squeeze state will not register until enough history is accumulated
The percentile-based squeeze threshold adapts to the lookback window. A longer lookback produces a more stable threshold; a shorter lookback adapts faster but may produce more frequent squeeze entries and exits
Band rejection signals require the close to recover inside the band on the bar immediately following the outside close. Multi-bar breakouts that recover more slowly are not detected as rejections
Squeeze Breakout markers fire on the first bar exiting a squeeze regardless of candle size or direction. They do not independently confirm the breakout direction — the envelope trend color and Stochastic RSI must be used to assess directional bias
Stochastic RSI is a double-transformed oscillator (RSI → Stochastic). It can reach and hold extreme levels for extended periods in strong trends, producing frequent overbought or oversold readings that reduce the specificity of band rejection confirmation
Originality Statement
Volatility Prism is original in its adaptive, percentile-based squeeze detection combined with a dual-envelope gradient structure and Stochastic RSI extreme confirmation with right-edge band price labels. This indicator is published because:
Using the rolling percentile of bandwidth history — rather than fixed bandwidth values or the classic Keltner Channel comparison method — for squeeze detection provides an instrument-adaptive and timeframe-adaptive threshold that requires no manual calibration
The dual-envelope structure (inner and outer bands) with four independent gradient fills that change color based on real-time trend bias creates a visually rich, information-dense chart overlay without adding separate indicator panes
The right-edge band price labels for all five band levels eliminate a common usability friction point in Bollinger Band analysis, where traders must hover over lines or estimate prices from the y-axis scale
The three-signal system (Bull Rejection, Bear Rejection, Squeeze Breakout) operating from two independent mechanisms (band geometry + Stochastic RSI for rejections, bandwidth percentile for breakout) provides distinct signal categories suited to different trading styles
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. Bollinger Bands and Stochastic RSI readings are historical statistical tools. Squeeze states can persist for extended periods without producing a breakout, and breakouts can occur in either direction. Band rejection signals do not guarantee price will reverse from the band. Always use proper risk management. The author is not responsible for any trading losses resulting from the use of this indicator.
-Made with passion by jackofalltrades
Indicator

Breakout Volume Quality [AGPro Series]Breakout Volume Quality
🔷 OVERVIEW
Breakout Volume Quality is a chart-overlay indicator built to answer one specific question:
When price breaks a defended level, did that break carry real participation quality, or was it only a low-conviction move beyond the line?
Many breakout tools detect the level break itself. This script goes one layer deeper. It evaluates the breakout candle through relative volume, body efficiency, close location, distance beyond the broken level, expansion versus ATR, and the quality of the underlying support-resistance range. The output is a clean 0-100 breakout volume quality score, a visual confirmation band, a compact event label, and a retest state panel.
The goal is not to mark every possible breakout. The goal is to separate a cleaner participation-backed break from a weak level poke that deserves less visual attention.
🔹 CORE IDEA
A breakout is more useful when price does more than cross a line.
Breakout Volume Quality looks for a sequence:
1. A support or resistance reference is built from repeated pivot interaction.
2. Price closes beyond that defended level by an ATR-adjusted buffer.
3. The breakout candle is graded for relative volume participation.
4. Candle structure is checked for efficient body control and directional close quality.
5. The move is measured against ATR to understand displacement and expansion.
6. Confirmed events project a forward confirmation band.
7. The script then tracks whether the broken level produces a clean retest hold, expires, or fades back inside.
This creates a more complete event map than a simple arrow above or below a candle.
💠 UNIQUE EDGE
The edge of this script is the "volume verdict" layer.
It does not simply ask whether price broke resistance or support. It asks whether the break showed enough participation quality to deserve confirmation.
That distinction matters because visually similar breakouts can behave very differently:
- A break with elevated relative volume, strong body efficiency, and a close near the directional extreme usually communicates cleaner participation.
- A break with low relative volume, wick-heavy structure, and a weak close beyond the level may be more fragile.
- A move that breaks, confirms, and later holds the band is visually different from a move that immediately fades back inside.
Breakout Volume Quality turns those differences into a readable score and a structured chart layer.
🔶 WHAT MAKES IT DIFFERENT FROM OTHER AGPRO BREAKOUT TOOLS
This script was intentionally designed to avoid overlapping with the existing AGPro breakout family.
It is not a Donchian breakout tool.
It does not revolve around a rolling channel high or low as the main concept. The level reference comes from defended pivot interaction, and the main evaluation is the volume quality of the break.
It is not an Inside Bar breakout tool.
It does not require a parent candle compression pattern. The script can evaluate broader defended levels rather than only inside-bar structures.
It is not an Opening Range breakout tool.
There is no session opening window, no locked opening range, and no session-specific model.
It is not an ATR Envelope breakout tool.
It does not treat a dynamic volatility envelope as the breakout boundary. ATR is used for normalization, buffers, bands, and score scaling.
It is not a Break-Retest quality tool.
The retest state is included for workflow context, but the core score is assigned to the breakout candle and its participation quality. The first retest is not the central scoring event.
It is not a Failed Break or trap-reclaim tool.
Weak breaks are faded as failed confirmations, but the script does not rebuild the event into a reversal or reclaim model.
It is not a general RVOL pressure map.
Relative volume is used specifically to validate level breaks, not to classify all candles into broad pressure states.
This gives Breakout Volume Quality its own clear lane: breakout participation quality around defended levels.
📌 VISUAL COMPONENTS
Breakout Line
The broken level is extended forward so the user can see the exact structural reference being tested.
Decision Rails
Eligible defended support and resistance references are displayed as subtle forward rails. These rails keep the chart active while price is building around a level, without turning the script into a generic support-resistance map.
Volume Build-Up Windows
Compact boxes labeled BULL SETUP or BEAR SETUP can frame areas where price is building volume pressure near an eligible breakout level before confirmation. These windows are concept-native: they show pre-breakout participation pressure, not generic support-resistance zones.
Optional Advanced Layers
RVOL approach marks, quality candle glow, and pressure trail points are available for users who want more activity on the chart, but they are disabled by default so the main public view remains easy to read.
Confirmation Band
A rectangular band is projected around the broken level. Confirmed events use stronger visual emphasis, while weak confirmations are faded so the chart keeps important context without becoming noisy.
Failed-Confirmation Fade
When price breaks a level but fails the volume, score, candle structure, or close-quality model, the event can still be shown as a softer failed confirmation band. Cleaner weak confirmations can also print WEAK UP or WEAK DOWN labels through a minimum-score filter, so the chart gains more context without labeling every low-quality break.
Retest Hold Label
After a confirmed breakout, the script watches the band for a clean hold. A retest hold is labeled only once so the chart remains controlled.
Summary Panel
The panel displays the current breakout side, volume confirmation, expansion, retest state, and score. It is designed for quick chart reading without covering the price action.
⚙️ SCORING MODEL
The score is built from six components:
Relative Volume
Measures whether current participation is meaningfully above its volume baseline.
Body Efficiency
Measures how much of the candle range is represented by the real body.
Directional Close Location
Checks whether the candle closes toward the breakout side of its own range.
Break Distance
Measures how far the close finishes beyond the broken level in ATR terms.
Expansion
Measures the breakout candle range relative to ATR.
Range Quality
Rewards levels that come from a more defined structure rather than a loose oversized range.
Together, these components produce a transparent 0-100 score and a grade-style readout.
🧭 HOW TO USE
Use the script to study whether a breakout has participation quality.
A stronger event usually has:
- A clean close beyond the level.
- Relative volume above the confirmation threshold.
- A body-dominant candle.
- A close near the breakout-side extreme.
- Meaningful ATR-normalized displacement.
- A confirmation band that later holds during a retest.
A weaker event may show:
- Low relative volume.
- A wick-heavy breakout candle.
- A close barely beyond the level.
- Fast return back inside the broken structure.
- A faded failed-confirmation label instead of a confirmed event.
The script is best used as a structured chart-reading layer. It helps organize breakout quality, but it is not a complete trading system by itself.
🔷 KEY INPUTS
Pivot Strength
Controls how support and resistance references are confirmed.
Minimum Level Touches
Requires repeated interaction before a level becomes eligible.
Level Match Tolerance ATR
Groups nearby pivots into one defended level.
Close Beyond Level ATR
Controls how decisive the break must be beyond the level.
RVOL Confirmation Threshold
Defines the participation level required for volume confirmation.
Minimum Body Efficiency
Filters weak, wick-heavy breakout bars.
Directional Close Location
Requires the candle to close toward the breakout side.
Minimum Score To Confirm
Controls how selective confirmed breakout labels should be.
Confirmation Band ATR
Sets the height of the projected band around the broken level.
Retest Watch Window
Defines how long the script watches for a clean retest hold.
Panel Location / Theme / Font Size
Allows the panel to be adapted to different chart layouts.
Label Font Size / Label Offset
Keeps labels readable and away from candle bodies.
🔶 BEST USE CASE
Breakout Volume Quality works best when the chart has visible defended levels and the user wants a cleaner way to judge whether the break had enough participation behind it.
It is especially useful for:
- Breakouts through repeated swing highs or swing lows.
- Range exits where volume quality matters.
- Comparing strong break candles against weak level pokes.
- Reviewing whether a breakout level later behaves as a confirmation band.
- Keeping weak break attempts visible without giving them the same visual weight as confirmed events.
The script is intentionally restrained: no oversized dashboard, no heavy channel system, no session dependency, and no unnecessary signal spam. The chart stays focused on the level, the break, the volume verdict, and the retest state.
🔹 ALERTS
The script includes alert conditions for:
- Bullish breakout volume confirmation.
- Bearish breakout volume confirmation.
- Breakout failed volume confirmation.
- Breakout retest hold.
- Breakout failed back inside.
These alerts are event prompts for chart review and workflow organization.
💎 DESIGN PHILOSOPHY
Breakout Volume Quality is built to feel clean, premium, and practical on a public PulseWire chart.
The visual hierarchy is deliberate:
- Confirmed breaks are visible but not loud.
- Cleaner weak confirmations are faded and labeled through a score filter, while low-quality weak breaks stay visually softer.
- Decision rails keep active levels visible between major events.
- Labeled setup windows explain where pre-breakout volume pressure is forming.
- Optional activity layers are available, but the default chart does not rely on unlabeled dots.
- Bands are long enough to make the level meaningful.
- Retest labels appear only when the state actually changes.
- The panel stays compact and focused on the fields that matter.
The result is a breakout tool that is easy to understand at first glance, but still has enough structure underneath to support serious review.
Indicator

Artemis Volatility Bands PRO🟦 Artemis Volatility Bands PRO is a price-overlay volatility indicator built on the KernelLens Nadaraya–Watson regression library (a_jabbaroff/KernelLens/1). A single kernel estimate — selectable from eight classical kernel families — anchors the Basis line. Around it, two outer bands fan outward by a fixed multiple of the residual standard deviation, creating an envelope whose width is model-consistent with the kernel. The interior is washed with a 6-layer neon halo that mirrors the statistical density of price residuals under normality. A signal engine detects basis-breaks with confirming slope direction, guarded by Confirmed (zero-repaint) or Realtime mode. Twelve cohesive color themes, a theme-aware Dark / Light dashboard, and four opt-in alert conditions complete the indicator.
🟦 HOW IT WORKS
Artemis Volatility Bands PRO fuses two mathematical operations on every bar — a single kernel regression pass and a residual standard deviation calculation:
basis = kl.estimate(type, src, ℓ, α, period, phase, filter)
sigma = kl.confidenceBand(src, basis, window)
upper = basis + k · σ
lower = basis − k · σ
where ℓ is the Primary Bandwidth, k is the Band Multiplier, and window is the Residual σ Window. The kernel regression produces the Basis line, and the residual standard deviation (σ of price − basis) produces the per-σ band half-width.
This architecture collapses classical Bollinger band duality: in Bollinger bands, the moving average and volatility estimate live in different statistical universes. In Artemis, both emerge from a single kernel pass, so the envelope is internally consistent by construction. The Basis is always non-parametric, and the band width always measures deviation relative to the Basis, never to a disconnected moving average.
The library handles all weighted-sum computation, kernel weight evaluation, NA-safe iteration, division-by-zero guards, and input validation internally. Artemis Volatility Bands PRO does not reimplement any kernel math — every bug fix or optimization in the library automatically propagates to this indicator.
🟦 KERNEL LIBRARY INTEGRATION
Artemis Volatility Bands PRO imports the published KernelLens library and uses the following exports:
| Library Export | Used For |
|---|---|
| `kl.estimate()` | Unified dispatcher — routes to the correct kernel based on the user's Kernel Type dropdown. Called once per bar to produce the Basis line. |
| `kl.confidenceBand()` | Rolling residual standard deviation — computes σ of (source − basis) over the specified window. |
| `kl.trendState()` | Ternary trend detector — returns +1 (rising), 0 (flat), or −1 (falling) based on a 1-bar finite difference of the Basis. |
Every regression computation — kernel weight evaluation, NA-safe summation, bandwidth-aware loop termination — is delegated to the library. The indicator itself contains zero kernel math; it only orchestrates three library calls and aggregates their outputs into the band envelope and signal logic.
🟦 KERNEL REGRESSION & RESIDUAL VOLATILITY
**The Basis line** — A non-parametric kernel regression anchored to the user's choice of price source (default: close; also supports hl2, ohlc4, custom). Eight kernel families available:
| Kernel | Behavior | Best For |
|---|---|---|
| Rational Quadratic | Multi-scale mixer; α controls stretch | Default, balanced responsiveness |
| Gaussian / RBF | Canonical smoother, infinitely differentiable | Smooth trend, minimize noise |
| Periodic | Resonates with a known repetition distance p | Cyclic markets, seasonal patterns |
| Locally Periodic | Periodic × gaussian blend | Seasonal + trend drift |
| Epanechnikov | MSE-optimal, compact support | Minimal tail contamination |
| Tricube | LOWESS standard, near-Gaussian profile | Fast computation, robust |
| Triangular | Simplest compact kernel | Lightweight, real-time responsiveness |
| Cosine | Raised-cosine, smooth boundary transition | Smooth rolloff, professional appearance |
Three filter modes applied on top of the raw kernel estimate:
| Filter | Description | Use Case |
|---|---|---|
| No Filter | Single-pass Nadaraya–Watson | Rawest output, maximum responsiveness |
| Smooth | Double-pass: kernel applied to its own output | Cleaner, slightly more lag |
| Zero Lag | Ehlers de-lagging: 2·raw − smooth | Sharpens edges without increasing lag |
**Residual volatility** — Once the Basis is computed, the per-bar residual is (source − basis). The residual standard deviation is the rolling σ of this residual over a configurable window (default: 14 bars). This is the model-consistent volatility estimate — price deviations are measured relative to the kernel Basis, guaranteeing alignment between trend and volatility.
**Band levels** — upper = basis + k · σ and lower = basis − k · σ, where k is the Band Multiplier (default: 2.0, Bollinger-style). The multiplier is user-adjustable from 0.5 (tight) to 5.0 (wide).
🟦 SIGNAL ENGINE
Artemis fires Long / Short signals when price breaks the Basis with a confirming slope direction:
Long → close > basis AND basis rising
Short → close < basis AND basis falling
The signal state is persistent — once a direction flips, it remains latched until the opposite condition fires. This state machine (vii ∈ {−1, 0, +1}) ensures the Basis hue stays coherent across bars even when the raw trigger is a single-bar event.
Signal markers fire ONLY on the bar the state flips, not on every bar that satisfies the raw condition. This keeps the chart uncluttered and mirrors how discretionary traders consume trend-flip information.
**Signal Mode** — Two gating options:
| Mode | Behavior | Repaint |
|---|---|---|
| Confirmed | Signals fire ONLY after the bar closes via `barstate.isconfirmed` | Zero repaint, fully reliable for live trading |
| Realtime | Signals fire on the current (open) bar as soon as the condition is met | Fastest reaction; signal may vanish if price reverses before bar closes |
Historical repainting never occurs at any Signal Mode value. The library's `_phase` parameter shifts every kernel center into the past by that many bars, so historical bars' plotted values are final once confirmed.
🟦 6-LAYER NEON HALO VISUALIZATION
The interior between the Basis and each outer band is filled with a 6-layer gradient: 5 interior step plots plus the outer band, creating a stepped transparency schedule that mirrors the statistical density of price residuals under normality.
**Transparency schedule:**
| Layer | Transparency | Meaning |
|---|---|---|
| Outer band ↔ 1st interior | 70 % | Densest layer |
| 1st ↔ 2nd | 78 % | |
| 2nd ↔ 3rd | 85 % | |
| 3rd ↔ 4th | 90 % | |
| 4th ↔ 5th | 95 % | |
| 5th ↔ Basis | 98 % | Nearly invisible fade to centerline |
Every transparency value is scaled by the Gradient Intensity input (0–100 %), so the user can dial the visual density from invisible (0) to heavy fills (100).
**Color assignment:**
- Upper band + gradient: Bearish theme hue (short signal color)
- Lower band + gradient: Bullish theme hue (long signal color)
- Basis line: Slope-adaptive color (thBull when rising, thBear when falling, previous color on flat bars)
**Signal markers** — Two-layer neon glow plotshapes:
- Halo: size.small, 40 % opaque theme hue (glow layer)
- Core: size.tiny, 100 % opaque theme hue (bright center)
🟦 THEME SYSTEM
Twelve cohesive color palettes tuned to every trading aesthetic. One selection drives every visual component — Basis line, outer bands, gradient halos, long / short signal markers, dashboard accents — all sharing the same bull / bear / neutral color axes:
| Theme | Bull | Bear | Usage |
|---|---|---|---|
| Tropic | Cyan steel | Deep orange | Default, electric contrast |
| Amber | Warm amber | Indigo blue | Fire tones |
| Pastel | Sky blue | Soft lavender | Cool arctic glow |
| Cyber | Neon lime | Hot crimson | Cyber terminal aesthetic |
| Helios | Bright gold | Scarlet | Solar warmth |
| Electric | Electric aqua | Magenta | High-voltage neon |
| Candy | Neon green | Hot pink | Dark energy pop |
| Bloomberg | Terminal orange | Cyan | Wall Street finance heritage (PRO) |
| Solar | Solarized olive | Crimson | Developer palette, easy on eyes (PRO) |
| Royal | Imperial gold | Deep purple | Luxury signature (PRO) |
| Midnight | Deep navy | Dark crimson | Dark depth |
| Graphite | Near-black | Silver grey | Monochrome minimal |
**Dashboard display modes** — Dark (black background, bright accents) or Light (white background, darker accents), auto-adapting visual contrast regardless of chart background.
🟦 DASHBOARD
A 2-column, 9-row theme-aware status panel that updates only on the last bar (zero historical overhead). Supports Dark and Light display modes, six docking positions, and four text sizes. Renders via `force_overlay = true` on the main price chart.
| Row | Label | Content |
|---|---|---|
| Header | ARTEMIS PRO | DARK / LIGHT |
| Theme | Theme | Active palette name |
| Divider | KERNEL | — |
| Type | Type | Selected kernel type |
| Bandwidth ℓ | Bandwidth ℓ | Primary bandwidth + Phase φ |
| Basis | Basis | Current Basis value in chart mintick format |
| Divider | VOLATILITY | — |
| Residual σ | Residual σ | Current residual standard deviation |
| Signal | Signal | ▲ LONG / ▼ SHORT / ━ FLAT (direction-colored) |
🟦 ALERT CONDITIONS
Four opt-in alert conditions, each gated by its own toggle:
| Alert | Fires When |
|---|---|
| Long Signal | Price breaks above the Basis with a rising slope (confirmed state flip) |
| Short Signal | Price breaks below the Basis with a falling slope (confirmed state flip) |
| Upper Band Touch | Price touches or exceeds the upper outer band (raw crossover) |
| Lower Band Touch | Price touches or falls below the lower outer band (raw crossunder) |
Band touch alerts are useful as pre-signal early warnings in trending markets. Signal alerts are gated by the Signal Mode setting, so Confirmed mode ensures zero-repaint alerts suitable for live trading.
All alerts use `alertcondition()` for maximum compatibility with PulseWire's alert system including webhooks. Messages are structured as `"Artemis Volatility Bands: "` for easy parsing in downstream automation.
🟦 RECOMMENDED PRESETS
| Trading Style | Bandwidth ℓ | Filter | Residual σ Window | Phase |
|---|---|---|---|---|
| Scalper | 10–20 | No Filter | 8–10 | 1 |
| Day Trader | 20–40 | Smooth | 14 | 2 |
| Swing | 30–60 | Smooth | 20–40 | 2 |
| Position | 60–120 | Smooth | 40–60 | 3 |
**Bandwidth tuning** — Smaller ℓ produces a tighter fit to price and faster reaction; larger ℓ produces smoother curves and more stability. Experiment with ℓ in your preferred style's range, then adjust the Residual σ Window and Filter mode for visual smoothness.
**Phase tuning** — Phase = 0 is live (flickers on the current bar); Phase = 2 is the recommended balance; Phase = 3+ adds margin against noise at the cost of lag. Historical charts are immutable at any phase value.
🟦 KERNEL-ONLY DESIGN PHILOSOPHY
Artemis Volatility Bands PRO contains zero classical technical analysis bolt-ons. No Bollinger Bands, no Keltner Channels, no linear regression, no ATR, no moving averages — only kernel regression and residual volatility. This kernel-only architecture guarantees that:
1. **Internal consistency** — The Basis and band width emerge from a single statistical model, not from mixing independent techniques.
2. **Unified parameterization** — All visual outputs (Basis, bands, gradient) are controlled by a single set of kernel-theoretic parameters.
3. **No analytical compromise** — Every choice in the indicator is mathematically motivated; no ad-hoc decorations.
The philosophy is defensive: traders who layer Artemis on top of their own edge strategies get a pure kernel-regression envelope that will not conflict with classical-TA signals already in use. Traders seeking a standalone kernel-based indicator get a complete, coherent system.
🟦 COMPATIBILITY
- Pine Script v6
- All exchanges, all asset classes (crypto, forex, equities, commodities, indices)
- All timeframes (1 minute through Monthly)
- Both Dark and Light chart themes — visual elements auto-adapt to chart background
- No exchange-specific logic — fully deterministic
Indicator renders on the main overlay chart with `force_overlay = true`. No secondary panes, no subplot logic.
🟦 TECHNICAL NOTES
- **Library dependency** — `import a_jabbaroff/KernelLens/1` — all kernel regression math is delegated to the published library
- **Plot budget** — 2 outer bands + 10 gradient interior plots + 1 Basis + 1 transparent anchor + 4 signal shapes + 12 fills + 4 alertconditions = 34 outputs, well under Pine's 64-output hard limit (50 % margin)
- **Table** — Single `var table` created once on `barstate.islast` with `force_overlay = true`; dashboard renders on the main chart pane, zero historical overhead
- **No persistent drawing objects** — no `box.new`, `line.new`, no `array.new`; all visuals are plots and fills
- **Opacity convention** — every user-facing opacity / transparency input follows `0 = invisible, 100 = fully opaque`; conversion to Pine's native transparency is centralized in a single helper function (`f_opac`)
- **Non-repainting** — inherits from the library's `_phase` parameter; no `request.security`, no lookahead, no future-bar leakage at any phase value
- **Residual consistency** — The residual σ is computed as `ta.stdev(source − basis, window)`, ensuring the band width always measures deviation relative to the kernel Basis
🟦 DISCLAIMER
Artemis Volatility Bands PRO is a technical analysis indicator built on the KernelLens Nadaraya–Watson regression library. It is provided solely for educational and research purposes and does not constitute financial, investment, or trading advice.
Kernel regression is a local smoothing technique. It estimates the mean of a source series in the neighborhood of the current bar based on historical data, but it does not predict future prices, does not generate trading signals on its own, and does not guarantee the profitability of any strategy built on top of its output. The signal engine is a mechanical detector of basis breaks and slope direction — not a forecast — and should always be combined with broader context: higher-timeframe structure, volatility regime, liquidity, news, and risk management.
Past performance of any model does not guarantee future results. Markets contain systemic risks that cannot be eliminated by any amount of mathematical rigor. Responsibility for any trading decisions rests entirely with the user. Always apply sound capital management, conduct your own independent analysis, and never risk capital you are not prepared to lose.
The author assumes no liability for direct or indirect losses incurred through the use of Artemis Volatility Bands PRO or the underlying KernelLens library. Indicator

Artemis Regression Bands🟦 Artemis Regression Bands is a kernel-driven volatility envelope indicator built on the KernelLens Nadaraya–Watson regression library (a_jabbaroff/KernelLens/1). A single kernel estimate — selectable from eight classical kernel families — anchors the Fair Value line. Around it, three residual-standard-deviation bands (±1σ, ±2σ, ±3σ) fan outward with either Linear or Exponential spacing, producing a statistically grounded envelope far cleaner than the classical close-stdev approach used by legacy Bollinger-style indicators. A four-gate Romb signal engine overlays buy / sell diamond markers when price pokes through the outermost enabled σ boundary and reverses back inside.
🟦 HOW IT WORKS
Artemis calls the KernelLens library's unified dispatcher once per bar to build the Fair Value line, then queries three additional library exports to derive the band widths, slope direction, and residual σ:
```
fair = kl.estimate (type, src, ℓ, α, period, phase, filter)
sigma = kl.confidenceBand(src, fair, window)
slopeVal = kl.slope (fair, 1)
trendSt = kl.trendState (fair, 1)
dev = baseMult · sigma
upper1 = fair + 1·dev lower1 = fair − 1·dev
upper2 = fair + 2·dev lower2 = fair − 2·dev
upper3 = fair + k3·dev lower3 = fair − k3·dev (k3 = 3 Linear | 4 Exp)
```
The library handles all weighted-sum computation, loop-depth selection, NA-safe iteration, division-by-zero guards, and input validation internally. Artemis contains zero kernel math — every bug fix or optimization in the library automatically propagates to this indicator.
🟦 KERNEL LIBRARY INTEGRATION
Artemis imports the published KernelLens library and uses the following exports:
| Library Export | Used For |
|---|---|
| `kl.estimate()` | Unified dispatcher — routes to the correct kernel based on the user's Kernel Type dropdown. Called once per bar to produce the Fair Value line. |
| `kl.confidenceBand()` | Rolling standard deviation of the (source − Fair Value) residual. Drives the band half-widths on every bar. |
| `kl.slope()` | Discrete first derivative of the Fair Value line. Feeds trend flip alerts. |
| `kl.trendState()` | Ternary classifier (+1 rising / −1 falling / 0 flat) of the Fair Value line. Drives the slope-adaptive color, the kernel trend confluence filter, and the dashboard Trend row. |
Every regression computation — kernel weight evaluation, NA-safe summation, bandwidth-aware loop termination, residual stdev, finite-difference slope — is delegated to the library. The indicator itself only orchestrates the four library calls and layers the visual pipeline on top.
🟦 EIGHT KERNEL FAMILIES
A single Kernel Type dropdown selects any of the eight kernels shipped with the KernelLens library. Each is a different mathematical smoother with its own statistical character:
| Kernel | Formula | Best For |
|---|---|---|
| Rational Quadratic | (1 + d² / (2·α·ℓ²))^(−α) | Multi-scale mixer; α controls stretch. Recommended default. |
| Gaussian / RBF | exp(−d² / (2·ℓ²)) | Canonical smoother; infinitely differentiable. |
| Periodic | exp(−2·sin²(π·d/p) / ℓ²) | Resonates with a known repetition distance p. |
| Locally Periodic | Periodic × Gaussian | Seasonal patterns with slow trend drift. |
| Epanechnikov | (3/4)·(1 − u²), \|u\| ≤ 1 | MSE-optimal; compact support, no tail contamination. |
| Tricube | (70/81)·(1 − \|u\|³)³, \|u\| ≤ 1 | LOWESS standard; near-Gaussian compact profile. |
| Triangular | (1 − \|u\|), \|u\| ≤ 1 | Simplest compact kernel; cheapest to compute. |
| Cosine | (π/4)·cos(π·u/2), \|u\| ≤ 1 | Raised-cosine; smooth boundary transition. |
Because the dropdown feeds the library's `kl.estimate()` dispatcher directly, every kernel inherits the same three-mode filter layer (No Filter / Smooth / Zero Lag) and the same non-repainting guarantees — there is no special case per kernel in Artemis.
🟦 FILTER LAYER
A second dropdown applies an optional post-processing layer on top of the raw Nadaraya–Watson estimate:
| Filter | Formula | Trade-off |
|---|---|---|
| No Filter | ŷ = ŷ_raw | Single-pass kernel. Rawest output, most reactive. |
| Smooth | ŷ = K(ŷ_raw) | Double-pass — kernel applied to its own output. Cleaner line, slightly more lag. |
| Zero Lag | ŷ = 2·ŷ_raw − K(ŷ_raw) | Ehlers de-lagging identity — sharpens edges without adding lag. |
The filter is resolved entirely inside `kl.estimate()`, so switching modes incurs no runtime cost beyond the extra kernel pass.
🟦 RESIDUAL-σ BAND ENGINE
Artemis bands are statistically grounded on the residual standard deviation — not on raw close stdev as in classical Bollinger indicators. The residual is computed as:
```
residual = src − fair
sigma = ta.stdev(residual, window) // via kl.confidenceBand()
```
Because Fair Value is already an unbiased local estimate of the source, the residual is a zero-mean noise series and its stdev captures **only the portion of price variance that the kernel could not explain**. This produces three benefits over the classical approach:
1. **Tighter bands in trending regimes** — close-stdev widens during strong trends because the trend itself inflates the variance; residual-σ does not, because the kernel absorbs the trend.
2. **Faster reaction to volatility regime changes** — residual-σ tightens as soon as the kernel fits well, and widens the instant the market breaks out of the kernel's neighborhood.
3. **True statistical interpretation** — under the assumption of locally Gaussian residuals, ±1σ / ±2σ / ±3σ enclose approximately 68 % / 95 % / 99.7 % of near-term price variation. The traditional close-stdev envelope carries no such interpretation.
A dedicated Residual σ Window input controls the lookback; typical values range from 50 (reactive, scalping) to 300 (stable, position trading).
🟦 BAND SPACING MODES
Two spacing presets shape the outward fan of the three σ bands:
| Mode | Multipliers | Character |
|---|---|---|
| Linear | 1·, 2·, 3· | Classical Bollinger-style uniform steps. Predictable, symmetric. |
| Exponential | 1·, 2·, 4· | Fibonacci-flavored — outer band (4σ) is reserved for genuine blow-off excursions. |
Base Multiplier scales all three bands uniformly (default 1.0). The formula is:
```
band_level = fair ± (baseMult · k · sigma) k ∈ {1, 2, k3}
```
where k3 resolves to 3 in Linear mode and 4 in Exponential mode. Every band has an independent visibility toggle, so minimalist users can run ±1σ only, swing traders ±3σ only, or any combination.
🟦 FOUR-GATE ROMB SIGNAL ENGINE
The Romb engine prints buy / sell diamond markers when price pokes through the outermost enabled σ band and reverses back inside. Four sequential gates protect against false entries:
| Gate | Logic | Purpose |
|---|---|---|
| 1 — Crossover | `ta.crossunder(high, triggerUp)` / `ta.crossover(low, triggerDn)` | Detects the reversal back through the outer band. |
| 2 — Warm-up | Residual σ computable for N consecutive bars | Blocks signals during the early kernel-settlement window. |
| 3 — Confluence | Fair Value slope aligns with the reversal direction | Optional PRO filter — Sell Romb requires falling kernel, Buy Romb requires rising kernel. |
| 4 — Cooldown | Minimum bar gap since the last same-side Romb | Prevents signal clustering on a single extended poke-and-reverse sequence. |
A Signal Mode toggle layers on top:
- **Confirmed** — signals fire only on `barstate.isconfirmed`; zero repaint on closed bars.
- **Realtime** — signals fire live on the current open bar; faster reaction, may vanish if price reverses before close.
Each confirmed signal is rendered as a two-layer neon diamond:
- **Halo** — `size.small`, 40 % transparent theme hue (glow layer).
- **Core** — `size.tiny`, fully opaque theme hue (bright center).
The halo renders first so the core sits cleanly on top, producing a sharp luminous marker that reads instantly even on dense price charts.
🟦 ADAPTIVE OUTER-BAND TRIGGER
The Romb engine does not hard-code the ±3σ band as the signal trigger. Instead, it resolves the outermost currently-enabled band on every bar:
```
triggerUp = show3 ? upper3 : show2 ? upper2 : show1 ? upper1 : na
triggerDn = show3 ? lower3 : show2 ? lower2 : show1 ? lower1 : na
```
The result is an envelope that respects the user's visibility choices:
| Visible Bands | Romb Fires At |
|---|---|
| ±1σ + ±2σ + ±3σ | ±3σ (default) |
| ±1σ + ±2σ | ±2σ |
| ±1σ only | ±1σ |
| All off | no signals |
Diamond positioning follows the same trigger, so the glyph always floats ~0.3σ outside whatever envelope is actually drawn on the chart. The behavior matches user intent: the band I can see is the band that fires signals.
🟦 NON-REPAINTING BEHAVIOR
Artemis inherits non-repainting behavior directly from the KernelLens library's `_phase` parameter. A single Phase input (default 2) shifts the kernel center into the past by that many bars:
- **Phase = 0** — live estimate, flickers on the current bar (real-time only; history is immutable).
- **Phase = 1** — 1-bar lag, non-repainting once the bar is confirmed.
- **Phase = 2** — recommended balance between freshness and stability (default).
- **Phase = 3+** — extra margin against erratic ticks, higher lag.
Historical repainting never occurs at any phase value. The library contains no `request.security` calls, no lookahead, and no array rotation that could leak future data. Every historical bar's plotted Fair Value, band, and Romb signal is final once confirmed.
🟦 VISUAL PIPELINE
**σ Band Outlines** — Three upper bands (±1σ / ±2σ / ±3σ) in progressively lighter `thBear` hues, three lower bands in progressively lighter `thBull` hues. Hidden bands collapse to na via their individual visibility toggles; the outline widths share a single Band Line Width input.
**Tapered Gradient Fills** — Six fills drawn between the Fair Value line and each σ band. Opacity scales progressively from ±1σ (densest, most opaque) to ±3σ (lightest, most transparent), creating a halo that mirrors the statistical density of price residuals under normality. Master Fill Opacity input (0 = invisible, 100 = fully opaque) scales all three fills uniformly.
**Fair Value Line** — Slope-adaptive color resolver swaps between `thBull` (rising kernel) and `thBear` (falling kernel). Flat bars retain the previous color so the line never flashes neutral on a perfectly horizontal tick. Width is user-controlled (1–5 px).
**Romb Diamonds** — Two-layer neon glow at the adaptive trigger band; halo + core rendering described above.
**Bar Coloring** — Optional theme-aware candle coloring driven by the Fair Value slope. Off by default; when enabled it paints every bar with the active theme's bull / bear hue based on the current trend state.
🟦 THEME SYSTEM
Twelve cohesive color palettes drive every visual component — Fair Value line, σ band outlines, gradient fills, Romb diamonds, bar coloring, and dashboard accents — all sharing the same four color axes (`thBull`, `thBear`, `thNeutral`, `thSignal`):
| Theme | Bull | Bear |
|---|---|---|
| Tropic | Cyan steel | Deep orange |
| Amber | Warm amber | Indigo blue |
| Pastel | Sky blue | Soft lavender |
| Cyber | Neon lime | Hot crimson |
| Helios | Bright gold | Scarlet |
| Electric | Electric aqua | Magenta |
| Candy | Neon green | Hot pink |
| Bloomberg | Terminal orange | Cyan |
| Solar | Solarized olive | Crimson |
| Royal | Imperial gold | Deep purple |
| Midnight | Deep navy | Dark crimson |
| Graphite | Near-black | Silver grey |
A separate Display Mode toggle (Dark / Light) controls the dashboard palette independently of the chart theme — so a Bloomberg chart theme with a Light dashboard is a valid configuration, as is Midnight chart + Dark dashboard.
🟦 DASHBOARD
A 2-column, 12-row theme-aware status panel that updates only on the last bar (zero historical overhead). Supports Dark and Light display modes, six docking positions, and four text sizes. Renders via `force_overlay = true` on the main price chart.
| Row | Label | Content |
|---|---|---|
| Header | ARTEMIS | DARK / LIGHT |
| Theme | Theme | Active palette name |
| Kernel | Kernel | Selected kernel type |
| Divider | REGRESSION | — |
| Bandwidth | Bandwidth ℓ | Bandwidth value / Phase offset φ |
| Filter | Filter | No Filter / Smooth / Zero Lag |
| Fair Value | Fair Value | Current Fair Value in chart mintick format |
| Divider | BANDS | — |
| Spacing | Spacing | Linear 1·/2·/3· or Exp 1·/2·/4· |
| Residual σ | Band σ | Rolling residual standard deviation |
| Trend | Trend | ▲ BULL / ▼ BEAR / ━ FLAT (bull/bear colored) |
| Last Romb | Last Romb | ▲ BUY (N ago) / ▼ SELL (N ago) — bull/bear colored |
**Zebra-stripe layout** — alternating `dashBg` / `dashBgAlt` row backgrounds improve scan-ability on narrow cells. Section dividers (REGRESSION, BANDS) use a third background tone (`dashSection`) with the theme's bull accent as the header color — preserving brand identity across both Display Modes.
🟦 ALERT CONDITIONS
Six opt-in alert conditions, each gated by its own toggle:
| Alert | Fires When |
|---|---|
| Bullish Trend Flip | Fair Value slope crosses from ≤ 0 into positive territory |
| Bearish Trend Flip | Fair Value slope crosses from ≥ 0 into negative territory |
| Buy Romb | Confirmed Buy Romb fires — all four signal gates passing |
| Sell Romb | Confirmed Sell Romb fires — all four signal gates passing |
| Upper Band Touch | Price touches or exceeds the outermost enabled upper band |
| Lower Band Touch | Price touches or falls below the outermost enabled lower band |
All alerts use `alertcondition()` for maximum compatibility with PulseWire's alert system including webhooks. Messages are structured as `"Artemis Regression Bands: "` for easy parsing in downstream automation. Touch alerts are off by default (can be noisy in trending markets); the four core alerts are on by default.
🟦 RECOMMENDED PRESETS
| Style | Bandwidth ℓ | Filter | Phase | Spacing | σ Window | Chart |
|---|---|---|---|---|---|---|
| Scalper | 10–20 | No Filter | 1 | Linear | 50–80 | 1m–5m |
| Day Trader | 20–40 | Smooth | 2 | Linear | 80–120 | 15m–1h |
| Swing | 30–60 | Smooth | 2 | Linear or Exp | 100–200 | 4h–1D |
| Position | 60–120 | Smooth or Zero Lag | 3 | Exp | 200–300 | 1D–1W |
**Kernel type tuning**
- **Trending instruments** — Rational Quadratic (α = 1–3) or Gaussian. Smooth multi-scale response.
- **Mean-reverting instruments** — Epanechnikov or Tricube. Compact support keeps the band envelope tight.
- **Session-cyclic patterns** — Periodic (with p = session length in bars) or Locally Periodic. Resonates with known cycles.
**Romb filter tuning** — Keep Kernel Trend Confluence ON for high-conviction setups only. Switch OFF on range-bound instruments to capture both sides of the oscillation.
🟦 COMPATIBILITY
- Pine Script v6
- All exchanges, all asset classes (crypto, forex, equities, commodities, indices)
- All timeframes (1 minute through Monthly)
- Both Dark and Light chart themes — the Display Mode toggle controls dashboard palette independently
- No exchange-specific logic — fully deterministic
🟦 TECHNICAL NOTES
- **Library dependency** — `import a_jabbaroff/KernelLens/1` — all kernel regression, residual σ, slope, and trend-state math is delegated to the published library.
- **Plot budget** — 6 band plots + 1 Fair Value anchor + 1 Fair Value visible + 6 gradient fills + 4 Romb plotshapes + 1 barcolor = well under Pine's plot limits.
- **Table** — Single `var table` rebuilt on `barstate.islast` with `force_overlay = true`; zero historical overhead.
- **Signal state** — Two `var int` cooldown anchors (`lastSellBar`, `lastBuyBar`) seeded at −10000 so the very first bar always passes the gap test. A `var int stabCount` warm-up counter blocks signals during early kernel settlement.
- **No persistent drawing objects** — no `box.new`, `line.new`, no array rotations; every visual is either a plot or a single-bar plotshape.
- **Adaptive trigger resolver** — Romb crossover detection, touch alerts, and diamond positioning all read from the same `triggerUp` / `triggerDn` resolver, so band visibility toggles stay semantically coherent across every layer of the indicator.
- **Non-repainting** — inherits from the library's `_phase` parameter; no `request.security`, no lookahead, no future-bar leakage at any phase value.
🟦 DISCLAIMER
Artemis Regression Bands is a technical analysis indicator built on the KernelLens Nadaraya–Watson regression library. It is provided solely for educational and research purposes and does not constitute financial, investment, or trading advice.
Kernel regression is a local smoothing technique. It estimates the mean of a source series in the neighborhood of the current bar based on historical data, but it does not predict future prices, does not generate trading signals on its own, and does not guarantee the profitability of any strategy built on top of its output. The residual-σ envelope describes past dispersion around the kernel estimate — not a forecast of future range — and should always be combined with broader context: higher-timeframe structure, volatility regime, liquidity, news, and risk management.
Past performance of any model does not guarantee future results. Markets contain systemic risks that cannot be eliminated by any amount of mathematical rigor. Responsibility for any trading decisions rests entirely with the user. Always apply sound capital management, conduct your own independent analysis, and never risk capital you are not prepared to lose.
The author assumes no liability for direct or indirect losses incurred through the use of Artemis Regression Bands or the underlying KernelLens library. Indicator

Quant Edge Ribbon PRO🟦 Quant Edge Ribbon PRO is a multi-kernel divergence ribbon indicator built on the KernelLens Nadaraya–Watson regression library (a_jabbaroff/KernelLens/1). A primary kernel and eleven longer-bandwidth kernels form a dual-ribbon visualization driven by kernel regression mathematics, an integer trend score in , a theme-aware rendering pipeline, four user-configurable reference levels, and a PRO dashboard. All twelve kernels route through the unified library dispatcher, so the user may select any of the eight kernel families and any of the three filter modes from a single configuration panel.
🟦 HOW IT WORKS
Quant Edge Ribbon PRO calls the KernelLens library's unified dispatcher (`kl.estimate`) twelve times per bar — once for the primary kernel and once for each of the eleven outer kernels:
```
primary = kl.estimate(type, src, ℓ, α, period, phase, filter)
long00 = kl.estimate(type, src, ℓ + 1·s, α, period, phase, filter)
long01 = kl.estimate(type, src, ℓ + 2·s, α, period, phase, filter)
...
long10 = kl.estimate(type, src, ℓ + 11·s, α, period, phase, filter)
```
where ℓ is the Primary Bandwidth and s is the Bandwidth Step. All twelve kernels share the same kernel type, filter, shape α, period, and phase — only the bandwidth differs. This guarantees the ribbon behaves as a coherent spectrum of kernel scales rather than a mixture of unrelated signals.
The library handles all weighted-sum computation, loop-depth selection, NA-safe iteration, division-by-zero guards, and input validation internally. Quant Edge Ribbon PRO does not reimplement any kernel math — every bug fix or optimization in the library automatically propagates to this indicator.
🟦 KERNEL LIBRARY INTEGRATION
Quant Edge Ribbon PRO imports the published KernelLens library and uses the following export:
| Library Export | Used For |
|---|---|
| `kl.estimate()` | Unified dispatcher — routes to the correct kernel based on the user's Kernel Type dropdown. Called twelve times per bar, once for the primary kernel and once for each of the eleven outer kernels. |
Every regression computation — kernel weight evaluation, NA-safe summation, bandwidth-aware loop termination — is delegated to the library. The indicator itself contains zero kernel math; it only orchestrates twelve library calls and aggregates their outputs into the trend score.
🟦 THE TWELVE-KERNEL RIBBON ARCHITECTURE
**Primary kernel (the shortest, the anchor)** — A single kernel at bandwidth ℓ that serves two roles: (1) it is the reference baseline for the trend score calculation, and (2) it is plotted as a dedicated highlighted anchor line when the "Highlight Primary Kernel" toggle is ON.
**Eleven outer kernels (progressively wider)** — Kernels at bandwidths ℓ+1·s, ℓ+2·s, …, ℓ+11·s, where s is the Bandwidth Step (default: 1). Each outer kernel is plotted as a line on the main chart, all eleven sharing a single score-driven gradient color — so the entire outer ribbon shifts between the theme's bull and bear hues as the trend score moves between −11 and +11.
**Eleven inner ribbon plots (lagged primary snapshots)** — The primary kernel plotted at eleven time-lag offsets (0, 1, 2, …, 10 bars). The resulting visual is a gently flowing shadow that makes expansion and contraction of the outer ribbon easier to perceive. Opacity is user-controlled (default: 40 %).
🟦 INTEGER TREND SCORE
The trend score is a signed integer in , computed on every bar by eleven pairwise comparisons between the primary kernel (at progressive lag offsets) and the eleven outer kernels:
```
score = 0
for i in 0..10:
if primary < long_i:
score += 1
else:
score -= 1
```
**Semantic interpretation** — Each comparison pairs an older snapshot of the shortest kernel against a current snapshot of a progressively wider kernel. In an uptrend, past primary values are lower while current wider-kernel values have caught up above them — the inequality resolves positive on most pairs and the score climbs toward +11. The symmetric argument drives the score toward −11 in a downtrend.
**Score parity** — Because the score is a sum of eleven ±1 terms (score = 2k − 11, k ∈ ), it is always odd. Reachable values: { −11, −9, −7, −5, −3, −1, 1, 3, 5, 7, 9, 11 }. The score is never exactly zero.
🟦 STRENGTH CATEGORIZATION
The absolute score is bucketed into four bands, each with a matched label glyph used throughout the dashboard and the last-bar signal label:
| Score Range | Strength | Label |
|---|---|---|
| \|score\| = 1 | NEUTRAL | ▰▱▱▱ NEUTRAL |
| \|score\| ∈ {3, 5} | WEAK | ▰▰▱▱ WEAK BULL / WEAK BEAR |
| \|score\| = 7 | STRONG | ▰▰▰▱ STRONG BULL / STRONG BEAR |
| \|score\| ∈ {9, 11} | TRIPLE | ▰▰▰▰ TRIPLE BULL / TRIPLE BEAR |
The bull / bear suffix is driven by the sign of the score. The progress-bar glyphs (▰▱) give an instant at-a-glance read of confluence intensity without needing to parse the numeric value.
🟦 NON-REPAINTING BEHAVIOR
Quant Edge Ribbon PRO inherits non-repainting behavior directly from the KernelLens library's `_phase` parameter. A single Phase input (default: 2) shifts every one of the twelve kernel centers into the past by that many bars.
- Phase = 0 — live estimate, flickers on the current bar (real-time only; history is immutable)
- Phase = 1 — 1-bar lag, non-repainting once the bar is confirmed
- Phase = 2 — recommended balance between freshness and stability (default)
- Phase = 3+ — extra margin against erratic ticks, higher lag
Historical repainting never occurs at any phase value. The library contains no `request.security` calls, no lookahead, and no array rotation that could leak future data. Every historical bar's plotted value is final once confirmed.
🟦 VISUAL PIPELINE
**Outer Ribbon Gradient** — All eleven outer kernels are plotted with a single shared color driven by the trend score via `color.from_gradient(score, -11, 11, thBear, thBull)`. As the score walks across its range, the entire ribbon shifts continuously between the active theme's bearish and bullish hues — producing a smooth visual feedback loop between the math and the palette.
**Inner Ribbon Shadow Trail** — Eleven lag-shifted primary snapshots (primary through primary ) drawn in the theme's accent hue with user-controlled opacity. On a trending chart the trail visually expands; on a reversing chart it contracts. Adjust opacity from 0 (invisible) to 100 (fully opaque) — default 40 balances presence and subtlety.
**Primary Kernel Anchor Line** — The primary kernel plotted as a dedicated bold line in the theme's accent color at 80 % opacity, distinct from the shadow trail. Provides a clear centerline amid the ribbon flow. Toggleable.
**Oscillator Subplot** — The smoothed trend score plotted in a dedicated subplot with a score-gradient vertical fill between the score line and the zero line. Opacity is user-controlled. An optional bold score line (up to 4 px wide) overlays the fill for sharp numeric reading.
**Last-Bar Trend Label** — A right-anchored label at the current bar in the oscillator pane. Format: `▲ TRIPLE BULL 11 / 11` (bull) or `▼ WEAK BEAR −3 / 11` (bear). The label is deleted and redrawn on every bar, so only one instance is ever present on the chart.
🟦 OSCILLATOR STYLES
The oscillator subplot ships with two visual presets, selectable from the Oscillator Style dropdown:
| Style | Plot Style | Fill | Best For |
|---|---|---|---|
| Classic Gradient | `plot.style_line` (smooth curve) | Continuous vertical gradient from score to zero | Trend flow, slope momentum |
| Stepline | `plot.style_stepline` (staircase) | Stepped gradient mirroring the discrete score plateaus | Signal / threshold trading, discrete level crossings |
**Classic Gradient** produces a smooth curve traced through the smoothed score values, with the gradient fill flowing continuously between the score line and the zero line. This is the default and suits traders who read trend direction through slope and curvature.
**Stepline** renders each bar as a horizontal plateau joined to the next bar by a vertical edge. Because the raw score is always an odd integer in { −11, −9, …, 9, 11 }, the staircase visualization honors the score's true discrete nature — making it easier to identify exact threshold crossings (e.g. the moment the score enters the ±9 extreme zone). The fill inherits the same stepline style, so the entire oscillator pane stays geometrically consistent.
Both styles share the same opacity controls, score line toggle, and line width setting — only the geometry of the score line and its fill changes between them.
🟦 THEME SYSTEM
Ten cohesive color palettes tuned to the Quant Edge Ribbon PRO optical brand. One selection drives every visual component — outer ribbon gradient, inner ribbon accent, oscillator fill, reference lines, signal label, dashboard accents — all sharing the same bull / bear / accent color axes:
| Theme | Bull | Bear |
|---|---|---|
| Prism | Forest green | Crimson red |
| Focus | Cyan steel | Deep orange |
| Solar | Warm amber | Indigo red |
| Frost | Sky blue | Soft lavender |
| Laser | Neon lime | Hot crimson |
| Aurora | Bright gold | Scarlet |
| Plasma | Electric aqua | Magenta |
| Bloom | Mint green | Hot pink |
| Eclipse | Deep navy | Dark crimson |
| Carbon | Near-black | Silver grey |
The oscillator's zero line uses Pine's `chart.fg_color` so it auto-adapts to the actual chart background (white on dark charts, black on light charts) — independent of the Dashboard's Display Mode setting.
🟦 REFERENCE LEVELS
Four user-configurable horizontal reference lines mark the score's structural thresholds inside the oscillator subplot:
| Level | Style | Meaning |
|---|---|---|
| +11 / −11 | Dotted | Ceiling / floor — the mathematical maximum (every comparison aligned) |
| +9 / −9 | Dashed | Extreme zone — nine or more of the eleven comparisons agree on direction |
Each pair (±11 and ±9) has an independent opacity input (0–100 %). A master toggle (Show Reference Levels) collapses all four lines to fully transparent in a single branch — useful for minimalist layouts. An additional `showOsc` gate hides them automatically when the oscillator itself is disabled.
🟦 PRO DASHBOARD
A 2-column, 12-row theme-aware status panel that updates only on the last bar (zero historical overhead). Supports Dark and Light display modes, six docking positions, and four text sizes. Renders via `force_overlay = true` on the main price chart.
| Row | Label | Content |
|---|---|---|
| Header | Q-EDGE PRO | DARK / LIGHT |
| Theme | Theme | Active palette name |
| Kernel | Kernel | Selected kernel type |
| Divider | RIBBON | — |
| Primary ℓ | Primary ℓ | Primary bandwidth value |
| Span | Span | ℓ → ℓ + 11·s |
| Filter | Filter | No Filter / Smooth / Zero Lag |
| Divider | SCORE | — |
| Score | Score | ▲/▼ + integer score + " / 11" (bull/bear colored) |
| Bull / Bear | Bull / Bear | Bull comparison count / bear comparison count |
| Strength | Strength | ▰-bar + NEUTRAL / WEAK / STRONG / TRIPLE label |
| Primary | Primary | Primary kernel value in chart mintick format |
**Bull / Bear breakdown** — The eleven pairwise comparisons split into bulls (resolved +1) and bears (resolved −1). Always sums to 11, so this row gives a direct visual of how many kernel scales agree with the net direction.
🟦 ALERT CONDITIONS
Six opt-in alert conditions, each gated by its own toggle:
| Alert | Fires When |
|---|---|
| Bullish Flip | Score crosses from ≤ 0 into positive territory |
| Bearish Flip | Score crosses from ≥ 0 into negative territory |
| Extreme Bullish | Score reaches +9 or higher (first entry into the zone) |
| Extreme Bearish | Score reaches −9 or lower (first entry into the zone) |
| Full Confluence Up | Score hits +11 — every outer kernel aligned bullishly |
| Full Confluence Down | Score hits −11 — every outer kernel aligned bearishly |
All alerts use `alertcondition()` for maximum compatibility with PulseWire's alert system including webhooks. Messages are structured as `"Quant Edge Ribbon PRO: "` for easy parsing in downstream automation.
🟦 RECOMMENDED PRESETS
| Style | Primary ℓ | Bandwidth Step s | Phase | Filter | Chart |
|---|---|---|---|---|---|
| Scalper | 8–16 | 1 | 1 | No Filter | 1m–5m |
| Day Trader | 16–32 | 1–2 | 2 | Smooth | 15m–1h |
| Swing | 25–50 | 1–2 | 2 | Smooth | 4h–1D |
| Position | 50–120 | 2–3 | 3 | Smooth | 1D–1W |
**Bandwidth Step tuning** — Step = 1 produces a tight ribbon where adjacent outer kernels sit visually close together. Steps of 2–4 spread the eleven outer kernels across a broader spectrum of scales, making expansion / contraction easier to read at a glance. Step 5–6 is reserved for very wide ribbons where each line represents a distinctly different time scale.
🟦 COMPATIBILITY
- Pine Script v6
- All exchanges, all asset classes (crypto, forex, equities, commodities, indices)
- All timeframes (1 minute through Monthly)
- Both Dark and Light chart themes — visual elements auto-adapt via `chart.fg_color`
- No exchange-specific logic — fully deterministic
🟦 TECHNICAL NOTES
- **Library dependency** — `import a_jabbaroff/KernelLens/1` — all kernel regression math is delegated to the published library
- **Plot budget** — 11 outer + 11 inner + 1 primary + 2 oscillator plots + 1 fill + 4 hlines = well under Pine's 64-plot limit
- **Table** — Single `var table` created once on `barstate.islast` with `force_overlay = true`; dashboard renders on the main chart pane, zero historical overhead
- **No persistent drawing objects** — no `box.new`, `line.new`, no `array.new`; the single trend label is deleted and recreated every bar so only one instance is ever present
- **Opacity convention** — every user-facing opacity input follows `0 = invisible, 100 = fully opaque`; conversion to Pine's native transparency is centralized in a single helper function (`f_opac`)
- **Non-repainting** — inherits from the library's `_phase` parameter; no `request.security`, no lookahead, no future-bar leakage at any phase value
- **Chart background adaptive** — the oscillator's zero line uses `chart.fg_color`, so it always renders with high contrast regardless of the user's chart color scheme
🟦 DISCLAIMER
Quant Edge Ribbon PRO is a technical analysis indicator built on the KernelLens Nadaraya–Watson regression library. It is provided solely for educational and research purposes and does not constitute financial, investment, or trading advice.
Kernel regression is a local smoothing technique. It estimates the mean of a source series in the neighborhood of the current bar based on historical data, but it does not predict future prices, does not generate trading signals on its own, and does not guarantee the profitability of any strategy built on top of its output. The integer trend score is a geometric summary of kernel alignments — not a forecast — and should always be combined with broader context: higher-timeframe structure, volatility regime, liquidity, news, and risk management.
Past performance of any model does not guarantee future results. Markets contain systemic risks that cannot be eliminated by any amount of mathematical rigor. Responsibility for any trading decisions rests entirely with the user. Always apply sound capital management, conduct your own independent analysis, and never risk capital you are not prepared to lose.
The author assumes no liability for direct or indirect losses incurred through the use of Quant Edge Ribbon PRO or the underlying KernelLens library. Indicator

Indicator

Composite Panic IndexENGLISH VERSION
Composite Panic Index (Gold + VIX + DXY)
Overview
The Composite Panic Index is a multi-asset indicator designed to identify periods of market-wide fear and uncertainty by combining three key macro components:
VIX (CBOE Volatility Index): measures market fear via implied volatility
DXY (US Dollar Index): reflects USD strength as a safe haven
Gold (XAUUSD): traditional store of value during uncertainty
Instead of relying on news or subjective interpretation, this indicator measures how the market behaves under stress, providing an objective view of panic conditions.
Core Logic
Momentum Extraction
For each asset (Gold, VIX, DXY), the indicator calculates a short-term rate of change (ROC) to detect acceleration and shifts in market sentiment.
Normalization (Z-score)
Each component is normalized using a Z-score to:
Align different assets into a comparable scale
Remove bias from price magnitude differences
Highlight statistically abnormal movements
Composite Score
All components are combined into a single value using a weighted average and smoothed with an EMA. This produces the Composite Panic Score.
Indicator Components
Composite Panic Score (white line): represents the overall panic level
Panic Level (orange line): threshold for elevated uncertainty
Extreme Panic Level (red line): threshold for strong panic conditions
Background color:
Orange = panic regime
Red = extreme panic regime
Signals:
PANIC = new panic phase
EXT = new extreme panic phase
Table:
Displays Gold, VIX, and DXY direction, current score, and regime
Filters and Confirmation
Optional filters ensure that panic is only detected when:
Gold is rising
VIX is rising
DXY is rising
Signals are confirmed over multiple bars to reduce noise and false positives.
How to Use
Low values: normal conditions
Medium values: increasing uncertainty
High values: panic environment
The most relevant moments are when panic or extreme panic begins, often associated with volatility expansion and strong market movements.
This indicator should be used as a context tool, not as a standalone entry signal.
Limitations
Not all panic is synchronized across assets
Gold and DXY may diverge depending on macro conditions
The indicator does not read news directly, only market reactions
Summary
The Composite Panic Index transforms macro behavior into a single readable metric, helping identify when markets are driven by fear.
VERSIÓN EN ESPAÑOL
Composite Panic Index (Oro + VIX + DXY)
Descripción
El Composite Panic Index es un indicador multi-activo diseñado para identificar momentos de miedo e incertidumbre en el mercado combinando tres referencias clave:
VIX: mide el miedo mediante volatilidad implícita
DXY: refleja la fortaleza del dólar como activo refugio
Oro (XAUUSD): activo refugio tradicional
En lugar de basarse en noticias, el indicador mide directamente cómo reacciona el mercado ante situaciones de estrés.
Lógica interna
Cálculo de momentum
Se utiliza el ROC (rate of change) para detectar aceleraciones y cambios de sentimiento.
Normalización (Z-score)
Se aplica Z-score para:
Igualar escalas entre activos
Eliminar sesgos por magnitud de precio
Detectar movimientos anómalos
Score compuesto
Se combinan los tres activos mediante una media ponderada y se suaviza con una EMA, generando el nivel de pánico.
Componentes del indicador
Línea principal (blanca): nivel de pánico
Nivel de pánico (naranja)
Nivel de pánico extremo (rojo)
Fondo:
Naranja = pánico
Rojo = pánico extremo
Señales:
PANIC = inicio de pánico
EXT = inicio de pánico extremo
Tabla:
Muestra dirección de oro, VIX y DXY, valor del índice y estado actual
Filtros
Opcionales:
Oro subiendo
VIX subiendo
DXY subiendo
Permiten confirmar que el pánico es coherente entre activos.
Cómo usarlo
Valores bajos: mercado normal
Valores medios: aumento de incertidumbre
Valores altos: entorno de pánico
Los momentos más importantes son cuando comienza el pánico o el pánico extremo.
No es un sistema de entrada, sino una herramienta de contexto y confirmación.
Limitaciones
No siempre hay alineación entre activos
Oro y dólar pueden comportarse de forma distinta
No detecta noticias, solo sus efectos
Resumen
El Composite Panic Index convierte señales macro complejas en un único valor que permite identificar cuándo el mercado está dominado por el miedo. Indicator

Iterative Locally Periodic EnvelopeThe Iterative Locally Periodic Envelope is a phase-conditioned kernel estimator with temporal locality and endogenous dispersion modeling, implemented as a Nadaraya–Watson estimator under a locally periodic kernel.
The locally periodic kernel defines similarity through cyclical phase alignment modulated by temporal proximity. Observations contribute to the estimator based on both their position within a repeating cycle structure and their recency, emphasizing structural recurrence with sensitivity to local regime conditions.
The indicator computes a latent equilibrium using a kernel-weighted mean and a dispersion measure using kernel-weighted variance under the same weighting structure. The resulting envelope reflects cycle-consistent deviation with temporal locality, rather than a conventional volatility band. All values are computed exclusively on closed historical bars using a bounded lookback window to ensure non-repainting behavior.
This indicator belongs to a broader class of iterative kernel-based envelopes that includes Gaussian, Rational Quadratic, and Periodic variants. All share a common Nadaraya–Watson estimation framework, differentiated by their kernel.
TRADING USES
The Iterative Locally Periodic Envelope is best interpreted as a cycle-aware structural estimator with adaptive temporal sensitivity, rather than a volatility-based band. The temporal locality component allows the estimator to adapt more readily to emerging regime shifts than the pure periodic variant.
Equilibrium Tracking
The latent equilibrium represents the phase-conditioned central tendency of price under locally periodic similarity weighting. Oscillations around this level reflect movement within a repeating structural cycle, with more recent phase-aligned observations contributing more strongly than temporally distant ones.
Cycle Regime Structure
The envelope emphasizes repeating structural behavior through phase recurrence weighting, modulated by temporal decay. Changes in symmetry, amplitude, or persistence of oscillation around the latent equilibrium may indicate transitions between cyclical regimes.
Mean Reversion Within Cycles
When a stable periodic structure is present, deviations from the latent equilibrium may revert toward phase-consistent levels. Mean-reversion behavior is conditioned on both cycle structure and temporal proximity.
Structural Extremes
Extreme deviations relative to the envelope correspond to phase-inconsistent states where cyclical structure becomes stretched or destabilized. Because the kernel incorporates temporal decay, these conditions are identified with greater sensitivity to recent price behavior.
State Estimation
The system defines a latent equilibrium as the inferred central cyclical state under joint phase and temporal weighting, with dispersion derived from kernel-weighted variance under identical constraints. This produces a structurally consistent representation of the market state that is sensitive to both cyclical position and local regime conditions.
LOCALLY PERIODIC ENVELOPE CONSTRUCTION
The envelope is constructed using kernel-weighted variance under the same locally periodic similarity measure used to estimate the latent equilibrium. The latent equilibrium defines the central state estimate and kernel-weighted variance defines dispersion under identical weighting, producing an endogenously determined envelope. The band width is fixed at ±1 kernel standard deviation with no multiplier, ensuring dispersion remains an intrinsic property of the locally periodic similarity structure rather than an externally imposed scaling parameter.
THEORY
The locally periodic kernel defines similarity in terms of cyclical phase recurrence modulated by temporal proximity. Observations contribute to the estimator based on alignment within a repeating cycle structure, with influence attenuated by temporal distance from the estimation point.
The estimator is formulated as a Nadaraya–Watson kernel regression under a locally periodic kernel, where weights are defined as:
k(i) = exp( -2 · sin²(πi / p) / L² ) · exp( -i² / 2L² )
Where:
p = period (cycle length)
L = lookback window (shared bandwidth parameter; effective smoothing scales with L²)
In this MacKay consistent formulation, the lookback window acts as a unified bandwidth parameter governing periodic phase selectivity and the Radial Basis Function (RBF) temporal decay envelope. The two components are coupled through L, producing a kernel that simultaneously emphasizes phase-aligned and temporally proximate observations.
As L increases, both the periodic and RBF components broaden, producing stronger smoothing across phase and time. As L decreases, phase selectivity and temporal locality both increase, making the estimator more sensitive to recent cycle-consistent observations.
This induces a similarity structure in which influence concentrates at phase-aligned intervals within a temporally bounded neighborhood. The resulting estimator defines a latent equilibrium governed by phase alignment and temporal proximity that can be interpreted as a locally stationary periodic extension of kernel regression on a circular phase manifold.
The key distinction from the pure periodic kernel is that phase-aligned observations at distant lags are progressively suppressed by the RBF decay term, allowing the estimator to adapt to structural drift while preserving cycle-aware weighting. During stable cyclical regimes the two estimators converge; during structural transitions the locally periodic variant adapts faster by downweighting older phase information.
CALIBRATION
As established in Gaussian Processes for Machine Learning (Rasmussen & Williams, 2006), the period should reflect the recurrence interval of the dominant cycle in the data, while the bandwidth parameter L controls how quickly similarity decays away from perfect phase alignment. For daily charts, common cycle anchors include the trading week (~5 bars), trading month (~21 bars), trading quarter (~63 bars), and trading year (~252 bars).
Length (Lookback / Bandwidth)
Controls structural depth of the estimator and acts as the unified bandwidth parameter for the periodic and RBF components; as L governs phase selectivity and temporal decay simultaneously, its effect is stronger than in the pure periodic variant. The default of 100 reflects the locally periodic kernel's temporal decay component; at longer lengths the RBF term weakens and behavior converges toward the pure periodic estimator.
- 50–100: high responsiveness, strong temporal locality, short-cycle sensitivity
- 150–250: balanced regime stability with moderate temporal decay
- 300+: broad structural smoothing, weak temporal decay, behavior converges toward pure periodic envelopes
Period (Cycle Length)
Defines the recurrence interval of the kernel and governs phase alignment and cyclical structure. Shorter periods increase phase resolution and cycle sensitivity, while longer periods emphasize broader structural recurrence. The period should reflect the dominant cycle present in the data, aligned with the anchor scales defined above.
Start At Bar
Offsets the kernel window backward from the most recent bars and excludes newer observations from the estimator. This ensures all calculations are based strictly on closed historical data and preserves non-repainting behavior.
MARKET USAGE
Stock, Forex, Crypto, Commodities, and Indices.
Performance is dependent on the presence of stable cyclical structure; in regimes lacking periodic coherence, the estimator converges toward a local smoother with reduced phase discrimination. Indicator

Indicator

Indicator
