OPEN-SOURCE SCRIPT

Squeeze Momentum Oscillator

54
Title: Squeeze Momentum Oscillator

Description: This indicator is a panel-based oscillator that separates market momentum from volatility, designed to spot high-probability breakouts using the classic TTM Squeeze logic.

How It Works: The indicator uses a "traffic light" system on the zero line to indicate volatility states, while the histogram shows the strength and direction of the trend.

1. The Dots (Volatility State): These dots tell you if the market is consolidating or trending.

🔴 Red Dot: Squeeze is ON. Bollinger Bands are inside Keltner Channels. Volatility is compressed. Do not trade; wait for the release.

🟢 Green Dot: Squeeze is OFF. Volatility is normal.

🟣 Fuchsia Dot: Bullish Breakout! The squeeze has fired to the upside and is confirmed by positive SMA momentum.

🔵 Blue Dot: Bearish Breakout! The squeeze has fired to the downside and is confirmed by negative SMA momentum.

2. The Histogram (Momentum): This measures the strength of the move using Linear Regression.

Light Green: Bullish momentum is increasing.

Dark Green: Bullish momentum is waning (caution).

Light Red: Bearish momentum is increasing.

Dark Red: Bearish momentum is waning (caution).

Settings & Features:

Momentum Filter: Breakout dots (Fuchsia/Blue) only appear if the 20-period SMA slope agrees with the breakout direction, filtering out weak fakeouts.

Customizable: Adjust lengths and multipliers for Bollinger Bands and Keltner Channels to tune sensitivity.

Toggle: You can turn the specific "Breakout Colors" on or off in the settings.

Credits: Based on the TTM Squeeze concept popularized by John Carter, utilizing Linear Regression for momentum and standard deviation/ATR comparisons for volatility. Fixed and optimized for TradingView Pine Script v6.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.