Squeeze Momentum 3D [NeBlok]

1 034
SQUEEZE MOMENTUM 3D [NeBlok]

Squeeze Momentum 3D finds periods when the market is coiling (volatility compressing) and then tells you when that energy releases and in which direction. It combines a three-tier squeeze engine, ATR-normalized momentum, graded breakout signals, compression boxes on the price chart, an EMA trend overlay, and an extruded 3D histogram.

Concept credit: The "Bollinger Bands inside Keltner Channels" squeeze idea comes from John Carter's TTM Squeeze. This script is written from scratch, and the tiering, ATR normalization, signal grading, compression boxes, trend overlay, dashboard and 3D rendering are original to this version.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HOW IT WORKS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

1) The Squeeze Engine
The script compares the width of the Bollinger Bands to the width of the Keltner Channels. When the Bollinger Bands contract inside the Keltner Channels, volatility is compressed and the market is "in a squeeze." Instead of a simple on/off reading, compression is graded into three tiers:

- HIGH compression (amber dots): the tightest squeezes. Bollinger width is inside 1.0x the Keltner range.
- MID compression (red dots): a standard squeeze. Inside 1.5x.
- LOW compression (gray dots): early or mild compression. Inside 2.0x.
- NO squeeze (green dots): volatility is expanding.

The dots run along the zero line of the indicator pane. You choose which tier counts as "in squeeze" (default: Mid).

2) Momentum
The histogram measures how far price has moved from its equilibrium, defined as a blend of the recent high/low midpoint and an EMA. That distance is smoothed with a linear regression. By default, momentum is divided by ATR, so the readings are expressed in ATR units. A reading of 1.5 means roughly the same thing on MES, NQ, QQQ, BTC or any other symbol.

Histogram colors:
- Bright cyan: bullish momentum and rising
- Dark teal: bullish momentum but fading
- Bright magenta: bearish momentum and falling
- Dark magenta: bearish momentum but fading

Color intensity scales with the strength of the reading relative to the last 100 bars, so the strongest pushes stand out.

3) Fire Signals
A "fire" happens when a qualified squeeze (one that lasted at least the minimum number of bars, default 6) releases. The direction comes from the momentum reading at the moment of release. Each fire is graded:

- SQZ A (large label): momentum direction, momentum slope and the EMA trend all agree. This is the higher-quality signal.
- B (small triangle): the squeeze released, but not everything is aligned. Treat it as a heads-up, not a trigger.

Squeezes that release before the minimum bar count are ignored. They produce no signal and no box.

4) Compression Boxes
On the price chart, each qualified squeeze is outlined with a dashed box showing the high and low of the coil, labeled with how many bars it lasted. The box's color reflects the squeeze tier. These ranges give you natural reference levels: a breakout that holds outside the box confirms the release, and a quick return inside it is a warning sign.

5) EMA Trend Overlay
A fast EMA (9) and slow EMA (21) are drawn on the price chart. A "+" marks each cross: green for bullish, red for bearish. The EMA relationship is also used to grade fire signals.

6) Dashboard
A compact table shows the current squeeze tier, bars spent in the squeeze, the BB/KC ratio (lower = tighter), momentum value and direction, EMA trend, and the most recent fire with how many bars ago it happened.

7) 3D Histogram
The most recent bars are drawn as extruded 3D prisms. Bullish bars cap on top and bearish bars cap on the bottom, so bars always extrude away from zero. Because TradingView limits the number of drawing objects per script, 3D rendering applies to the most recent 100 bars by default (up to 120). Older bars display as standard flat columns. 3D can be turned off in the settings.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
HOW TO USE IT
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Step 1: Watch for the coil.
When the dots turn red or amber, the market is compressing. Longer squeezes and higher tiers tend to precede larger moves. The compression box shows you the range that is building.

Step 2: Read the momentum while in the squeeze.
Momentum often starts leaning one way before the release. A histogram that is rising toward or above zero while in a squeeze suggests the break may come to the upside, and vice versa.

Step 3: Act on the release, not the squeeze.
The squeeze tells you something is building. The fire tells you it has started. SQZ A signals have full alignment. B signals deserve extra confirmation.

Step 4: Use the box for structure.
Many traders place stops back inside or beyond the opposite side of the compression box and watch for price to hold outside the range after the fire.

Step 5: Manage the trade with momentum.
When the histogram shifts from the bright color to the fading color, momentum is slowing. That is a common place to tighten stops or take partial profits.

Tips
- Signals are confirmed on bar close. On the live (unclosed) bar, the squeeze tier and signals can change until the bar closes. Historical signals do not repaint.
- Checking a higher timeframe for direction and using this indicator on a lower timeframe for timing can help filter out weaker signals.
- Tighter markets or faster timeframes may benefit from a higher minimum bar count. Slower markets may need a lower one.
- Pair the signals with your own risk management. No indicator works on its own.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SETTINGS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Squeeze Engine: Length, Bollinger standard deviation, Keltner multipliers for each tier, the minimum tier counted as a squeeze, and the minimum bars required before a fire counts.

Momentum: Momentum length, ATR normalization on/off, ATR length, and an optional momentum wave line.

Trend Overlay: Fast and slow EMA lengths, cross markers, and whether A-grade signals require EMA trend alignment.

Price Chart Visuals: Compression boxes, fire signals, optional squeeze shading on the price chart, and optional candle coloring by momentum.

3D Histogram: 3D on/off, number of 3D bars, bar face width, and horizontal and vertical depth. Keep face width plus horizontal depth under 1.0 so neighboring bars don't overlap.

Colors & Dashboard: Every color is customizable, and the dashboard can be moved to any corner or hidden.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
ALERTS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Enable the alert types you want in the settings (Squeeze Fire, Squeeze ON, EMA Cross). Then create an alert on this indicator and choose "Any alert() function call." All alerts trigger once per bar close and include the ticker, signal type, grade, squeeze length and closing price.

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
DISCLAIMER
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

This script is provided for educational and informational purposes only. It is not financial, investment or trading advice, and it is not a recommendation to buy or sell any security, futures contract, cryptocurrency or other financial instrument.

Trading involves substantial risk of loss and is not suitable for every investor. Past performance of any signal, pattern or indicator does not guarantee future results. Squeeze signals can and do fail, and markets can move against any position.

You are solely responsible for your own trading decisions. Always do your own research, test any tool before using it with real capital, and consider consulting a licensed financial professional. The author accepts no liability for any losses resulting from the use of this script.

Clause de non-responsabilité

Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.