Tyson Uppercut Compression Spring Breakout (Viprasol)Tyson Uppercut — Compression Spring Breakout 🥊
(The name is an affectionate combat-sports homage — this is an educational pattern tool, not affiliated with or endorsed by any athlete or organization.)
CONCEPT
A spring loaded by VOLATILITY, not by swings. The tool measures the recent bar-range and requires it to be compressed — noticeably tighter than the window before it (energy coiling). Then the uppercut: one wide-range bar that bursts up out of the compression on the close = the release. Distinct from swing-decay coils; this reads raw range contraction directly from the bars.
HOW IT DETECTS
- Compression is measured on CLOSED bars only: the highest high and lowest low over a window (default 10 bars, offset by one bar).
- That compression range must be tight versus the prior, wider window (default: <= 60% of the range over twice the lookback) AND not larger than a set ATR cap.
- Release: the current bar closes above the compression high, its full bar range is at least a set ATR multiple (default 1.3x ATR), and it closes up (close > open).
- All logic runs on bar close (barstate.isconfirmed). An optional dotted live box previews an active compression before any break.
ENTRY / STOP / TARGET
- Entry: on the confirmed release close (long only).
- Stop: below the compression low, minus an ATR buffer.
- Target: entry + R multiple of risk (default 2R, adjustable).
- Drawn as a solid compression box plus an entry line and filled TP/SL zones that extend right until price touches one; the hit side thickens.
NON-REPAINTING
Compression is read from already-closed bars (a one-bar offset is used), and the release is confirmed on the bar close. A printed signal does not move or disappear afterward. The live dotted preview is informational only and is not a signal.
KEY FEATURES
- Volatility-compression detection from raw range, with an ATR height cap to avoid oversized "boxes".
- Release requires a genuinely wide breakout bar, not just a marginal close.
- Optional live compression preview; option to hide new setups while a trade is active.
- Filled, extend-until-hit TP/SL zones and an on-chart status table (open trades). Alert condition included.
INPUTS OVERVIEW
- The spring: compression window (bars), tightness fraction vs prior window, max compression height (x ATR), release bar range (x ATR), ATR length.
- The knockout: TP as R multiple, SL buffer (x ATR), minimum bars between signals, one-trade-at-a-time, hide-setup-while-in-trade.
- Visuals: compression box / entry / TP / SL colors, label offset, zone transparency, show-live toggle.
HOW TO USE
1. Add to a liquid symbol and timeframe; it is fully overlay-based.
2. Set the compression window and tightness fraction to define how coiled the range must be.
3. Raise the release ATR multiple to demand a stronger breakout bar.
4. Watch the live dotted box to anticipate setups, and study the TP/SL zones on your instrument.
5. Optionally create an alert from the built-in condition.
LIMITATIONS (read this)
- This is a pattern/education tool, not a signal service and not financial advice. It does not predict the future.
- Compression breakouts frequently fail or reverse (false breakouts are common), especially in ranging markets.
- It is long-only by design; it does not trade downside releases.
- Range readings depend on the chosen windows; different settings can materially change what counts as "compressed".
- Results depend heavily on your inputs, instrument, and timeframe. Always use your own risk management and discretion.
CREDITS
ATR uses Wilder's Average True Range. Highest/lowest range measurement uses standard public functions (ta.highest / ta.lowest). The raw-range compression-and-release detection and the trade-zone visualization are original Viprasol design.
Original Viprasol work; no third-party Pine code reused.
Indicator

Compression Breakout & Follow-Through Scoring [SlatinaTrades]🌀 Compression Breakout & Follow-Through Scoring — grades the coil, then checks its own homework.
Most squeeze/compression tools flag a tight range and stop there. This one also tracks what happens after the break — and separates completed setups by quartile to show whether the coil's tightness or the breakout candle's quality actually predicted the outcome, instead of assuming either one does.
THE MECHANICS
🧊 Compression detection — three conditions have to hold together: box range ≤ a multiple of base-ATR (C1), Bollinger Band width inside a squeeze percentile (C2), and a minimum dwell in confirmed bars (C3). All three gate the coil; none of them alone is enough.
🔒 State machine — COILING → PRIMED → BREAKOUT (up/down) → HELD or FAILED, with EXPIRED for coils that age out unbroken. The box freezes on arm (tighten-only re-lock while PRIMED — it can tighten further, never widen), so what you see is a committed level, not a moving target.
📊 Tightness score (0–100) — weighted blend of C1 margin, C2 depth, and dwell length. Grades how genuine the compression is, not just whether it cleared a threshold.
🎯 Break-quality score (0–100) — weighted blend of close location, body ratio, range expansion vs ATR14, and where volatility sits inside a regime band (mid-band scores highest; dead or chaotic extremes score low).
📈 Follow-through score (0–100) — tracks maximum favorable excursion beyond the broken edge over a fixed window, capped at a set ATR multiple. A break that reclaims the level before the window closes is scored FAILED instead.
SEPARATION HARNESS — the honesty check
A stats table bins every completed setup (HELD or FAILED) into quartiles two ways: by tightness score and by break-quality score. Each quartile reports mean follow-through in ATR units and reclaim rate. If a score's Q4 looks like its Q1, that score isn't doing the work it claims to — the table shows you that plainly instead of asking you to trust a single headline number.
NON-REPAINT
Every state transition and every follow-through update runs on barstate.isconfirmed. The box freezes the moment a coil arms. The optional HTF alignment read uses a closed-bar offset (lookahead_on + gaps_off on ) and is a flag only — it never gates the state machine.
WHAT IT IS NOT
Not a strategy. No entries, no stops, no targets, no risk sizing anywhere in this script. Bidirectional context only — it tells you a coil compressed and how the break resolved, not what to do about it. Settings are starting points, not recommendations; tune box length, dwell, and weights to what you're trading and validate before risking anything on it.
ALERTS
New Coil Primed · Bull Breakout · Bear Breakout · Follow-Through Confirmed · Reclaim. All gated to confirmed bars, all carry numeric state/score payloads for automation.
Still useful after it's been on your chart a while — every read maps to a concrete decision about whether this coil is worth watching. Indicator

Squeeze Breakout Signals [TBalgo]Squeeze Breakout Signals spots when volatility compresses, then flags breakout long and short signals when price escapes the band after a tight zone.
Overview
This overlay indicator maps volatility compression and breakout direction on your chart. It builds dynamic SMA bands, detects when band width ranks in the lowest part of recent history (squeeze / tight zone), and fires signals only when price breaks the upper or lower band after compression.
Built for traders who want a clean squeeze → breakout workflow without clutter.
How it works
1. Bands — SMA midline + standard-deviation upper/lower bands
2. Tight zone — band width percentile rank vs lookback; when rank is low, market is in a squeeze
3. Signals — long when price crosses above the upper band after a tight bar; short when price crosses below the lower band after a tight bar
4. Guide lines — optional entry, risk (opposite band), and reward level based on band width
Features
- Green/red squeeze bands with tight-zone background wash
- Diamond markers on breakout signals
- Optional entry labels (`TB Long` / `TB Short`)
- HUD chip showing **TIGHT** or **LIVE** state
- Full display toggles — turn bands, signals, tags, guides, or HUD on/off
- Custom colors for bull, bear, and neutral states
- Built-in alerts for long, short, squeeze start, and expansion
Settings
Display — Bands · Tight Zone · Signals · Tags · Guide Lines · HUD
Engine
- **Length** — SMA / band period (default 50)
- **Std Mult** — band width multiplier (default 2.0)
- **Rank Lookback** — history for squeeze detection (default 100)
- **Tight Rank ≤** — max percentile to count as tight (default 20)
- **Reward × Width** — target distance as multiple of band width (default 1.5)
| Alert | When it fires |
|---|---|
| TB Squeeze Long | Bullish breakout after tight zone |
| TB Squeeze Short | Bearish breakout after tight zone |
| TB Squeeze Tight | Compression / squeeze begins |
| TB Squeeze Expand | Compression ends |
---
Suggested use
- **Higher timeframes (1H–1D):** default settings often work well for swing context
- **Lower timeframes (1–15m):** try shorter Length (20–35) and lower Tight Rank (10–15)
- Wait for **TIGHT** on the HUD, then trade only confirmed diamond signals
- Use guide lines as reference — not automatic trade execution
Pairs well with volume, structure, or liquidity tools on the same chart.
---
License
Original TBalgo indicator.
Licensed under Mozilla Public License 2.0 — free to use and modify with attribution.
Disclaimer
For education and research only. Not financial advice. Past signals do not guarantee future results. Always manage risk and do your own analysis before trading.
Indicator

AlgoForex PULSE Momentum & Volatility CompassAlgoForex PULSE is a single-pane trend, momentum and volatility read-out. It replaces the usual stack of three separate indicators — a moving average, an oscillator and a volatility gauge — with one adaptive framework drawn directly on price.
WHY IT EXISTS
A fixed-period moving average has one setting and two problems: it lags in a trend and whipsaws in a range. Most traders answer this by adding an oscillator in a lower pane and a volatility filter somewhere else, then spend the session moving their eyes between three places. PULSE folds those three jobs into one object on the chart.
HOW THE BASELINE WORKS
The baseline is an adaptive average driven by an efficiency ratio. For the chosen lookback it measures:
• net directional travel = |price now − price N bars ago|
• total travel = the sum of every bar-to-bar move over the same N bars
The ratio of the two is the efficiency ratio. Near 1, almost all movement went one way, so the average is allowed to accelerate toward price. Near 0, price covered a lot of distance and ended up nowhere, so the average slows down and flattens. The smoothing constant is squared, which makes the transition between the two states sharper than a linear blend.
The practical effect: the line tracks trends closely, then stops reacting to noise when the market goes sideways.
AURORA BANDS
Three ATR-scaled layers are drawn on each side of the baseline and filled with the live trend colour. They serve two purposes at once:
• the WIDTH shows current volatility — the cloud breathes as ATR expands and contracts
• the POSITION of price inside the cloud shows how stretched the move is
A close hugging the outer band is an extended move. A close oscillating around the baseline is a market with no commitment.
TREND STATE (with hysteresis)
The trend does not flip the moment price touches the baseline. It requires a close beyond baseline ± (Trend Trigger × ATR), default 0.5× ATR. This buffer is the difference between a handful of meaningful flips per session and dozens of meaningless ones. Raise it for fewer, slower signals; lower it for a more reactive read.
Flips are marked with and labels.
MOMENTUM SCORE (0-100)
Rather than a second pane, momentum is reduced to one number:
Momentum = 55 × normalised position inside the bands + 45 × RSI
The position component is clamped to ±1 so a single spike bar cannot dominate the reading. The result drives three things: the gauge in the dashboard, the candle colour gradient, and the surge markers (small dots) fired when the score crosses the bullish or bearish levels.
CONVICTION
The dashboard shows the raw efficiency ratio as a percentage. This is deliberately kept separate from the momentum score because the two answer different questions:
• Momentum = which direction, how strongly
• Conviction = how clean that movement was
A high momentum score with low conviction is a move fighting through chop. High on both is the condition worth acting on.
SQUEEZE RADAR
Current ATR is compared against its own percentile over a lookback window (default: bottom 25% of the last 100 bars). While ATR sits in that bottom band the background is tinted, marking compression. The bar where ATR climbs back out is marked with a the expansion point.
Compression tells you nothing about direction, only that the range is unusually tight. Pair it with the trend state for a directional bias.
HOW TO USE IT
1. Read the trend colour first — it sets your bias for the session.
2. Check Conviction. Below roughly 20% the market is not paying trend-followers.
3. Wait for price to pull back toward the baseline rather than chasing the outer band.
4. Treat a squeeze release in the direction of the trend as a timing cue, not a signal on its own.
5. Momentum surge dots confirm strength — they are not standalone entries.
SETTINGS THAT MATTER MOST
• Adaptive Length — the responsiveness of the whole system. Lower = faster.
• Trend Trigger ( ATR) — signal frequency. The single most useful dial here.
• Squeeze Percentile — how rare a "squeeze" should be. Lower = stricter.
ALERTS
Bullish trend flip Bearish trend flip Bullish momentum surge Bearish momentum surge Squeeze started Squeeze release.
NOTES
Works on any symbol and any timeframe. The dashboard is bilingual (English) and can be switched in the settings.
This indicator is an analysis tool. It does not predict price and it is not financial advice. No indicator has an edge on its own — use it inside a plan that includes risk management and position sizing. Past behaviour of any tool does not guarantee future results. Indicator

Trend Ribbon [MachineSuiteAI]Trend Ribbon
respect ranking, measured cross odds and auditable statistics
🟦 OVERVIEW
A five-average trend ribbon (8 / 21 / 50 / 100 / 200 by default; EMA, WMA, SMA, HMA or VWMA) built on one idea: the ribbon should measure itself.
Beyond the stack-based trend state and 50/100 cross markers, it keeps auditable statistics on the chart it is loaded on: which average price has actually been respecting (and how reliably), how every 50/100 cross resolved, what happened after squeeze expansions and after trend-health peaks — each statistic with its sample size, and each verifiable on the chart itself, dot by dot. It is built for traders who use layered moving averages and want the chart to answer two questions the ribbon genre normally leaves to folklore: which of these lines matters here, and what have these signals actually done on this symbol?
🟦 WHAT IS A TREND RIBBON?
Moving-average ribbons are a public-domain concept: several averages of increasing length plotted together. When they are stacked in order the trend is orderly; when they compress and interleave the market is ranging; crosses of a slower pair mark regime changes. Published ribbon scripts already color stacks, count touches, score trend strength and detect squeezes.
What the genre does not do is resolve outcomes. A ribbon will mark a "golden cross" without knowing how golden crosses have actually resolved on this chart; it will call an average "support" without a record of how often that support held. This script's contribution sits one level up: measurement with discipline, and evidence you can check.
🟦 WHY THIS SCRIPT IS ORIGINAL
- A cross odds engine. Every 50/100 cross is resolved N bars later (default 10) on the loaded symbol and timeframe: did the close move in the cross's direction? The win rate is tracked and split by volume confirmation, higher-timeframe agreement, and whipsaw-cluster membership — each split with its own sample size, greyed below a minimum. To the author's knowledge no published ribbon resolves its own crosses' outcomes, let alone per filter.
- Evidence-gated chart marks. The ✓ volume mark and ⚠ counter-HTF warning print on cross chips only where the measured split beats the chart's own base rate by a configurable margin with sufficient samples. Filters that have not helped on this chart do not decorate it.
- Auditable statistics. The respect record is drawn on the chart: numbered dots mark the counted touches of the leading average (gold = held, grey = failed) and a grey ✕ marks clean pass-throughs where nothing was tested and nothing entered the record. Every number in the panel can be verified visually — no other script found does this.
- Outcomes attached to the score and the squeeze. The 0–100 health score is not just decomposed from a stated formula — the panel reports how often the primary side was still intact at three horizons after past crossings above 80, on this chart. Squeeze expansions are likewise measured N bars later (median move, direction agreement, samples).
- Recency-weighted respect ranking. Touch counting exists in published scripts; here each average's last 12 touches form a rolling record where the newest touch weighs most, and the gold halo must be earned twice over: both the raw record and the weighted recent form have to clear a threshold. Below it the panel reads LOW RESPECT — price slicing through everything is itself information.
- Readability engineered like the statistics. Six engines share one chart only because the visual rules are strict: line identities never change (white 50, amber 100, thick grey 200 — the respect halo is an underlay beneath the leader's own line, never a recolor), whipsaw crosses are de-emphasized but never deleted so the visible ▲/▼ sequence always alternates, higher-timeframe levels identify themselves with end tags instead of a legend, and every mark on the chart has exactly one meaning. Nothing decorative, nothing unexplained.
🟦 HOW IT WORKS
- Trend state: the 50/100 pair picks the side; the state reads BULL or BEAR only when at least 3 of the 4 adjacent stack pairs agree, otherwise CHOP. Fill opacity scales with alignment.
- Respect engine: every touch of every average runs through a small state machine on confirmed bars. A touch requires the prior close beyond the average, a penetration into a tolerance band (default 0.25 × ATR(14)) and a close back on the original side; consecutive contacts merge into one event. The touch HOLDS if no close crosses the far tolerance edge within the resolve window (default 5 bars). Each average keeps its last 12 resolved touches; the best recency-weighted hold rate (minimum 5 touches) leads the ranking, and the leader earns a soft gold halo under its own line only when raw record and recent form both clear the threshold (default 50%).
- Cross odds engine: as described above — confirmed bars only, fixed-horizon resolution, per-filter splits, evidence-gated chip marks.
- Health score: 0–100 from a stated formula — 40% stack alignment + 25% slope consistency + 20% price position + 15% width behavior. The panel tooltip decomposes the live score and reports the measured survival after 80-crossings at half, full and double the outcome window.
- MTF strip and HTF anchors: a small table shows the 50/100 cross state on five timeframes, and up to three higher-timeframe averages plot as stepped level lines (default: the 50/100/200 one regime up, with an optional corridor fill between the pair, tinted by where price trades). Both are read from the last completed bar of their timeframe with confirmed-bar indexing, so they can appear one higher-timeframe bar late but never rewrite. Anchors render only once their timeframe has a full length of history — young symbols never show statistically meaningless levels.
- Squeeze and expansion: ribbon width (widest minus narrowest core average, as % of price) is percentile-ranked over a lookback (default 250 bars); below the threshold percentile the ribbon is squeezed. Every expansion out of a squeeze is measured N bars later: median move, direction agreement with the ribbon state, and an "A-grade" slice (state agreed with the higher timeframe AND volume confirmed) tracked separately.
- Cluster damping: several crosses inside a short window classify as whipsaw; rapid re-crosses shrink to dimmed dots rather than full chips — de-emphasized, never deleted, so the visible ▲/▼ sequence always alternates. A cross suppressed into a cluster can still print later, once, if the market settles on its side.
All statistics are collected on confirmed bars only.
🟦 HOW TO USE IT
- Line identities stay fixed: white 50, amber 100, thick grey 200, fast pair in the trend color. The pair that generates the signals is always findable.
- Read the panel top-down: state, health, stack, the respected average with its raw record and recent form, cross recency, the measured win-rate splits, then width and expansion.
- A typical workflow: before treating a pullback to an average as meaningful, check that average's record — the gold halo and its numbered dots are the evidence. Before taking a cross, check whether volume or higher-timeframe agreement has historically mattered on this particular chart — the ↑ marks in the odds rows answer that. Use the MTF strip for context and the HTF corridor as the higher-timeframe decision zone.
- Defaults suit swing timeframes (4H–1D); everything is length-adjustable.
🟦 SETTINGS
- Averages: type, five core lengths, up to three optional extras, curated price source.
- Respect engine: halo and audit-dot toggles, touch tolerance, hold window, ranking window, minimum touches, gold threshold, recency decay.
- Health score: panel row toggle, outcome window.
- Cross odds engine: outcome horizon, minimum sample, evidence-mark gating mode, improvement margin.
- MTF cross strip: five timeframes, strip position.
- HTF anchors: auto or fixed anchor timeframe, three levels with lengths and colors, corridor or lines-only rendering.
- Visuals and extras: marker style (chips/dots/off), cluster damping, line-coloring mode (stack state or per-line slope), price-scale labels, squeeze shading, conviction-scaled fill, panel position, colors, volume-confirmation multiple.
🟦 ALERTS
Primary 50/100 cross (bull/bear) · fast 8/21 cross (bull/bear) · full stack aligned (bull/bear) · cross + volume (bull/bear) · squeeze start · squeeze expansion + volume · respected-average touch · respected average changed · health crossed 80 · health dropped below 40.
🟦 REPAINT & DATA NOTES
- Chips, dots and all bookkeeping wait for bar confirmation; the live bar updates until it closes.
- Higher-timeframe reads use the last completed bar of their timeframe: repaint-safe, but up to one higher-timeframe bar late by construction.
- Statistics are computed over the loaded history and reset when the chart reloads with a different amount of history; low timeframes load fewer bars.
- Volume-based features — including the VWMA average type — require a feed that supplies volume.
- PulseWire caps a script's labels at 500, so on long intraday histories the oldest cross chips drop off the left edge; the statistics still cover the full loaded history.
- MTF strip rows set below the chart's own timeframe show a dash: a lower timeframe cannot be read repaint-safely from a higher-timeframe chart.
- The higher-timeframe anchor levels can sit far from current price (a weekly 200 on a daily chart, for example), which widens the chart's auto-fitted price scale. Enable "Scale price chart only" in your chart settings — or switch anchors off — if you prefer a tight fit around price.
🟦 CREDITS
Moving averages, ribbons, MA crosses and squeeze concepts are public domain. The implementation — the respect state machine, cross odds engine, evidence gating, health decomposition with measured outcomes, repaint-safe MTF/anchor reads and the audit-dot system — was written from scratch for this script.
🟦 LIMITATIONS
- Moving averages lag; ranging markets whipsaw the state and the crosses. The cluster logic labels that condition, it does not remove it.
- All win rates, hold rates and outcome stats are historical measurements on the loaded chart only. They change with symbol, timeframe and loaded history, are greyed below the minimum sample, and do not predict future results.
- The outcome definition is direction-only over a fixed horizon — no stops, fees, or sizing; this is not a strategy backtest.
🟦 DISCLAIMER
This is an educational analysis tool, not investment advice. Historical measurements, however carefully computed, do not predict future results. Trading involves substantial risk. Indicator

Volatility Squeeze Scanner MTF [StrixEDGE]Overview
A multi-timeframe volatility squeeze detector that identifies when Bollinger Bands contract inside Keltner Channels across four configurable timeframes simultaneously. The indicator combines squeeze state detection with a LazyBear-method momentum oscillator and a real-time consensus engine, giving traders a structured view of cross-timeframe compression without switching charts.
Volatility squeezes represent periods of contracting price action — energy building before a directional move. Detecting them on a single timeframe is common. Detecting them across multiple timeframes at once isolates the higher-probability setups where compression is structural, not noise.
How It Works
Squeeze Detection
A squeeze fires when the Bollinger Bands (SMA ± standard deviation) fully contract inside the Keltner Channel (SMA ± ATR). This means the upper Bollinger Band is below the upper Keltner Channel AND the lower Bollinger Band is above the lower Keltner Channel. When both conditions hold, volatility has compressed below its average range — the market is coiling.
Bull BIAS
Bear BIAS
Momentum Oscillator (LazyBear Method)
The momentum histogram is calculated as the linear regression of the difference between price and the average of the Donchian Channel midline and SMA. This produces a zero-centered oscillator that reveals both the direction and acceleration of momentum inside the squeeze.
The histogram uses a four-tone color scheme:
- Bright green — bullish momentum, accelerating
- Dark green — bullish momentum, decelerating
- Bright red — bearish momentum, accelerating
- Dark red — bearish momentum, decelerating
Squeeze-State Dots
Dots on the zero line change color based on the current chart timeframe's squeeze state:
- Orange dot — squeeze is active (BB inside KC)
- Teal dot — no squeeze (BB outside KC)
The transition from orange to teal marks the moment the squeeze fires — volatility is expanding and the move is underway.
Multi-Timeframe Consensus
The indicator runs the squeeze calculation independently on four user-defined timeframes via `request.security()`. A consensus table displays each timeframe's squeeze state, momentum direction, momentum acceleration, and squeeze duration in real time.
Consensus is reached when the number of timeframes simultaneously in squeeze meets or exceeds the user-defined threshold (default: 3 out of 4). The background subtly highlights when consensus is active, with a brighter flash on the bar where consensus is first reached.
How to Read It
Entry context:
Wait for the consensus row to show 3/4 or 4/4 CONSENSUS — this confirms compression is happening across the timeframe stack, not just locally. The higher the consensus count, the more significant the potential expansion.
Directional bias:
The MOM and DIR columns across timeframes reveal whether momentum is aligned. When most timeframes show BULL + ▲, the bias favors long. When most show BEAR + ▼, the bias favors short. Mixed readings suggest no clear directional edge — patience is warranted.
Timing the release:
Watch the zero-line dots on the current chart timeframe. When the dot transitions from orange (squeeze active) to teal (squeeze released), the coil is unwinding. The histogram's color and direction at that moment indicate the likely direction of the expansion.
Duration as context:
The DUR column shows how many bars each timeframe has been in squeeze. Longer durations generally correspond to larger eventual moves. A fresh squeeze (DUR = 1–3) may still be forming. An extended squeeze (DUR = 15+) is deeply compressed and more likely to produce a significant breakout.
Inputs
Bollinger Bands
- Length — lookback period for the SMA and standard deviation (default: 20)
- Multiplier — standard deviation multiplier for band width (default: 2.0)
Keltner Channel
- Length — lookback period for the SMA and ATR (default: 20)
- Multiplier — ATR multiplier for channel width (default: 1.5)
Timeframes
- Four independently configurable timeframes (default: 5m, 15m, 1H, 4H)
- Choose timeframes that create meaningful structure for your trading style
Consensus
- Minimum TF Consensus — how many timeframes must be in squeeze simultaneously to trigger consensus (2, 3, or 4; default: 3)
Momentum
- Momentum Source — price source for all calculations (Close, Open, High, Low, HL2, HLC3, OHLC4)
Alerts
5 alert conditions are available:
- Squeeze Consensus Reached — fires when the minimum TF consensus threshold is first met
- Squeeze Consensus Broken — fires when consensus drops below the threshold
- Consensus + Bullish Bias — consensus active with 3+ timeframes showing positive momentum
- Consensus + Bearish Bias — consensus active with 3+ timeframes showing negative momentum
- Full 4/4 Squeeze — all four timeframes in simultaneous squeeze
Indicator

EMA Ribbon Trend Filter [StrixEDGE]EMA Ribbon Trend Filter is a multi-layered trend analysis system built around a triple EMA ribbon (8/21/55) enhanced with squeeze detection, a composite momentum score, multi-timeframe confluence, and dynamic slope-adaptive coloring.
This is not another moving average overlay. It is a full trend diagnostics dashboard designed to answer five questions at a glance: what is the trend, how strong is it, how long has it been running, is the ribbon compressing toward a breakout, and do higher timeframes agree.
🔹 CORE CONCEPT
Three exponential moving averages — fast (8), mid (21), and slow (55) — form a visual ribbon on the chart. When the EMAs stack in order (fast > mid > slow), the trend is bullish. When they invert, the trend is bearish. Anything else is a transitional state labeled neutral.
The ribbon is more than directional. The distance between the fastest and slowest EMA (the "spread") measures trend strength as a percentage, and the rate at which the ribbon expands or contracts reveals momentum shifts before price confirms them.
🔹 WHAT MAKES THIS DIFFERENT
Most EMA ribbons stop at direction and color. This indicator adds four analytical layers that standard ribbons lack:
▸ Ribbon Squeeze Detection
The indicator continuously measures ribbon width against its own moving average. When the three EMAs converge below a configurable threshold (default: 30% of average width), the ribbon turns yellow and the dashboard flags an active squeeze. Compression precedes expansion — a squeeze ending often marks the start of a directional move. Dedicated markers appear on the chart when a squeeze releases into a bullish or bearish trend.
▸ Composite Momentum Score (0–100)
A single number synthesizing four components, each weighted equally at 25 points:
— EMA alignment: full bullish or bearish stack scores 25, mixed scores 0
— Slope agreement: all three EMAs rising or all falling scores 25, partial agreement scores 12
— Spread strength: scaled between 0–25 based on where the current spread falls relative to the user-defined weak and strong thresholds
— Price position: price above the ribbon in a bullish trend (or below in bearish) scores 25, inside the ribbon scores 10, on the wrong side scores 0
The score is color-coded: cyan (80+), teal (60–79), orange (40–59), red (below 40).
▸ Dynamic Slope-Adaptive Colors
When enabled, each EMA line independently changes color based on its own slope — rising EMAs render green, falling EMAs render red. This provides an early visual warning when individual EMAs begin to flatten or turn, even while the overall stack remains intact. A bullish stack where the slow EMA has turned red is a qualitatively different signal than one where all three are green.
▸ Multi-Timeframe Dashboard
A built-in table displays trend state, spread, and grade across five timeframes simultaneously: the current chart timeframe plus 15-minute, 1-hour, 4-hour, and daily. The active chart timeframe is marked with ► in the MTF rows if it matches one of the fixed timeframes. A confluence row at the bottom counts how many timeframes are bullish versus bearish and outputs a directional bias: Strong Bull (4–5 aligned), Bull Lean (3), Neutral (mixed), Bear Lean (3 bearish), or Strong Bear (4–5 bearish).
🔹 CROSSOVER SIGNAL HIERARCHY
Not all EMA crossovers carry equal weight. The indicator differentiates three tiers with distinct marker sizes and shapes:
▸ Fast × Mid (tiny triangles) — Early signal. The 8 EMA crossing the 21 EMA indicates short-term momentum shift. Frequent, noisy, best used as an alert rather than a trigger.
▸ Fast × Slow (standard triangles) — Confirmation signal. The 8 EMA crossing the 55 EMA has more significance and filters out minor pullbacks.
▸ Mid × Slow (diamonds) — Trend shift signal. The 21 EMA crossing the 55 EMA typically marks a genuine change in trend direction. This is the least frequent and most reliable crossover in the set.
All crossover markers can be toggled off independently.
🔹 DASHBOARD COMPONENTS
The top-right dashboard (position and size adjustable) contains:
Row 1 — TREND: Current trend state (▲ Bullish / ▼ Bearish / ◆ Neutral) with bar count showing how long the trend has been active.
Row 2 — ZONE: Where price sits relative to the ribbon (Above / Inside / Below) alongside the momentum score out of 100.
Row 3 — SQUEEZE: Active squeeze status with a visual strength bar (██████░░░░) showing current spread intensity relative to its recent range.
Rows 4–9 — MTF OVERVIEW: Trend, spread, and grade for the current chart, 15m, 1H, 4H, and 1D timeframes.
Row 10 — BIAS: Multi-timeframe confluence verdict with bull/bear count.
🔹 SETTINGS
EMA Settings
▸ Fast / Mid / Slow EMA Period — Default 8/21/55. Periods must be in ascending order.
▸ Source — Close, Open, High, Low, HL2, HLC3, or OHLC4.
Overlay Settings
▸ Background Transparency — Controls the intensity of the trend-colored chart background (0–99).
▸ Crossover Signals — Toggle the three-tier crossover markers.
▸ Ribbon Fill — Toggle the colored fill between EMA lines. Fill turns yellow during active squeeze.
▸ Dynamic EMA Colors — Toggle slope-based EMA coloring (green = rising, red = falling).
▸ Bar Coloring — Optional candle coloring by trend state and price position. Off by default.
▸ Squeeze Detection — Toggle squeeze markers and dashboard squeeze status.
Dashboard
▸ Table Size — Tiny, Small, Normal, or Large.
▸ Table Position — 8 positions (corners, centers, sides).
Thresholds
▸ Weak/Strong spread thresholds (%) — Define what constitutes a weak, moderate, or strong trend spread. These should be adjusted per asset class (e.g., lower for forex, higher for crypto).
▸ Squeeze Lookback — Number of bars used to calculate the average ribbon width for squeeze detection.
▸ Squeeze Ratio — The compression threshold. A ribbon narrower than this ratio × average width triggers a squeeze flag.
🔹 ALERTS
Nine configurable alert conditions:
▸ Bullish / Bearish EMA Crossover (any tier)
▸ Mid × Slow Bullish / Bearish Shift
▸ Bullish / Bearish Stack Formed
▸ Squeeze Detected (compression begins)
▸ Squeeze Released (expansion starts)
▸ High Momentum (score crosses above 80)
🔹 SUGGESTED USE
This indicator works as a trend filter, not a standalone entry signal. Use it to:
▸ Confirm directional bias across timeframes before entering trades
▸ Identify compression phases where breakouts are likely
▸ Gauge trend quality and exhaustion via the momentum score and bar duration
▸ Filter crossover signals — a Fast × Mid cross during an active squeeze with MTF confluence is a higher-probability setup than the same cross in isolation
Pairs well with oscillators (RSI, Stochastic), volume-based indicators, or support/resistance tools for entry timing. Indicator

Multi-Timeframe Squeeze Board LiteWhat it shows
Multi-Timeframe Squeeze Board — Lite answers one question at a glance: "Where is this symbol compressed, and which way is momentum leaning, on every timeframe that matters?" For the chart's symbol it displays a compact table with one row per timeframe — 15m, 1h, 4h, Daily, Weekly — and two readings per row:
- Sqz — the TTM Squeeze compression state as a colored dot, using the standard three-level cascade: orange = high squeeze (deepest compression), red = mid squeeze, black = low squeeze, green = no squeeze (volatility released / normal).
- Mom — the squeeze momentum oscillator as a colored arrow using the classic 4-color scheme: aqua = positive and rising, blue = positive but falling, yellow = negative but rising, red = negative and falling. The arrow points up when momentum is increasing bar-over-bar and down when it is decreasing.
A stacked squeeze (orange/red dots on several adjacent timeframes) marks a market coiling across horizons; the momentum colors tell you which side the pressure is building on.
How it works
Each row runs the full TTM Squeeze calculation on its own timeframe via request.security() with lookahead = barmerge.lookahead_off (no future data, ever):
1. Bollinger Bands: SMA(close, 20) basis, 2.0 × population standard deviation.
2. Keltner Channels: the same SMA(close, 20) basis, with band width = SMA of True Range over 20 bars (simple average of TR — not Wilder's ATR) at three multipliers: 1.0, 1.5, 2.0.
3. A squeeze is on when the Bollinger Bands sit fully inside the Keltner Channel on both sides. The narrower the Keltner band that still contains the BB, the deeper the compression — hence the 1.0-multiplier band defines the high squeeze, 1.5 the mid, 2.0 the low.
4. Momentum is the linear regression of price's deviation from the average of the Donchian midline and the SMA, over the same 20 bars.
By default the board evaluates confirmed bars only: every row shows the last fully closed bar of its timeframe, so a dot or arrow never changes after it appears. See Limitations for the tradeoff.
Inputs
- Squeeze length — lookback for BB, KC and momentum (default 20, the canonical TTM setting).
- Confirmed HTF bars only — ON (default): stable, non-repainting readings that lag up to one bar of each row's timeframe. OFF: rows track the still-forming higher-timeframe bar — more current, but the reading can flip until that bar closes.
- Table position / Table size — where the board sits and how large it renders.
How to use it
Apply it to a 15m chart (or lower) so all five rows populate. Scan the Sqz column top-to-bottom: multiple orange/red dots stacked across timeframes indicate multi-horizon compression — historically the precondition for expansion moves. Then read the Mom column for directional lean while the compression resolves. The board is a context tool: it tells you where energy is stored, not when or in which direction it must release.
Limitations — please read
- Confirmed-bar lag: with the default non-repainting mode, the Weekly row updates once per week, the Daily row once per day, etc. That is the honest cost of stability. Turning the toggle off shows the live forming bar instead, and those readings can change until the bar closes.
- Rows below the chart's timeframe show "–": Pine's request.security() cannot reliably reconstruct lower-timeframe series, so instead of showing a possibly wrong dot the board declines to show one. Use a 15m chart to see everything.
- A squeeze has no direction. Compression means stored energy, not a buy or sell signal. The momentum color is a lean, not a prediction.
- Warm-up: each timeframe needs about 20 bars of history before its row populates (shown as "·" until then).
This board covers one symbol — the chart's.
Indicator

Volatility Squeeze Ignition [MarkitTick]💡 A multi-dimensional analytical engine designed to detect periods of extreme market consolidation and validate the subsequent directional expansion. By measuring the mathematical relationship between standard deviation and average true range, this tool identifies equilibrium zones where price action compresses and stores kinetic energy. Rather than reacting blindly to every volatility spike, the script employs a sophisticated filtration matrix that evaluates underlying volume delta, higher timeframe macro-trend alignment, directional movement strength, and immediate candlestick morphology. This creates a rigorous framework that authenticates breakout signals, ensuring that traders only focus on high-probability momentum ignitions supported by definitive market conviction.
✨ Originality and Utility
Standard volatility indicators often generate breakout signals without providing any insight into the underlying market participation or the structural validity of the move. This system distinguishes itself by integrating a state-tracking memory engine that monitors the cumulative buying and selling volume specifically during the compression phase. This continuous volume delta tracking allows the system to pre-assess the directional bias before the actual breakout materializes. Furthermore, it incorporates a dynamic risk-to-reward projection matrix mapped directly onto the chart. It calculates stop-loss zones and sequential take-profit levels based on the exact width of the preceding volatility squeeze. This creates a completely self-contained analytical environment that bridges the critical gap between signal generation and precise trade management, eliminating the need for discretionary target plotting and manual risk calculations.
🔬 Methodology and Concepts
● The Volatility Squeeze Engine
The core mechanics rely on the precise interplay between Bollinger Bands and Keltner Channels. A squeeze state is formally activated when the Bollinger Bands contract entirely within the boundaries of the Keltner Channels. This condition signifies that the market's standard deviation has fallen below its historical true range, indicating a profound period of low volatility and liquidity resting. The system mathematically locks in the exact width of the bands at the onset of this compression. An ignition signal is mathematically validated only when the price decisively breaks outside the Bollinger Bands, provided the bands have begun to expand.
● Volume Delta Profiling
While the squeeze state is active, the script meticulously aggregates the volume of up-closing bars versus down-closing bars. This builds a cumulative delta sum. When a breakout triggers, the system references this stored delta to ensure that the directional break is fully supported by the actual volume flow accumulated during the consolidation phase, preventing false breakouts engineered by low-liquidity spikes.
● Multi-Dimensional Filtering
The breakout validation process is governed by a rigorous confluence matrix:
Higher Timeframe Alignment: Evaluates a simple moving average on a higher resolution chart to ensure the breakout trades strictly in the direction of the macro trend, utilizing a secure, non-repainting data referencing architecture.
Trend Strength Evaluation: Integrates the Average Directional Index to demand a minimum trend strength threshold, actively filtering out choppy, sideways market noise.
Candlestick Morphology: Evaluates immediate, candle-by-candle price and momentum interaction. The real body of the breakout candle must constitute a specific percentage of the total high-to-low range, confirming definitive and immediate market conviction rather than relying on lagging divergences.
Volatility Expansion: Compares the current channel width against the locked width from the start of the squeeze, ensuring the breakout is accompanied by a genuine expansion in market volatility.
🎨 Visual Guide
● Chart Overlays
Active Squeeze Background: A subtle blue vertical background highlight appears when the volatility squeeze is actively compressing.
Breakout Backgrounds: A vibrant teal background signals a confirmed bullish squeeze ignition, while a vivid crimson background highlights a bearish squeeze ignition.
BB Basis Line: A solid blue line representing the central moving average of the standard deviation channel.
KC Lines: Muted, semi-transparent lines mapping the upper and lower boundaries of the true range channel.
● Trade Management UI
Entry Line: A dashed blue line marking the exact closing price of the validated breakout candle, accompanied by a dynamic price label.
Stop Loss (SL) Line: A solid, thick crimson line indicating the invalidation level. Depending on user settings, this is positioned either at the opposite channel edge or calculated via an ATR multiplier. A red translucent fill connects the Entry to the SL, visualizing the exact risk zone.
Take Profit (TP) Lines: Three distinct dashed teal lines representing sequential profit targets, derived from Fibonacci extensions of the locked squeeze width. A green translucent fill highlights the total reward zone from the Entry to TP3.
● Information Dashboard
A comprehensive heads-up display anchored to the chart corner providing real-time telemetry on the system's state:
Squeeze Status: Displays whether the compression is currently ACTIVE or OFF, alongside a graphical progress bar.
Sqz Bars: A numerical count of how long the current squeeze has been compressing.
BB Width %: A visual gauge showing the current width of the standard deviation channel relative to its basis.
Delta Bias: Highlights the dominant accumulated volume direction (BULLISH, BEARISH, or NEUTRAL) colored dynamically in teal or crimson.
R:R Metrics: Real-time calculation bars showing the exact risk-to-reward ratios for all three take-profit targets based on the current active signal.
Filter Diagnostics: Individual status readouts for HTF Trend, ADX, Body Strength, and Volume Confirmation, allowing traders to instantly see which filters are passing or failing.
📖 How to Use
● Identifying Setups
Traders should monitor the chart for the appearance of the blue active squeeze background. During this phase, direct your attention to the Dashboard to monitor the "Delta Bias" and "Sqz Bars" count. A longer squeeze accompanied by a strong, building Delta Bias indicates a high-probability impending breakout. Wait for a confirmed candle close that breaks the channel limits, triggering the vibrant teal or crimson background.
● Managing Trades
Once an ignition signal fires, the script automatically projects the entry, stop-loss, and three take-profit levels. Traders can use the SL line to place their initial protective stop. As price approaches TP1, traders may consider scaling out a portion of their position and trailing their stop loss to the Entry line to secure a risk-free trade. The graphical risk and reward fills visually assist in quickly assessing if the projected trade meets your personal risk parameters before execution.
⚙️ Inputs and Settings
● Core Parameters
BB Range: Defines the calculation range for the standard deviation channel.
BB Mult: The standard deviation multiplier determining the width of the outer bands.
KC Range: Defines the calculation range for the average true range channel.
KC Mult: The multiplier dictating the width of the Keltner Channels.
Min Squeeze Bars: The absolute minimum number of consecutive compressed bars required before a valid ignition can be fired.
● Filters
Require Volume Confirmation: Toggles the volume delta tracking engine.
HTF Trend Filter: Activates the macro-trend alignment requirement, preventing counter-trend breakout signals.
ADX Trend Strength Filter: Enables a strict momentum threshold requiring the market to be actively trending.
Candle Body Strength Filter: Enforces a structural rule where the breakout candle's body must meet a minimum size relative to its wicks.
● Trade Tools & Alerts
SL Mode: Allows traders to select between a structural stop loss at the opposite channel edge or a volatility-based ATR stop.
TP1, TP2, TP3 Fib: Customizable Fibonacci multipliers that project the profit targets based on the original width of the market squeeze.
Dashboard Settings: Toggles the visibility and positional anchoring of the telemetry table.
Alert Actions: Advanced JSON-formatted string inputs allowing traders to define precise webhook payloads for entries, exits, and target hits, enabling seamless automated execution.
🔍 Deconstruction of the Underlying Scientific and Academic Framework
● Volatility Compression Theory
The fundamental architecture of this script is rooted in the cyclical nature of market volatility, which oscillates continuously between periods of extreme contraction and aggressive expansion. By cross-referencing standard deviation against an absolute measure of true range, the algorithm quantitatively identifies the inflection points where liquidity providers pull back and the market reaches a state of unnatural equilibrium. The mathematical locking of the channel width captures the precise kinetic energy stored during this phase, applying principles of mean reversion and standard deviation expansion to project the statistical probability of the ensuing vector move.
● Order Flow and Delta Mechanics
To move beyond simple price derivatives, the system incorporates an approximated order flow model through its volume delta profiling. By segmenting traded volume into up-closing and down-closing aggregates during the compression state, the script builds a proxy for aggressive market participation. This mechanism relies on Auction Market Theory, assessing the imbalance between aggressive buyers lifting the offer and aggressive sellers hitting the bid. When the mathematical breakout aligns with the underlying delta accumulation, the script confirms that the price displacement is driven by genuine institutional or macroscopic participation, significantly reducing the statistical likelihood of a mean-reverting liquidity sweep.
⚠️ Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. We expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion. Indicator

Robust Bollinger Bands"First and foremost, full credit and massive respect to John Bollinger for inventing the original Bollinger Bands, an absolute cornerstone of technical analysis. This script does not aim to replace his legendary work, but rather to build upon his core philosophy by applying modern robust statistics to solve extreme outlier scenarios."
Description:
Overview
The "Institutional Robust Bollinger Bands" is a highly advanced, mathematically robust volatility indicator designed to solve the most common flaws of the classic Bollinger Bands. Standard Bollinger Bands rely on a Simple Moving Average (SMA) and Standard Deviation. Because standard deviation squares the distance from the mean, extreme market events (flash crashes, large gaps, or massive outlier wicks) artificially inflate the bands. This creates a "ghosting effect" where the bands remain irrationally wide long after the volatile event has passed, leading to false signals (fakeouts).
This script completely rebuilds the volatility model using Robust Statistics, Huber Weights, Kaufman-inspired Efficiency Ratios, and Asymmetric Expansion.
How It Solves the Classic Bollinger Bands Problem
Median (Q50) vs. SMA: Instead of using an SMA for the Basis line, this indicator uses the Median (Q50). The Median is statistically immune to single-bar manipulation. Even if a massive outlier wick occurs, the Basis line remains stable, completely ignoring the "fake" movement.
Huber Weighted Dispersion vs. Standard Deviation: Instead of squaring outliers, this script uses Median Absolute Deviation (MAD) and Huber Weights. Price action that falls outside a statistical threshold (1.345 * MAD) receives heavily penalized weights. This means the bands measure true continuous volatility rather than being skewed by one-off anomalies.
Asymmetric Bands: Financial markets do not follow a perfect normal distribution (Bell Curve); they exhibit skewness and fat tails. This script calculates the Skewness (Q75 + Q25 - 2 * Q50) and Kurtosis (Q95 - Q05). If the trend is aggressively skewed to the upside, the upper band expands further while the lower band tightens, adapting to the directional momentum asynchronously.
The Role of Classic Indicators & Custom Volatility Engines
While the core logic replaces classic averages with quantiles, we still utilize the classic Simple Moving Average (SMA) for a very specific, underlying purpose: Smoothing dynamic mathematical engines.
Efficiency Ratio (ER): We calculate a raw directional efficiency (netDisp / hlRange) inspired by Perry Kaufman's methodology. We then apply an SMA to smooth this raw data. This smoothed ER dynamically adjusts the Lambda (Skewness) multiplier. When the market is trending cleanly, the asymmetry expands automatically.
Gap & Body Volatility: We measure real tick-by-tick shock (disp = body + gap). We use an SMA to compare the short-term volatility of this calculation against its long-term average. This dynamically adjusts the Mu (Fat Tail) multiplier, fortifying the bands automatically when market gaps increase.
Key Features for Traders
Self-Adaptive Multipliers: You don't need to manually change settings for different assets. The internal Efficiency Ratio and Volatility engines automatically scale the Skewness and Kurtosis multipliers based on the asset's current state.
Percentile-Based Squeeze Detection (Yellow Background): Instead of looking for an absolute lowest value (which often breaks in prolonged ranging markets), the script uses a Percentile Rank logic. If the current bandwidth falls within the narrowest 15% (adjustable) of the last 100 bars, the background turns Gold/Yellow. This provides a highly stable visual cue that a major volatility breakout is building up.
QUICK COMPARISON: CLASSIC BB vs. ROBUST BB
1. BASIS LINE (MIDDLE BAND)
Classic: SMA (Simple Moving Average) - Sensitive to spikes.
Robust: Median (Q50) - Completely immune to single-candle manipulation.
2. VOLATILITY MEASUREMENT
Classic: Standard Deviation (Squared errors) - Outliers cause "Ghosting Effect".
Robust: Huber Weighted Dispersion - Punishes outliers, keeping bands stable.
3. BAND STRUCTURE
Classic: Perfectly Symmetric - Ignores market trend bias.
Robust: Asymmetric Expansion - Adapts to price skewness (Bullish/Bearish bias).
4. DYNAMIC MULTIPLIERS
Classic: Static (User-defined) - Requires manual tuning.
Robust: Self-Adaptive - Automatically scales Kurtosis and Skewness via Efficiency Ratios.
5. SQUEEZE DETECTION
Classic: Manual observation.
Robust: Percentile-Rank Based - Background turns yellow when bandwidth is in the narrowest 15% of recent history.
Usage
Use this indicator exactly as you would use classic Bollinger Bands, but with the confidence that outlier wicks will not distort your analysis. Look for continuous Squeeze (yellow) zones to prepare for breakouts, and observe the asymmetric expansion of the bands to understand the true strength and bias of a trend.
Disclaimer: This script is for educational and analytical purposes only. It does not constitute financial advice.
Indicator

MACD Dynamic Squeeze Pro [ZynAlgo]1. Technical Overview
ZynAlgo MACD Dynamic Squeeze Pro is a momentum-context indicator built from the traditional MACD concept. Instead of trying to pick tops and bottoms against the trend, it focuses on trend-following shakeouts, energy compression, and breakout confirmation after a squeeze phase.
2. Chart Reading & UI Guide
ZynAlgo Ribbon
The area between the MACD line and Signal line is filled with Green/Purple ribbon colors.
The ribbon helps traders quickly see which side currently has momentum control.
Use the ribbon as context for your own trading approach, not as a standalone entry trigger.
4-State Histogram
Neon Green highlights bullish acceleration.
Neon Purple highlights bearish acceleration.
Faded colors warn that momentum is losing strength or price may be stagnating.
Diamond Marker on Main Chart
The breakout context marker is plotted directly on the main price chart.
This reduces the need to constantly switch attention between the oscillator pane and price candles.
Treat the marker as a context alert that should be confirmed with your own entry method, risk plan, and market structure.
3. Zyn Explosion Logic
The Green/Purple diamond markers appear only when the indicator detects several conditions together:
Trend Filter: The MACD and Signal lines must both be above the Zero line for bullish trend context, or both below the Zero line for bearish trend context.
Squeeze Phase: The histogram compresses, showing that the market is consolidating or shaking out traders.
Explosion Phase: After the squeeze, MACD crosses the Signal line with enough timing alignment to suggest momentum expansion.
This is a context/analysis tool, not a signal generator. The marker identifies a possible momentum continuation area, but it does not execute trades or guarantee direction.
4. Settings Explanation
Momentum Average Length
Controls the period used to calculate the average volatility of the histogram.
This average becomes the baseline for detecting whether current momentum is compressed.
Squeeze Compression Ratio
Controls how tightly the histogram must compress before the market is considered to be in a squeeze phase.
For example, 0.5 means the current histogram column must compress to less than 50% of the average.
Lower values reduce marker frequency and make the squeeze requirement stricter.
Squeeze Valid Lookback
Defines how many bars after the squeeze phase the MACD cross can still qualify.
This helps reject late or off-beat crossover events.
5. Recommended Presets
Gold Breakout - XAUUSD 5m/15m
Squeeze Average Length: 20
Squeeze Compression Ratio: 0.4
Valid Lookback: 3
Useful when gold creates short-term shakeouts before starting a stronger trend move.
Crypto Trend Following - BTC/ETH 15m/1H
Squeeze Average Length: 30
Squeeze Compression Ratio: 0.5
Valid Lookback: 5
Useful when crypto spends longer periods in sideways consolidation before momentum expansion.
6. Best Practices & Limitations
Use this tool as momentum and squeeze context for your own framework.
Confirm any trade idea with price structure, session context, volatility, and risk planning.
A diamond marker is not an automatic buy or sell instruction.
This tool does not predict price movement.
You alone are responsible for your trading decisions.
No tool eliminates risk or guarantees results.
Indicator

Indicator

Momentum Squeeze Breakout EngineDescription
*Momentum Squeeze Breakout Engine* is a quantitative, trend-following breakout strategy engineered to capture explosive directional moves emerging from periods of asset compression (squeezes). By combining precise volatility boundaries, structural market sentiment filters, and micro-momentum triggers, this strategy systematically avoids false breakouts.
### Core Mechanics & Features
1. Volatility Squeeze Identification
The foundation of this strategy relies on the relationship between *Bollinger Bands* and *Keltner Channels. When the Bollinger Bands contract *inside the Keltner Channels, it confirms a highly compressed, low-volatility environment (highlighted by the subtle blue background zones). This indicates stored market energy primed for release.
2. Rigid Structural Macro Filter (200 EMA)
To eliminate counter-trend traps, the strategy utilizes a strict 200-period Exponential Moving Average (EMA) as a macro baseline. Long entries are strictly prohibited if the asset is printing below this line, ensuring you only trade high-probability expansions aligned with the dominant institutional trend.
3. Holistic Intra-Bar Bias
Rather than relying purely on close prices, the script calculates an internal *Holistic Bias* engine. It evaluates where the close falls relative to each bar's high-low range over a specific structural lookback period. A valid breakout requires a positive cumulative sentiment bias (cumBias > 0), ensuring authentic accumulation is taking place.
4. Micro-Momentum (Rate of Change) Filter
To prevent entering "slow drift" scenarios or low-volume fakeouts, a 3-period Rate of Change (ROC) velocity check is integrated. A breakout will only trigger an entry if the price action demonstrates immediate expanding velocity (priceROC > 0).
# Execution Rules
* *BUY Signal:* Generated when a compression zone has broken out within the last 3 bars, the price crosses above the Upper Bollinger Band, the macro trend is bullish (Price > 200 EMA), holistic bias is positive, and positive momentum velocity is confirmed.
* *EXIT Signal:* Generated when the price crosses below the Lower Bollinger Band following a squeeze or when the holistic bias shifts negatively, functioning as a structural trailing mechanism.
* *Signal Spacing:* Features a built-in 15-bar cooldown rule to prevent over-trading and signal clustering within volatile consolidation nodes.
### Best Practices
* *Intended Timeframe:* Optimized for the *1-Hour (1H)* chart.
* *Assets:* Best suited for high-liquidity assets including Major Crypto Pairs (BTC, ETH), Blue- Chip Equities, Indices and Major Forex Pairs.
* *Risk Management:* Default settings utilize a 100% equity allocation model for raw backtesting transparency, but traders should scale their position sizes according to their personal risk tolerances.
### Disclaimer
*Financial and Trading Risk Warning:*
This script is an educational and analytical tool designed to demonstrate quantitative breakout concepts using historical data. It is published as an open-source resource for informational purposes only and does not constitute financial, investment, or trading advice.
Past performance is not indicative of future results. Market conditions change constantly, and systematic strategies can experience significant drawdowns. Automated trading involves substantial risk of capital loss. Never trade with money you cannot afford to lose. The author assumes no liability or responsibility for any financial losses incurred from the use or modification of this code. Always perform your own independent research and forward-test on a demo account before risking live capital. Strategy

Squeeze Momentum Pro - TTM Squeeze, Volatility Breakout & MomentSqueeze Momentum Pro - TTM Squeeze, Volatility Breakout & Moment is a modern volatility squeeze and momentum indicator for PulseWire that shows you exactly when the market is coiling (building energy) and the precise moment that energy fires into a trend. It combines the classic TTM Squeeze concept — Bollinger Bands contracting inside the Keltner Channel — with a multi-tier compression engine (Squeeze Pro) and a glowing momentum histogram, so you can trade breakouts, momentum, trend continuation and volatility expansion on any market and any timeframe: forex, crypto, stocks, indices, futures, gold (XAUUSD), Bitcoin (BTCUSD), NASDAQ, S&P 500, oil and more. Built in Pine Script v6, it adds neon momentum candles, rare high-conviction squeeze fire signals and a live dashboard — a clean, professional upgrade over a plain squeeze momentum oscillator. Keywords: squeeze momentum, squeeze pro, TTM squeeze, volatility squeeze, momentum indicator, Bollinger Bands, Keltner Channel, breakout indicator, volatility breakout, momentum oscillator, trend, buy sell signals, scalping, day trading, swing trading, no repaint.
◆ WHY THE SQUEEZE WORKS
When Bollinger Bands contract inside the Keltner Channel, volatility is compressing — the market is coiling like a spring. Low volatility is always followed by high volatility. The squeeze tells you a big move is building; the momentum histogram tells you which direction it is most likely to release. Trading the release of a squeeze is one of the highest-reward, lowest-risk setups in technical analysis.
◆ WHAT IT DOES
3 compression tiers (Squeeze Pro): HIGH (BB inside KC x1.0, tightest coil), MID (x1.5), LOW (x2.0), and EXPANSION (bands released). Tier is shown by colour-coded dots on the zero line.
Neon momentum histogram: linear-regression momentum that glows brighter as it extends and dims as it fades — instant read of strength and direction.
Squeeze Fire signals: rare, high-conviction arrows that fire only when a real coil (HIGH/MID) releases — filtered to remove noisy weak releases.
Neon momentum candles: your chart candles are tinted by momentum (turquoise up / magenta down).
Live dashboard: State, a unique Coil Energy gauge (stored energy of the coil), Momentum strength, Signal and Bias.
◆ HOW IT WORKS (under the hood)
Bollinger Bands (length/multiplier) measure compression; Keltner Channel (ATR-based) is the volatility reference. A squeeze is active when both BB edges sit inside the KC edges.
Three KC multipliers create three compression tiers so you can tell a mild coil from a maximum-tension coil.
Momentum is a linear regression of price versus the average of the Donchian midline and the moving average (LazyBear method).
The script tracks the tightest tier reached during each coil; a fire is only flagged when the coil reaches your chosen tier and then releases — so arrows mean something.
Coil Energy accumulates from how long and how tightly price has been compressed, and discharges on release — a unique read of stored breakout potential.
◆ HOW TO USE IT
Wait for a squeeze (especially a HIGH tier — tightest spring). The dashboard shows State and rising Coil Energy.
On the Squeeze Fire arrow, enter in the direction of the histogram colour (teal = long, magenta = short).
Stay in while momentum keeps extending (bars growing, bright colour); exit as momentum fades (bars shrinking, dim colour) or flips across the zero line.
Use Fire on release from to control signal frequency: HIGH only (rare, strongest) → MID+ → Any (more signals).
Works on all symbols and timeframes; combine with your own support/resistance, structure or trend tools for confluence.
◆ SETTINGS
Squeeze Engine: BB length & multiplier, KC length, KC multipliers for HIGH/MID/LOW tiers.
Momentum: linear-regression length.
Fire Signals: release tier threshold (HIGH only / MID+ / Any).
Histogram / Candles: glow, tint chart candles by momentum, optional squeeze-zone shading, fire markers.
Panel: show/hide, position, background, accent colour.
◆ ALERTS
Squeeze Fire Long / Short
High Squeeze started (maximum compression)
Momentum crossed zero
◆ LIMITATIONS
This is a momentum/volatility tool, not a complete system — always confirm with price action and risk management.
On forex and crypto, volatility (ATR) and momentum reflect the data feed of your broker/exchange; results can vary slightly between feeds.
A squeeze signals that a move is building, not its direction with certainty — the momentum colour gives the probable bias, not a guarantee.
With "HIGH only" some calm instruments may rarely reach the tightest tier; loosen the KC HIGH multiplier or switch to "MID+" if you want more signals.
◆ NON-REPAINTING
Every value comes from confirmed bar data with no lookahead and no security() smoothing tricks. A signal printed on a closed bar stays. As with any live tool, the current forming bar updates in real time and settles on close.
Squeeze Momentum Pro - TTM Squeeze, Volatility Breakout & Moment is an educational analysis tool, not financial advice. Always do your own research and manage risk. © LunqFX. Indicator

Strong Squeeze Signals | ProjectSyndicateStrong Squeeze Signals catches the moment a genuine volatility coil releases — and instead of treating every flat patch as a setup, it waits for a real squeeze to fire, tags the direction from momentum, and ranks the release 0–10 with a star score. A market that has been compressing for a stretch of bars — its Bollinger Band wound tightly inside its Keltner Channel — has to actually expand back out, in the direction of momentum, before a signal arms. Every setup gets a structural stop beyond the coil that just broke and fixed R-based targets, and is tracked live on a full statistics dashboard so you can see how the logic behaves on the exact symbol and timeframe you trade.
🧠 Squeeze-Release Core — the core idea. The engine measures volatility compression directly from two bands. When a Bollinger Band contracts entirely inside a Keltner Channel, the market is coiling: range is shrinking and energy is building. A signal fires on the release — the bar where the band expands back outside the channel — and the direction is set by a linear-regression momentum oscillator that measures how far price sits from a composite centreline. Momentum above zero on the release fires a long; below zero fires a short. The longer and tighter the coil before it lets go, the more it counts. Signals are evaluated on the bar's close and are fixed once that bar closes — the release does not repaint.
📈 Coil Mapping & Tightness — while a squeeze is active, the engine continuously tracks how many bars it has been compressing, the high and low extent of the coil, and how tight it became — the Bollinger half-width as a fraction of the Keltner half-width. A long coil that wound down to a very tight ratio is a loaded spring; both the duration and the tightness feed directly into the strength score. A minimum-coil filter ignores fleeting micro-squeezes, and an optional Strict Fire setting demands a confirmed expansion on the release bar rather than just the end of the coil.
🎯 Structural Stop + R-Based Targets — the stop is placed just beyond the coil that just broke, with an ATR buffer: below the coil's low for a long, above the coil's high for a short — then capped and floored by ATR so it can never balloon into a wide stop or collapse into a meaningless one. TP1, TP2, and TP3 are set at clean R multiples and default to 0.5R / 0.75R / 1.25R — a tighter, hit-rate-leaning profile out of the box, and fully adjustable to whatever reward-to-risk you prefer. Every signal plots its complete Entry / SL / TP1 / TP2 / TP3 line set, labeled price levels, and filled TP / SL zone boxes, with a result label on exit.
🎚️ Coil-Conviction Controls — two inputs set how serious a squeeze must be before its release counts: Minimum Coil Bars To Arm how long the spring must compress and Minimum Strength the 0–10 gate. Tighten them for fewer, higher-quality fires; loosen them for more frequent signals. This is your main dial for conviction versus frequency.
🧭 HTF Trend Alignment Filter — an optional higher-timeframe EMA filter blocks counter-trend fires, keeping you on the dominant side of the market: longs only above it, shorts only below. The higher-timeframe value is read without lookahead. A signal cooldown spaces out entries so a single impulsive expansion doesn't stack multiple tickets.
⭐ 0–10 Setup-Quality Score — every release is scored and labeled with 1–5 stars and a tier FORMING → WEAK → MODERATE → STRONG → VERY STRONG → ELITE across nine squeeze-native factors: coil length stored energy, coil tightness how far the band compressed inside the channel, momentum magnitude at release, momentum acceleration in the fire direction, volume confirmation, expansion-candle body and range, band-width widening on the break, higher-timeframe alignment, and RSI agreement. Treat the score as a confluence / cleanliness read for ranking and thinning setups — it describes how textbook a squeeze release is, not a guaranteed outcome. A Minimum Strength / Only Strong gate lets you display and alert on stronger setups only, while the dashboard keeps tracking every tier in the background.
📊 Live Statistics Dashboard — a non-intrusive panel tracks, in real time on your chart: the current squeeze state coiling / fired / expanded / no squeeze, live coil-bar count, the momentum reading, current status and the active trade, the last signal with its star score, total signals, win rate, closed trades, profit factor, average R per trade, best-performing direction, long vs short win rate, current and max win/loss streaks, and a TP1 / TP2 / TP3 / SL hit breakdown. These are computed live from the signals on your current symbol and timeframe — so you can judge the settings yourself rather than trusting a number printed in a description.
🎨 Clean Themed Visuals — an institutional colour palette shades each zone by direction and score: bullish coils run a teal family that deepens as the score climbs, bearish coils a red-to-magenta-to-purple family, so quality reads at a glance. The compression zone is drawn over the bars where the coil formed and labeled with FIRE plus its star score; the TP and SL zones are harmonized to the same palette. Four lighting themes drive the lines, labels, and dashboard; an optional faint background tint marks active coils, and optional state dots can sit under the chart. A Max Zone Width control caps how far the SL / TP / Entry zones extend to the right, so long trades never stretch into oversized towers across the chart.
🔔 Detailed Alerts — fires on strong long / short squeeze releases, plus squeeze-on new coil forming, squeeze-released, partial-TP, TP3, and SL events, including direction and score, formatted for manual or automated use. The minimum-strength setting can restrict alerts to higher-conviction setups.
🔧 Fully Customizable — every component is exposed: Bollinger and Keltner lengths and multipliers, the true-range toggle, minimum coil bars and Strict Fire confirmation, the 0–10 strength gate and Only-Strong filter, ATR length, the structural-stop buffer with risk cap/floor, the three R targets, level-shelf length and Max Zone Width, the HTF alignment filter, the signal cooldown, plus the full institutional box palette, all four themes, and every label, dashboard, and zone-shading option.
🎯 Why this is different — most squeeze tools just print a histogram or drop a dot when the bands let go and leave everything after that to you. This one classifies the release direction from momentum, requires a real coil rather than a momentary flat spot measuring both how long and how tightly it compressed, demands momentum, acceleration, volume, and expansion confirmation, anchors the stop to the coil that actually broke, then layers an objective 0–10 ranking and a live, on-chart statistics panel on top — so you are tuning and judging the system on real, current data instead of a marketing figure.
🚀 Where to use it — markets that coil and expand: Forex, Gold XAUUSD, indices, and crypto, on intraday and swing timeframes M10/M15/M30/H1 and up. The ATR-based stop and R targets adapt to each asset's volatility automatically.
🎯 How to trade it
Apply it to a market that produces real volatility cycles and let the dashboard populate. Read the live win rate, profit factor, and average R for your symbol and timeframe before committing — if the logic doesn't suit that market, you'll see it.
Keep the HTF Trend Alignment filter on so you only take releases in the direction of the larger trend.
Wait for a STRONG LONG FIRE / STRONG SHORT FIRE label — it marks a confirmed coil release, with the star score and Entry, SL, and TP1/2/3 already plotted.
Manage the trade with the plotted levels: with the default sub-1R targets a common approach is to bank TP1 quickly, then trail or hold the remainder toward TP2/TP3; the structural SL defines your risk on the trade. If you prefer a higher reward-to-risk profile, widen the R targets in the inputs.
Use Minimum Coil Bars and Minimum Strength to set your style — stricter for fewer, cleaner releases; looser for more activity — and use the star score and Only-Strong gate to focus on the cleanest setups.
⚠️ Important — this is a decision-support tool, not a standalone buy/sell system, and it makes no performance guarantees. Default settings were chosen on historical data and behavior will vary by symbol, timeframe, and configuration; the dashboard's statistics are historical and descriptive, not a forecast. Note the default targets are sub-1R 0.5R / 0.75R / 1.25R: tight targets tend to raise the raw hit rate while lowering the reward-to-risk on each trade, so win rate read on its own is misleading — always weigh it together with average R and profit factor, and resize the targets to your own risk profile. Signals confirm on the closed bar, so always wait for the labeled release on a closed candle. Always combine it with your own analysis and risk management, and test it on your market before trading it live. Indicator

Volatility Pressure & Regime AnalyzerVolatility Pressure & Regime Analyzer
## What this script does
VPRA estimates **when a market is loading energy for an outsized move, how large that move could be, and whether the current regime favors chasing or fading the breakout**. It condenses this into one on-chart verdict panel, directional signal markers, a regime ribbon, and a forecast of the expected move in ATR and points.
It works on **any symbol, any market, any timeframe**. A related volatility index and a companion symbol (the underlying if you chart a derivative, or vice versa) are optional inputs that sharpen the analysis; both can be disabled and the model renormalizes to price-only mode automatically.
## Why these components are combined (mashup justification)
Each module answers a question the others cannot, and the signal only fires when their answers agree. None of them is a stock indicator pasted alongside another — they are inputs to a single pressure model:
1. **Compression (ATR percentile)** answers *"is energy being stored?"* Quiet ranges precede expansion, but compression alone says nothing about direction or timing.
2. **Implied-vs-realized volatility dislocation** (optional vol index) answers *"is the options market mispricing the calm?"* A large gap between implied and realized volatility marks complacency or stress that compression alone cannot see.
3. **Basis tension** (optional companion symbol) answers *"is positioning leaning?"* Momentum in the derivative-to-underlying spread, and outright backwardation, reveal funding pressure and de-risking invisible in a single price series.
4. **Convexity and trend inefficiency** (return acceleration, efficiency ratio) answer *"is price behavior becoming unstable?"*
These four are blended into one **Pressure score (0–100)**, percent-ranked against its own history so thresholds adapt to every symbol and timeframe.
5. **A variance-ratio regime filter** answers *"will the break run or get faded?"* The ratio of k-bar to 1-bar return variance classifies the tape as mean-reverting (pinning) or trending (amplifying). Breakouts in a pinning regime are statistically more likely to fail, so the script can label or skip them.
6. **A multi-timeframe trend filter (Ichimoku cloud bias on the chart TF + three higher TFs)** answers *"is the release direction supported by structure?"* It grades signals rather than generating them. Higher-timeframe values are taken from **closed bars by default, so the confluence grade does not repaint**.
7. **Session, expiry, gap and event context** scale the expected-move forecast: an expiry-afternoon release during a volatility spike forecasts a larger move than a sleepy mid-session one.
Removing any module degrades a specific, named capability — that is the test the combination was built to pass.
## How a signal is generated
A marker prints only when **all** of the following align: pressure has reached a high percentile of its own history within a short lookback ("loaded"), the current bar shows a genuine range expansion ("release"), the condition persists for a confirmation bar count, a debounce gap has passed, and (optionally) the regime and trend filters pass. Direction is scored from **trigger-break** (close beyond the prior N-bar extreme), **close location** within the bar, and short momentum.
Marker color encodes the inferred event type: expiry-session releases, volatility-co-movement squeezes (price and vol index moving together — a short-covering tell), or plain expansions. The glow ring encodes how many higher timeframes agree. An ⓘ label stores a full diagnostic snapshot (pressure, regime, instability, basis, energy, session, expected move) in its tooltip for every signal.
## How to use it
- Apply to a liquid symbol; set "This chart is" to Derivative or Underlying, point the companion and volatility-index inputs at your market's related symbols (or disable them), and set your session hours and expiry weekday.
- Read the panel top-down: **Regime** (chase vs fade), **Pressure/Energy** (how loaded), **Move size** (forecast), **Trend align / HTF** (structure), **Triggers** (the price levels that confirm).
- Use the "Filter" modes to suppress signals against regime or higher-timeframe structure, or leave them as badges and judge manually.
- The advanced rows show per-type follow-through statistics (hit rate, average favorable and adverse excursion in ATR) and an early-vs-late history split as a coarse robustness check. **These are in-sample descriptive statistics, not a backtest.** A companion strategy script with identical logic is available for proper backtesting with costs.
- Alerts: per-signal dynamic alert with all values (webhook-ready), plus static conditions for expiry signals, releases, critical pressure, and vol shocks.
## Originality
The pressure blend (compression x vol-dislocation x basis tension x convexity x inefficiency, percent-rank normalized), the variance-ratio regime gate applied to breakout qualification, the compression-energy budget, and the per-type MFE/MAE statistics with an early/late split are original constructions written from first principles for this script. The only classical components used are public-domain building blocks (ATR, Bollinger/Keltner-style compression logic via ATR percentile, Ichimoku cloud bias as a trend filter, Kaufman efficiency ratio), each justified above.
## Limitations (please read)
- Dealer-positioning effects (often discussed as gamma/vanna/charm) are **inferred from price, volatility and basis behavior**. This script does not and cannot read option-chain open interest. Labels such as "gamma blast" describe an expiry-session release pattern, not a measured dealer position.
- All on-panel statistics are computed on the loaded chart history and will differ across symbols, timeframes and history length.
- Higher-timeframe confluence uses closed HTF bars by default (no repaint); the current chart bar still forms in real time, as with any script.
- Expected-move figures are model estimates, not guarantees.
This script is for education and analysis. It is **not financial advice**; trade at your own risk and test before use.
Indicator

Adaptive Bollinger Bands Calibrated and Regime-Aware# Adaptive Bollinger Bands — Robust, Calibrated & Regime-Aware (BB ARC)
## What this is
Most Bollinger Band tools plot a simple moving average plus or minus two standard deviations and assume price is normally distributed. Real price is not: it has fat tails, it is skewed, and a single spike distorts the width. BB ARC is a full reworking of the Bollinger idea that measures the **actual distribution** of the symbol on your chart, builds statistically honest bands from it, proves how well those bands describe the market in real time, and then decides whether a band touch should be **faded** (range) or **ridden** (trend). Everything is universal: the price source and all optional reference feeds are user-selectable, so it runs on any symbol, any market and any timeframe.
It plots the bands and signals on the price chart and an analytics oscillator (%B or band-z) in a lower pane, with a single dashboard that turns all of it into one read.
## Why these components are combined (mashup rationale)
A raw band only says "price is far from its average." On its own that is ambiguous: in a quiet range a touch of the band mean-reverts, but in a strong trend price "walks the band" and keeps going. Giving the same signal in both situations is the classic Bollinger weakness. BB ARC combines several layers specifically because each one removes a weakness the others cannot, and they feed each other in sequence:
1. **Honest band engine** — replaces the naive standard-deviation width with a choice of robust (median / MAD), asymmetric (separate upside/downside deviation, capturing skew), empirical-quantile (width set so the band actually contains your chosen percentage of bars), or EWMA-volatility estimators, plus a kurtosis-adaptive multiplier that widens the band when tails are fat. This makes the *distance* of a touch statistically meaningful instead of an arbitrary 2-sigma.
2. **Calibration layer** — because the bands now claim to contain a certain fraction of price, the script measures the **realized containment %** on the current symbol, plus skew and kurtosis, so the band proves its own validity instead of asking you to trust a textbook assumption.
3. **Regime filter** (efficiency ratio + ADX + volatility clustering) — decides whether the market is ranging, trending or volatile, and therefore whether the correct response to a band touch is to fade it or ride it. This is what resolves the Bollinger paradox above.
4. **Mean-reversion math** — an Ornstein-Uhlenbeck half-life estimate quantifies how many bars a touch typically takes to revert (and reports "trending" when there is no clean reversion), and band-walk persistence counts how long price has been pinned to a band. Together they tell you whether a reversion is realistically tradable.
5. **Multi-timeframe confluence** — checks %B agreement across four timeframes and draws higher-timeframe band rails on your chart, so a signal is not taken against the larger structure.
6. **Conviction engine** — blends the stretch, regime fit, MTF agreement, half-life quality, calibrated edge, volume thrust and order-flow into a single 0-100 score with hard vetoes, so you get one decision rather than several conflicting indicators.
None of these layers is decorative; remove any one and the others lose context. That interdependence is the reason they are published together rather than as separate scripts.
## What it does, step by step
- Builds a basis (SMA / EMA / rolling VWAP / robust median) and three band tiers using the deviation engine you select.
- Computes **%B** and **bandwidth**, a signed **band-z** (how many multiples beyond the basis, using the correct up or down deviation), realized **containment %**, **skew/kurtosis**, **half-life**, **band-walk** streaks, an empirical **reversion probability** (how often, historically on this symbol, a band touch returned toward the basis within N bars), and a **squeeze** state with an expansion-direction read.
- Classifies the **regime** and auto-selects **Fade** (range reversion) or **Ride** (trend continuation) logic.
- Detects regular **%B divergence** and can draw it as lines connecting the pivots on price.
- Produces a **verdict** (LONG / SHORT / VETO / FLAT) with a conviction score and tier, and fires alerts on bar close.
## How to use it
1. Add it to any chart. The bands appear on price, the %B/band-z analytics in the lower pane, and the dashboard in the corner.
2. Read the **REGIME** and **MODE** rows. In a Range regime the engine looks to **fade** outer-band touches back toward the basis; in a Trend regime it looks to **ride** band-walks in the trend direction.
3. Use the calibration rows as a confidence check: a high containment %, a short half-life and a favourable reversion probability support a fade; "trending" half-life and persistent band-walk support a ride.
4. Treat the **CONVICTION** score and **VETO** as the gate — a high score with no veto is the cleanest setup; a veto explains why a tempting touch is being skipped.
5. Optional: enter a volatility-index symbol and/or a correlated instrument in the feed settings to add a volatility-spike veto and cross-asset confluence. Both are blank (off) by default, so nothing market-specific is assumed.
## What makes it original
- A **multi-engine, statistically honest** band (robust, asymmetric semideviation, empirical quantile, EWMA, fat-tail-adaptive) rather than a single SMA±kσ.
- **Live self-calibration**: the band reports the percentage of bars it actually contained, on the current symbol, so its claim is verifiable.
- An **Ornstein-Uhlenbeck half-life** read that turns "far from the mean" into "expected to revert in about X bars, or not at all."
- An **empirical reversion-probability** statistic built from the chart's own history.
- A **regime-driven fade/ride auto-switch** and a single **conviction score with vetoes**, so the same band touch is interpreted correctly in different market states.
## Settings overview
Grouped as: Core (price source, basis, adaptive length), Band Engine (deviation engine, multipliers, quantile %, EWMA lambda, fat-tail), Regime, Mean-Reversion, Calibration, Squeeze, Signals, MTF, Conviction (weights and minimum), Risk (used for sizing and alert context), Optional Reference Feeds (volatility index, cross-asset — both off by default), and Display (bands, fills, divergence-as-lines toggle, adaptive dashboard, legend, identity label).
## Universal data source
The whole engine runs on a user-selected **price source** (close, hl2, hlc3, ohlc4, or even another indicator's output), and the optional reference feeds are typed in by the user, so the script is not tied to any one instrument or exchange. It also degrades gracefully on instruments without volume.
## A note on the chart used for publishing
The published chart shows only this script. The bottom-centre label prints the script name, the symbol and the timeframe so it is always clear what is plotted. No unrelated drawings or third-party indicators are added.
## Disclaimer
This script is a technical study for educational and informational purposes only. It is not financial, investment or trading advice, and it is not a strategy or a solicitation to buy or sell any instrument. The signals, levels, conviction scores and statistics it displays are derived from past price and volume on your chart and do not guarantee any future result. Markets involve risk; you are solely responsible for your own decisions and risk management. Test thoroughly before relying on any tool.
Indicator

SuperTrend Exhaustion Clues [Gabremoku]SuperTrend Exhaustion Clues is a context-aware SuperTrend indicator that separates structural direction from signal timing. Instead of treating every flip as a trade trigger, it classifies market behavior into four states: Transition, Confirmed, Compressed Break, and Exhausted. The goal is to show when trend structure is still healthy, when it is compressing, and when it is weakening enough to start looking for directional clues.
The core logic combines four elements: SuperTrend for directional structure, ADX and DI for trend strength, VWAP and price location for acceptance, and compression detection for squeeze/release context. These components are not merged just for convenience; they work together to decide whether price is merely changing direction structurally or whether it is also showing enough internal confirmation to justify attention.
BUY and SELL signals are not printed on every flip. They are designed to appear only during Exhausted phases, and only when directional clues align with the next likely move. This makes the indicator more selective than a standard SuperTrend and better suited to reading late-stage trend fatigue and early follow-through behavior.
A built-in Signal Profile lets you choose between Responsive, Balanced, and Selective behavior. Responsive lowers the confirmation threshold and is better for faster charts, Balanced is the default middle ground, and Selective raises the bar for cleaner but rarer signals. For this reason, the script is especially useful on lower timeframes, where exhaustion tends to be easier to read and directional clues appear earlier.
For higher timeframes, the script can keep showing state, regime, and clue scores while disabling signals from 4H and above. This helps avoid forcing execution signals where the exhaustion logic is less expressive, while still letting you use the indicator for context and structure.
The visual design is intentionally restrained: bullish states are blue, bearish states are yellow, compression is purple, transition is gray, and exhaustion is red. The SuperTrend line, gradient fill, dashboard, and color legend are meant to make the state of the market easy to read at a glance without cluttering the chart.
How to use it: watch the current state first, then use Exhausted phases as the main area of interest. When the script shows Exhausted and the directional clue score aligns with the next move, that is the moment it is designed to highlight. On 4H and above, the script is better used as a structural context tool rather than a signal engine.
@Gabremoku
PulseWire Indicator

MACD Dive [TTM Squeeze | Dual Lock %R]Disclaimer : This indicator is not financial advice and is strictly for educational and informational purposes only. The metrics and signals provided herein (including momentum crosses, trend saturation state icons, and squeeze markers) are calculated based on historical market data and do not guarantee future performance. Trading stocks and commodities involves significant risk of loss. The user assumes full responsibility for all trading decisions and should always perform their own due diligence before executing trades.
MACD Dive is a multi-state momentum and volatility context engine. By layering momentum oscillation (MACD/PPO/MACD-V) with market stalemates (volatility squeeze) and trend exhaustion (Dual %R saturation), this suite transforms a standard MACD into a multi-dimensional 'No-Go' gatekeeper. This synergy is what gives the engine its edge: it actively blocks the trader from whipsawing in sideways chop or buying into a dying trend, highlighting high-probability market turns where momentum, volatility, and trend capacity perfectly align.
Standard oscillators have a scaling problem. This script lets you choose your engine:
MACD (Classic): Measures momentum in absolute dollars. Great for visual reactivity, but a "2.0" reading means something different on a $5 stock versus a $500 stock.
PPO (Percentage): Measures momentum in percentages. Standardizes the reading across all assets, making it ideal for fixed-rule algorithmic trading.
MACD-V (Volatility Normalized): This divides the MACD by the Average True Range (ATR). It measures momentum in "Units of Volatility," mathematically adapting to market chaos so that signals remain consistent across both different assets and shifting volatility regimes (quiet markets vs chaotic markets).
This suite includes a fully optimized divergence detection engine:
Regular Divergence (Solid Lines): Identifies Trend Reversals. Price pushes to a new extreme, but momentum fails to follow, signaling exhaustion.
Hidden Divergence (Dashed Lines): Identifies Trend Continuations (Slingshots). Price pulls back, but momentum fully resets, signaling a high-probability entry in the direction of the dominant trend.
Located in your chosen corner, the HUD provides an instant visual readout with hover tooltips for active Engine Mode, %R Fatigue state, Oscillator crossover validation, and Squeeze environment. Vertical background highlights in green or red represent filter-passed momentum crossovers, like the MACD bullish cross. Use the extensive inline tooltips in the indicator's settings panel for a comprehensive breakdown of every tunable parameter.
Adaptive Time-Frames & RSI Gatekeeper
Think of this as an automated gear shifter. When looking at lower timeframes (below a user-defined boundary, e.g. 1 hour), the engine automatically scales down to tight, agile lookback periods. When viewing high timeframes, it dials up to filter out noise.
Buying a bullish MACD cross when the RSI is already at 85 increases risk of buying the top when the tank is empty. The optional RSI Safety Filter acts as a strict ceiling/floor blocker. If momentum crosses upward but the asset is mathematically overbought, the indicator suppresses the background highlight. It prevents signals on MACD crosses that have no fuel left.
VOLATILITY ENGINE: BB-KC Squeeze Radar
Building on John Carter’s TTM Squeeze by mapping the contraction of Bollinger Bands inside Keltner Channels to identify market stalemates. The implementation here color codes between a Loose Squeeze (BB inside 1.5 KC) and a hyper-compressed Tight Squeeze (BB inside 1.0 KC) to show the staged intensity of the coiled spring.
While the market coils sideways, a 20-period Linear Regression calculates the trajectory of price deviation inside the bands. The directional bias is shown by customizable markers on the zero line (default ⌃ or ⌄). This reveals hidden institutional accumulation or distribution before the trigger is pulled. To bypass "dead money" risk, the script tracks the first clean candle close or intraday pierce outside the Keltner bounds following a squeeze, catching the expansion phase exactly as it starts.
Furthermore, it accounts for the "Disappearing Mark" phenomenon. Bollinger Bands expand instantly when price moves, causing standard squeeze signals to vanish 1-3 bars before the real breakout candle. This script uses a memory state to remember recent compression, firing a "squeeze release" marker (default ❖) the exact moment price closes outside the Keltner bounds. Trade the release, not the waiting room.
Note: While MACD Dive tracks this compression mathematically on its zero-line, you can see the actual physical boundaries of the breakout by pairing it with my companion Swing Data suite . Plotting its Keltner Channel at 1.5 multiplier over your price chart allows you to visually verify the exact moment the squeeze release mark is ignited.
SATURATION ENGINE: Dual-Lock %R and Momentum Rot
This suite tracks sustained trend maturity using a fast/slow dual Williams %R setup. The conceptual pairing of a fast and slow %R to identify overbought/oversold exhaustion is credited to upslidedown's excellent Trend Exhaustion indicator . I highly recommend applying their script to your chart if you want to visually learn how the two %R lines interact.
While upslidedown’s implementation offers multiple display modes to paint visual boxes and exhaustion zones directly over price action, the focus here is on the discrete icons for trend status at the top and bottom of the MACD pane: Ignition (·), Saturation (□), and Fatigue (×). This suite adapts native ta.wpr() math assuming the trader is already familiar with Dual %R mechanics. Specific "Sprint" and "Marathon" tuning guidance is provided in the tooltips: heavily smoothing the fast line to ignore intraday noise, while lightly smoothing the macro slow line to preserve its reach into extreme zones.
It also features one major addition: the Stall. While Dual %R tracks Price Location (confirming price is structurally pinned at the highs), it doesn't track Velocity (confirming energy is sustained). To solve this, a Stoch RSI "Rot" detector runs quietly inside the saturation state. If price continues to float at the highs but internal velocity drops below a critical threshold, the script overlays a Stall marker (•). Designed as a "one-shot" early warning, it fires only on the first detection per trend saturation leg to prevent chart clutter. This differentiates a strong trend lock from a rotting lock, warning us that the move is running on fumes: giving us the exact cue to tighten stops, trim into parabolic strength, and strictly avoid adding new size.
BACKTESTER READY
Out-of-the-box compatibility with a comprehensive built-in README guide is available directly inside the settings menu. For traders who prefer a "Diamond Hands" approach, the indicator fully maps to Jason5480's TTS Framework convention, outputting strict integer states (1, -1, 2, -2) to hold full position size until the trailing macro baseline completely fractures. My personal backtester, Cosmos Signal Commander (which may be released to the public in the future), broadcasts a composite float signal capable of managing active trade positioning. It tracks entries, hard stops, and partial take-profits (swapping the trailing stop from tight to a wide "runner" buffer upon hitting extended ATR targets).
PERFORMANCE OPTIMIZATION
O(1) Memory States: Replaced lag-heavy ta.barssince() and 50-bar for loops in the Divergence engine with O(1) var state trackers.
String Caching: HUD table strings are built once in the global var scope to prevent constant memory allocation and garbage collection lag.
UI Mutation: The HUD uses table.cell_set_* to alter data dynamically, bypassing the stutter caused by destroying and redrawing tables on every tick.
Native C++ Backend: Replaced custom highest/lowest math arrays with native ta.wpr() functions for the %R engine to maximize computation speed.
Ghost State Resets: When switching the backtester logic to "Long Only" mode, the engine actively hunts and kills lingering short-memory variables so they don't inadvertently suppress valid long signals.
Indicator

Squeeze Vector [Gabremoku]Squeeze Vector is a squeeze-based volatility breakout tool that combines Bollinger/Keltner compression detection, directional pressure flow, and a first-expansion state machine to help traders identify high-probability post-squeeze breakout setups.
The core idea is simple: compression precedes expansion. When Bollinger Bands shrink inside Keltner Channels, the market is coiling — and when that squeeze releases, the first directional signal can carry strong momentum. This script gives that process a structured visual and logical framework.
Core Concept — Squeeze → Release → Direction
A BB/KC squeeze occurs when Bollinger Bands, which reflect price volatility through standard deviation, contract inside Keltner Channels, which reflect typical range through ATR. This gap between the two envelopes is used as a proxy for volatility compression.
When BB width becomes smaller than KC width, the script identifies a Squeeze state. When it releases, the script enters an Armed state and opens a short post-squeeze window during which it looks for the first valid directional expansion.
Importantly, the squeeze release alone does not confirm direction. That is why the script adds multiple expansion confirmation filters before triggering a signal.
What it shows
Squeeze Vector Oscillator — a single line that rises as BB/KC compression increases. When it crosses above 50, the squeeze is active. The oscillator turns purple during squeeze states for fast visual identification.
Pressure Flow Histogram — a volume-weighted directional pressure value that reads where price closed within the candle range and weights it by volume relative to its moving average. Positive values indicate bullish pressure, negative values indicate bearish pressure.
Bollinger Overlay on Price — during squeeze states, the script renders Bollinger Bands directly on the main chart with gradient fills, making it easy to see where price is relative to the compressed structure.
LONG / SHORT signals — primary directional signals are placed on the main chart after a post-squeeze expansion bar meets all required conditions. Optional lighter repeat markers can be shown for follow-through confirmation.
Dashboard with live checklist — the on-chart dashboard shows the current state, regime, pressure, vector value, and a 6-point checklist for both long and short setups, with filled/empty circles to show how many conditions are currently met.
Signal Logic
The signal engine works as a state machine with three phases:
Squeeze — BB/KC compression is active. No signal is generated. The dashboard shows SQUEEZE.
Armed — the squeeze just released. The script opens a short expansion window and waits for directional confirmation. The dashboard shows ARMED.
Expansion signal — within the expansion window, if a valid directional bar forms with sufficient pressure, body size, and break condition, a LONG or SHORT label is placed on the main chart.
Signal direction is confirmed by checking:
Basis side: price above or below the BB basis
Pressure: smoothed directional pressure above threshold
Strong pressure: optional stronger filter
Body quality: minimum body-to-candle-range ratio
Break condition: higher high or lower low
Regime: optional EMA 200 trend filter
When both long and short conditions are simultaneously valid, the stronger pressure side wins. If pressure is equal, raw pressure bias decides.
States and Dashboard
The dashboard tracks the full machine at a glance:
Row Content
SQZ Squeeze ON / OFF
SEQ ARMED or READY
REG Trend regime (BULL / BEAR / OFF)
BIAS Current directional pressure bias
P Pressure Flow value
V Vector Oscillator value
Checklist 6-point LONG and SHORT condition matrix
The checklist can be set to appear only during Squeeze or Armed states to reduce visual noise when no setup is forming.
Features
✅ Bollinger/Keltner squeeze detection via ratio oscillator
✅ Volume-weighted directional pressure flow
✅ Post-squeeze first expansion state machine
✅ Armed → signal transition logic
✅ 6-point entry checklist for both long and short
✅ EMA 200 regime filter
✅ Bollinger overlay with gradient fill during squeeze
✅ LONG / SHORT signal labels on main chart
✅ Optional follow-through repeat markers
✅ Repeat window filter to suppress signal clustering
✅ Strategy mode: Long, Short, or Both
✅ Fully configurable dashboard with size and offset settings
✅ Alert conditions for BUY, SELL, and squeeze activation
How to use
A practical workflow:
Watch for the Vector Oscillator to cross above 50 and turn purple — that is the squeeze state.
When it releases below 50, the dashboard switches to ARMED.
In the expansion window, check the checklist: more filled circles on one side indicate stronger directional alignment.
A LONG or SHORT label confirms a valid first expansion signal.
Use the Pressure Flow histogram to gauge how strong and consistent the directional push is.
The squeeze release alone is not a signal. Direction is only confirmed when the expansion bar quality, pressure, and structure checks all align.
Notes
Like all squeeze-based tools, Squeeze Vector is most effective when used alongside price structure context. Squeezes release into strong moves, but not every release produces a sustained trend — volume, higher timeframe context, and support/resistance levels can all affect follow-through quality.
Author: Gabremoku
Pine Script v6 Indicator

Bollinger Band [scoopup]Overview
A Bollinger Bands–based indicator that shows trend direction (up/down) through the basis line color, displays band width (volatility) as a percentage, and marks the most recent meaningful lows (demand zones) on the weekly and daily timeframes as boxes. It lets you view statistical volatility and the real low zones where buying previously stepped in — all on a single chart.
Default settings are Length 21 and StdDev 1.618, based on the Fibonacci number (21) and the golden ratio (1.618).
Components
1. Bollinger Bands (Upper / Basis / Lower)
Defaults: Length 21, StdDev 1.618
Upper band, basis (middle), and lower band. The bands widen and narrow with volatility.
2. Basis Line Trend Color (Daily-based)
The color of the middle basis line indicates trend direction.
Logic: over a set lookback, it compares the cumulative size of the "close-to-lower" area (red) versus the "upper-to-close" area (green).
Red area dominant → uptrend → basis line GREEN
Green area dominant → downtrend → basis line RED
The longer the close stays near the lower band (larger red area), the more it is read as base-building before a move higher.
This color is always calculated from Daily data, regardless of the chart timeframe. Whether you view it on the 15m, 1h, or 4h chart, the daily trend color stays consistent.
3. Fill
Upper band ↔ close: semi-transparent green
Close ↔ lower band: semi-transparent red
Lets you quickly read where the close sits within the bands.
4. Band Width (%)
Formula: (Upper − Lower) / Basis × 100
Displays the current band width in a corner table as Band Width: X.XX%.
Lower = volatility contraction (squeeze) → often precedes a large move; higher = volatility expansion.
The Data Window also shows band width % and band width (price difference), including on historical bars.
5. Recent Lows
Weekly recent low = yellow box / Daily recent low = red box
Shows only the most recent pivot (swing) low that sits below the current close. (Lows above the close are skipped; if the latest low is above the close, the prior low is used instead.)
Box height spans the low ↔ the close at that point, and extends to the right to show a still-valid support/demand zone.
How to Read It
Basis green + close near the lower band → watch for a potential bounce after base-building.
Basis red + close near the upper band → watch for overextension/pullback risk.
Band Width % contracting (squeeze) → watch for an upcoming volatility expansion.
Recent low boxes (yellow/red) act as first support candidates on a pullback. A close below the box signals support failure.
Key Settings
Bollinger Bands: Source, Length (default 21), StdDev (default 1.618), Band Color / Width / Style
Basis Line: Show Basis, Basis Width, Ratio Length, Up / Down Color
Fill: Show Fill, Upper / Lower Fill Transparency
Band Width: Show Band Width %, Table Position, Text Size
Recent Lows: weekly/daily toggles, Pivot Length, Box Color
Tips
This is a supporting tool for reading trend direction + volatility + support zones together, not a standalone trade signal.
Reliability increases when the daily trend color and a recent low box line up in the same area.
Adjust StdDev and Ratio Length to fit each instrument's volatility.
Disclaimer
This indicator is for reference only and does not guarantee trading profits. All trading decisions and responsibility rest solely with the user. Indicator

Stochastic Histogram Regime [Gabremoku]Stochastic Histogram Regime is a refined Stochastic-based momentum oscillator that transforms classic %K / %D logic into a mid-centered histogram regime model with adaptive zones, squeeze detection, and sequential BUY/SELL signaling.
Instead of using the traditional 0–100 Stochastic layout alone, this script recenters the oscillator around its midline and highlights:
momentum expansion and recovery phases
adaptive extreme zones
K/D compression regimes
sequential crossover signals
squeeze-aware signal styling
a compact live dashboard
The Stochastic Oscillator measures where the current close sits relative to its recent price range, and its two core lines — %K and %D — are commonly used to spot momentum shifts, overbought/oversold conditions, and crossover signals.
What it shows
📊 Mid-centered stochastic histogram — instead of plotting Stochastic only in its standard form, the script centers the histogram around the 50 level so bullish and bearish pressure become easier to compare visually.
📈 %K line and ghost %D line — the main momentum line stays visually dominant, while %D acts as a softer confirmation layer.
🎯 Adaptive zones — rather than relying only on static 80/20 thresholds, the script calculates percentile-based extreme zones from recent Stochastic behavior. Traditional Stochastic readings above 80 are often considered overbought and readings below 20 oversold, but adaptive thresholds can better reflect changing market behavior.
🗜️ Combined squeeze regime — the script measures both:
compression around the midline
compression between %K and %D
This creates a composite squeeze state that helps identify low-momentum contraction phases before expansion.
🚦 Sequential BUY/SELL state machine — primary signals are filtered through K/D crossover logic, slope confirmation, and optional extreme-zone requirements.
🔺 Follow-up triangles — repeated same-direction confirmations after the first primary signal can be shown as lighter continuation markers.
🪧 Minimal dashboard — displays state, K/D values, adaptive zone range, slope, and squeeze status.
Core logic
The script is built around the idea that the Stochastic Oscillator is not just an overbought/oversold tool, but a momentum regime detector.
Classic Stochastic compares the latest close to the recent high-low range and is typically interpreted through:
%K and %D crossovers
movement around 80/20 zones
and changes in momentum before price fully reacts
Your script extends that by:
recentering the oscillator around 50
using histogram structure for directional emphasis
adapting extreme zones to recent behavior
and combining crossover quality with slope and squeeze context
This makes it more structured than a standard Stochastic display.
State model
The indicator classifies momentum into five readable states:
Bull Impulse
Bull Recovery
Bear Impulse
Bear Recovery
Neutral
This adds nuance to the usual Stochastic reading because it separates:
strong directional continuation
weaker recovery phases
and non-directional compression
In practice:
Bull Impulse suggests K is above D, above the mid-neutral area, and still rising
Bear Impulse suggests K is below D, below the mid-neutral area, and still falling
recovery states identify improving momentum before full expansion
Signal logic
The script uses a filtered signal engine based on %K / %D crossovers, which are among the most common Stochastic signals.
Primary BUY and SELL signals can be filtered by:
extreme zone location
K slope confirmation
signal mode: Aggressive, Balanced, or Strict
This helps reduce the classic problem of noisy Stochastic crossovers in sideways conditions. Stochastic crossovers are useful, but they generally become more meaningful when combined with trend or momentum context rather than taken in isolation.
How to read it
A practical reading method is:
Use the histogram around the midline to read directional pressure.
Use adaptive zones to identify statistically stretched momentum.
Use %K / %D crossovers for trigger logic.
Use the squeeze state to identify contraction before expansion.
Treat follow-up triangles as continuation confirmation, not as fresh primary entries.
In general:
positive histogram with rising K = improving bullish momentum
negative histogram with falling K = improving bearish momentum
squeeze ON = compressed momentum regime
BUY/SELL labels = primary filtered crossover signals
Features
✅ Mid-centered stochastic histogram
✅ %K and ghost %D structure
✅ Percentile-based adaptive extreme zones
✅ Neutral zone around the 50 midline
✅ Composite squeeze detection
✅ Sequential BUY / SELL state machine
✅ Optional follow-up continuation markers
✅ Overlay and pane signal display options
✅ Minimal live dashboard
✅ Alert conditions for BUY, SELL, and squeeze state
Notes
This indicator is designed to improve the readability of Stochastic momentum structure, especially in transitions between compression, recovery, and impulse phases. Like all Stochastic-based tools, it can produce noisy signals in choppy markets, and overbought/oversold readings should generally be interpreted as momentum context rather than automatic reversal calls.
Author: Gabremoku
Pine Script v6 Indicator

Artemis Squeeze Momentum🟦 Artemis Squeeze Momentum collapses an entire momentum-and-volatility workflow into a single oscillator pane. Eight analytical layers — Squeeze Momentum core, Directional Flux, three-tier compression detection with a release tracker, dual confluence gauges, dual anchor Regular + Hidden divergence with a Smart AI Filter, a composite Trend Strength Score (0–100), a four-timeframe MTF Confluence panel with alignment / divergence detection, and a theme-adaptive PRO dashboard — operate as one integrated system, all driven by a single theme dropdown across 12 cohesive palettes.
Most squeeze indicators ship as a strip of black-and-red dots with a lone momentum histogram, then require a separate ADX, a separate divergence tool and a separate confluence gauge to complete the read. Artemis Squeeze Momentum closes that gap: every compression tier, every directional cross, every divergence, every higher-timeframe bias reads from the same pane in the same colour language — no inline colour pickers, no palette drift, no pane-hopping. The result is a complete momentum workbench where compressions, breakouts, regime flips, divergences and multi-TF bias are all readable at a glance.
🟦 HOW THE CORE ENGINE WORKS
**Squeeze Momentum Engine**
Each bar, the engine builds three anchors over the Momentum Length window:
1. **Channel midpoint** — `(highest(high, len) + lowest(low, len)) / 2`
2. **Smoothed midline** — `SMA(HL2, len)`
3. **Channel ATR** — channel range plus the gap-to-prior-close component (matches Pine v5 `tr(true)` on the synthetic channel bar)
The raw momentum is then computed as:
mom_raw = (close − avg(channelMid, smaMid)) / channelATR × 100
This produces a channel-aware, ATR-normalized residual scaled to roughly the ±100 range. The result is then passed through `ta.linreg(mom_raw, len, 0)` to produce the visible momentum line — a linear-regression smoothing that gives the curve its characteristic forward-leaning shape. An SMA of length Signal Length builds the trigger line. Crossovers between momentum and signal mark momentum regime changes — the same convention used by classical MACD.
**Directional Flux**
A custom ADX-style oscillator running in parallel. Each bar, the engine measures positive high-changes vs. negative low-changes, each RMA-smoothed and ATR-normalized:
up = RMA(max(change(high), 0), len) / ATR(len)
dn = RMA(max(−change(low), 0), len) / ATR(len)
ratio = (up − dn) / (up + dn)
flux = RMA(ratio, len / 2) × 100
The result is a directional bias oscillator bounded to ±100. An overflow branch (values past ±25 — where the directional pressure becomes structurally significant) renders as a separate, brighter fill so traders read both raw direction and acceleration in one glance.
**Heiken Ashi Bias (Optional)**
When `Use Heiken Ashi Bias` is enabled, the Flux engine reads from a Heiken Ashi bar stream instead of raw OHLC. HA bars smooth body / wick noise and emphasise trend continuation — useful on lower timeframes where raw OHLC is noisy.
🟦 SQUEEZE DETECTION
A three-tier Bollinger-vs-ATR compression detector running on the same Length as the Momentum Core (so compression and momentum stay perfectly aligned):
| Tier | Condition | Visual |
|---|---|---|
| Tight | stdev < ATR × 0.5 | Deepest, most saturated theme tone |
| Mid | stdev < ATR × 0.75 | Middle-intensity theme tone |
| Loose | stdev < ATR × 1.0 | Lightest tier — broadest detection |
Tiers nest — tight implies mid implies loose. The bottom-of-pane squeeze column lights up whenever any tier is active and the colour escalates as compression tightens, using a theme-native ramp drawn from each palette's own colour family (so the column reads as part of the theme rather than an imported generic warning).
The standard deviation is computed via a single-pass Welford algorithm — numerically stable on long histories where naive sum-of-squares accumulators drift.
**♦ Squeeze Release Marker**
The signature feature of the engine. The bar after the loosest active tier (stdev < ATR × 1.0) finally drops off, a tiny ♦ diamond paints at the midline in the theme's vivid release accent — one step brighter and more saturated than the tight tier so the climax moment reads as the most luminous point in the squeeze cycle.
This is the canonical "spring uncoiled" moment: compression has fully ended, volatility expansion begins, breakout direction is about to reveal itself. Historically the highest-conviction breakout setup the squeeze model produces. Hovering on the marker surfaces:
- Current bar state (compression ended this bar)
- Meaning (volatility expansion incoming)
- Next steps (watch the next 1–5 bars, confirm with Momentum slope, cross-check Flux, prioritise MTF-aligned setups)
🟦 CONFLUENCE GAUGES
Two horizontal strips render at the top (Bull side, +70 to +75) and bottom (Bear side, −70 to −75) of the pane. Each strip lights up when momentum and flux agree on direction, with brightness reflecting the confluence tier:
| State | Condition | Opacity |
|---|---|---|
| Strong Bull | mom > 0 AND flux > 0 | Full |
| Weak Bull | mom > 0 OR flux > 0 | Half |
| Strong Bear | mom < 0 AND flux < 0 | Full |
| Weak Bear | mom < 0 OR flux < 0 | Half |
| Neutral | Neither side dominates | Transparent |
The display mode (Both / Bull / Bear / None) lets traders mute one half if they only trade one direction.
**Confluence Buy / Sell Triangles**
A separate signal layer rides outside the gauges. The detector fires only when momentum crosses its signal line WHILE in the opposite zone past the Signal Threshold AND with flux in the opposite direction (classic mean-reversion logic):
- **Buy ▲** (below bear gauge at −90) — `xMomUp AND momVal < −threshold AND fluxVal < 0`
- **Sell ▼** (above bull gauge at +85) — `xMomDn AND momVal > +threshold AND fluxVal > 0`
Each triangle pairs with an invisible label carrying a tooltip that lists current mom, signal, flux, the active threshold, and a one-line interpretation of the trigger. The Signal Threshold (default 40) is independent of the Divergence Sensitivity setting — the two engines need different thresholds (divergence wants permissive at 25 for pivot detection, confluence wants strict at 40 for deep mean-reversion triggers).
🟦 DIVERGENCE DETECTION
A cross-confirmed, dual-anchor detector that fires on signal-line crossovers (NOT on Pine pivots). Regular divergences signal exhaustion reversals, Hidden divergences signal trend continuation.
**Four divergence types:**
| Type | Price | Momentum | Signal |
|---|---|---|---|
| Regular Bull (D▲) | Lower Low | Higher Low | Potential reversal up |
| Regular Bear (D▼) | Higher High | Lower High | Potential reversal down |
| Hidden Bull (H▲) | Higher Low | Lower Low | Uptrend continuation |
| Hidden Bear (H▼) | Lower High | Higher High | Downtrend continuation |
Regular divergence uses solid lines; Hidden uses dashed lines — visually quieter to match the continuation signal's lower conviction tier. Labels (D▲ / D▼ / H▲ / H▼) each carry a tooltip-rich hover with price + momentum + meaning context.
**Dual-Anchor Logic**
The key engineering choice. Regular and Hidden divergences each maintain their own separate anchor pair:
- **Regular anchors** — stored only at extreme-zone crosses (|mom| > Sensitivity). Catches classical exhaustion reversals at deep extremes.
- **Hidden anchors** — stored at ANY signal-line cross, regardless of zone. Shallow pullbacks inside an established trend rarely push momentum past ±Sensitivity, so the Hidden detector must accept every cross to capture the classical "price HL + mom LL" / "price LH + mom HH" continuation pattern.
A detected divergence consumes its anchor (resets to na) so the next setup starts fresh.
**Smart Divergence Filter (AI)**
Optional pre-filter that rejects low-quality divergences before they render. Three independent gates:
1. **Min Momentum Swing** — minimum |momentum| difference between the two pivot momentum values (default: 10 units). Drops noise-level differences.
2. **Min Price Swing (%)** — minimum price swing between pivots as a percentage of the recent `Momentum Length × 4` high-low range (default: 0.3%). Drops divergences where price barely moved relative to recent volatility.
3. **Require Flux Confirmation** — Flux must agree with the divergence direction at the moment of detection (Bull div needs Flux > 0, Bear div needs Flux < 0). Filters out divergences that fire counter to the broader directional bias.
When the master toggle is OFF (default), all detected divergences render. When ON, only divergences that clear all three gates survive. The filter applies identically to chart rendering and alert conditions — no mismatch between visual and alert signals.
🟦 COMPOSITE TS SCORE (0–100)
A weighted blend of every analytical layer into a single RSI-style 0–100 reading. 50 is neutral, > 50 leans bull, < 50 leans bear.
| Component | Weight | Mapping |
|---|---|---|
| Momentum | 30% | mom value mapped from −100..+100 → 0..100 |
| Flux | 30% | flux value mapped the same way |
| Mom × Signal | 15% | 70 if mom > sig, else 30 (slope direction confirmation) |
| Confluence | 25% | 90 strong-bull / 65 weak-bull / 50 neutral / 35 weak-bear / 10 strong-bear |
The score is rounded to the nearest integer and labelled into five tiers in the dashboard: STRONG BULL (≥75) / BULL (≥60) / NEUTRAL (40–59) / BEAR (≥25) / STRONG BEAR (<25), each prefixed with a directional glyph (▲ ▼ ■). The tier label gives traders an executive summary at a glance — one row in the dashboard tells you what every other row collectively says.
🟦 MULTI-TIMEFRAME CONFLUENCE
A separate PRO panel that runs the full Momentum + Flux + Confluence stack on four higher timeframes simultaneously via `request.security()` and surfaces the overall alignment state. All MTF calls use `lookahead = barmerge.lookahead_off` — fully repaint-safe on every closed bar.
**Six Presets**
Pre-tuned four-timeframe packs matched to common trader profiles:
| Preset | TF 1 | TF 2 | TF 3 | TF 4 | Use case |
|---|---|---|---|---|---|
| Scalp | 1m | 5m | 15m | 1h | Fast scalper |
| Intraday | 5m | 15m | 1h | 4h | Day trader |
| Swing | 15m | 1h | 4h | 1D | Default — swing trader |
| Position | 1h | 4h | 1D | 1W | Position trader |
| Crypto | 5m | 15m | 1h | 4h | 24/7 markets |
| Forex | 15m | 1h | 4h | 1D | Session-based markets |
**Alignment Detection**
Each TF returns a bias tag (▲ STRONG / ▲ WEAK / ▼ STRONG / ▼ WEAK / ◈ NEUTRAL) and a direction code (+1 / 0 / −1). The header rolls up the four codes into one of three states:
- **▲▲▲▲ ALIGNED** — all four TFs bullish (highest-conviction long setup)
- **▼▼▼▼ ALIGNED** — all four TFs bearish (highest-conviction short setup)
- **◈ MIXED** — TFs disagree (no clean direction)
**Divergence Detection**
When the current chart's bias contradicts ≥ 3 of the 4 HTF biases (e.g., chart bullish but 3+ HTFs bearish), an MTF Divergence flag fires — a contrarian / counter-trend warning. Treat as a "current move may be a bull / bear trap" signal.
**Panel Style**
Direction is conveyed purely by the ▲ / ▼ glyphs in each row's tag — never by cell colour. Every cell uses a uniform `thBull` text colour matching the main Dashboard, so the two panels feel like one product across all twelve themes, light and dark alike.
🟦 BAR COLORING
Five mutually exclusive modes apply an oscillator-driven colour to every price bar on the chart:
| Mode | Behavior |
|---|---|
| None | Leave bars untouched (default) |
| Momentum | Bull when mom > 0, bear when mom < 0 |
| Flux | Bull when flux > 0, bear when flux < 0 |
| Squeeze | Theme-native ramp when compressed, neutral otherwise |
| Confluence | Strong / Weak / Neutral tiers via mom + flux agreement |
| Slope | Bull when mom > signal, bear when mom < signal |
Colours are pulled from the active theme — no per-mode color picker needed.
🟦 DASHBOARD
A compact 2-column, 8-row data panel renders on the last bar when enabled. Every value derives from variables already computed upstream, so the dashboard adds zero overhead until the final bar.
| Row | Left | Right |
|---|---|---|
| Header | Artemis Squeeze | ▲ STRONG BULL / ▲ WEAK BULL / ■ NEUTRAL / ▼ WEAK BEAR / ▼ STRONG BEAR |
| TS Score | TS Score | 0–100 composite + tier label (STRONG BULL / BULL / NEUTRAL / BEAR / STRONG BEAR) |
| Momentum | Momentum | Current value + trend arrow (▲ ▼ ■) |
| Flux | Flux | Current value + trend arrow (▲ ▼ ■) |
| Squeeze | Squeeze | TIGHT / MID / LOOSE / — |
| Confluence | Confluence | STRONG BULL / WEAK BULL / NONE / WEAK BEAR / STRONG BEAR |
| Div | Div | Most recent divergence within last 50 bars (▲ REG / ▼ REG / ▲ HID / ▼ HID / —) |
| Slope | Slope | ▲ UP / ▼ DOWN / ■ FLAT |
**Theme-Adaptive Chrome**
The dashboard auto-inverts its layout based on the active theme:
- **Dark themes** (Tropic, Amber, Pastel, Cyber, Helios, Electric, Candy, Bloomberg, Solar, Royal): header and footer use a faint `thBull` tint, middle rows stay solid dark, text uses full-saturation `thBull`. Border uses `thBull` at 20% transparency for strong theme presence.
- **Light themes** (Midnight, Graphite): backgrounds flip to white, text stays `thBull` (which is itself dark on these themes), border uses `thBull` at 40% transparency.
This guarantees text legibility against every palette without per-theme manual tuning. The MTF Confluence panel uses identical chrome rules so the two panels feel like one product.
**Position & Size**
Six anchor slots (Top / Middle / Bottom × Left / Right) and four text sizes (Tiny / Small / Normal / Large). The Dashboard defaults to Bottom Right and the MTF panel to Top Right — vertically opposite so the two never overlap.
🟦 COLOR THEMES
Twelve cohesive palettes, each resolving to four axis colours plus a four-step squeeze ramp:
| Theme | Character | Bull | Bear |
|---|---|---|---|
| Tropic | Cyan steel + deep orange | #00bcd4 | #ff6d00 |
| Amber | Warm amber + ember red | #ff9800 | #e53935 |
| Pastel | Sky blue + soft lavender | #4fc3f7 | #9575cd |
| Cyber | Neon lime + hot crimson | #00e676 | #ff1744 |
| Helios | Bright gold + scarlet | #ffd600 | #ef5350 |
| Electric | Electric aqua + magenta | #00e5ff | #e040fb |
| Candy | Neon green + hot pink | #69F0AE | #FF4081 |
| Bloomberg | Terminal orange + cyan | #ff8c00 | #00b0ff |
| Solar | Solarized olive + crimson | #859900 | #dc322f |
| Royal | Imperial gold + deep purple | #ffd700 | #6a0dad |
| Midnight | Deep navy + dark crimson | #0d47a1 | #b71c1c |
| Graphite | Near-black + silver grey | #1a1a1a | #757575 |
Beyond the four axis colours (bull / bear / neutral / signal), each theme also defines its own four-step squeeze ramp (tight / mid / loose / release) drawn from its own colour family — so the squeeze column and the ♦ release marker harmonise with the active theme rather than imposing a generic warning hue. Nothing below the theme resolver block references a raw hex literal, so a single dropdown selection drives every plot, fill, gauge, divergence line, dashboard cell, MTF panel and bar colour.
🟦 ALERT SYSTEM
Twenty-two alert conditions, all using `alert.freq_once_per_bar_close`. Each alert is gated by its own toggle in the Alerts group — hiding a feature on the chart silences its alerts automatically.
| Alert | Condition |
|---|---|
| Confluence Buy | Mom crossed UP through signal while below −Threshold AND Flux bearish |
| Confluence Sell | Mom crossed DOWN through signal while above +Threshold AND Flux bullish |
| Momentum Cross Up | Mom crossed above zero |
| Momentum Cross Down | Mom crossed below zero |
| Flux Cross Up | Flux crossed above zero |
| Flux Cross Down | Flux crossed below zero |
| Bullish Swing | Mom × signal upward cross (any zone) |
| Bearish Swing | Mom × signal downward cross (any zone) |
| Strong Bull Confluence | Mom AND flux both turned bullish |
| Strong Bear Confluence | Mom AND flux both turned bearish |
| Weak Bull Confluence | Mom OR flux turned bullish |
| Weak Bear Confluence | Mom OR flux turned bearish |
| Tight Squeeze | stdev < ATR × 0.5 |
| Mid Squeeze | stdev < ATR × 0.75 |
| Loose Squeeze | stdev < ATR × 1.0 |
| Regular Divergence | D▲ or D▼ detected (respects Smart Filter) |
| Hidden Divergence | H▲ or H▼ detected (respects Smart Filter) |
| Squeeze Release ♦ | stdev re-expanded above ATR × 1.0 |
| MTF Aligned | All four MTF timeframes agree on direction |
| MTF Divergence | Current chart bias contradicts ≥ 3 of 4 HTF biases |
Each alert fires through `alert()` so the message body carries live context — direction, current values, the trigger condition, and a one-line interpretation. Divergence alerts respect the Smart Filter — if the filter is ON and a divergence is rejected visually, the alert will also not fire.
🟦 SETTINGS REFERENCE
**Visual**
- Theme — 12 cohesive palettes. Default: Tropic
**Bar Coloring**
- Bar Color Mode — None / Momentum / Flux / Squeeze / Confluence / Slope. Default: None
**Momentum Core**
- Length — Lookback for both the Momentum engine and the Squeeze window. Range 7–50. Default: 20
- Signal Length — SMA smoothing for the signal line. Range 2–7. Default: 3
- Show Momentum — Toggle. Default: ON
**Directional Flux**
- Length — Lookback for the Flux engine. Range 7–50. Default: 30
- Use Heiken Ashi Bias — Toggle. Default: OFF
- Show Flux — Toggle. Default: ON
**Squeeze Engine**
- Show Squeeze — Toggle. Default: ON
- Show Squeeze Release — Toggle for the ♦ marker. Default: ON
**Confluence Gauges**
- Display Mode — Both / Bull / Bear / None. Default: Both
- Signal Threshold — |momentum| floor for Buy ▲ / Sell ▼ arrows. Range 10–80. Default: 40
**Divergence**
- Sensitivity — |momentum| floor for Regular div detection. Range 10–50. Default: 25
- Regular Divergence — Toggle. Default: ON
- Hidden Divergence — Toggle. Default: ON
- Show Divergence Lines — Toggle. Default: ON
- Show Divergence Labels — Toggle. Default: ON
- Label Size — Tiny / Small / Normal / Large. Default: Tiny
- Smart Divergence Filter (AI) — Master toggle. Default: OFF
- Min Momentum Swing — Default: 10.0
- Min Price Swing (%) — Default: 0.3%
- Require Flux Confirmation — Default: ON
**Multi-Timeframe**
- Show MTF Panel — Toggle. Default: ON
- Timeframe Preset — Scalp / Intraday / Swing / Position / Crypto / Forex. Default: Swing
- Panel Position — 6 anchor slots. Default: Top Right
- Panel Text Size — Tiny / Small / Normal / Large. Default: Small
**Dashboard**
- Show Dashboard — Toggle. Default: ON
- Panel Position — 6 anchor slots. Default: Bottom Right
- Panel Text Size — Tiny / Small / Normal / Large. Default: Small
**Alerts**
- 20 toggles covering all 22 alert conditions (Regular and Hidden divergence each drive two alerts — bull + bear — from one toggle).
- Defaults ON: Confluence Buy/Sell, Mom Cross Up/Dn, Flux Cross Up/Dn, Strong Bull/Bear Confluence, Tight Squeeze, Regular Divergence, Squeeze Release, MTF Aligned.
- Defaults OFF: Swings, Weak Confluences, Mid/Loose Squeeze, Hidden Divergence, MTF Divergence.
🟦 COMPATIBILITY
Works on all asset classes and all timeframes in PulseWire Pine Script v6.
- Crypto: Spot, futures, perpetual contracts
- Forex: All pairs
- Equities: Stocks, ETFs, indices
- Commodities: Metals, energy, agriculture
- Timeframes: 1m through Monthly
The channel-aware ATR normalization in the Momentum engine, the ATR-normalized Flux ratio, and the stdev / ATR squeeze tests make every layer volatility-agnostic. The same default settings work on a 1m BTC chart and a weekly index chart without retuning. The MTF presets cover the common scalp / intraday / swing / position profiles plus dedicated Crypto and Forex packs.
🟦 DISCLAIMER
This indicator is provided for educational and informational purposes only. It does not constitute financial advice. Past performance does not guarantee future results. Always conduct your own analysis and apply proper risk management. Indicator
