OPEN-SOURCE SCRIPT
Pivot Squeeze Indicator

The Pivot Squeeze Indicator is an oscillator that identifies when markets are "squeezed" between recent pivot highs and lows, then signals when they're ready to make their next big move.
How it Works
The indicator calculates the percentage distance between the current price and the most recent pivot high vs. pivot low. When this distance gets compressed (small), the market is "squeezed" and building energy. When it expands rapidly, you get your breakout signal.
The indicator adapts to current market volatility using four different modes:
- ATR-Based
- Bollinger Bands
- Keltner Channels
- Fixed %
What to Look For
🟠 Orange Background = Squeeze Zone
Market is compressed between recent pivots
Low volatility, building pressure
🟢 Green Breakout = Bullish Signal
Price breaking out above recent highs
Momentum shifting upward
Time to look for long opportunities
🔴 Red Breakout = Bearish Signal
Price breaking down below recent lows
Momentum shifting downward
Time to look for short opportunities
Using Histogram Colors:
Green bars = Bullish territory (closer to recent highs)
Red bars = Bearish territory (closer to recent lows)
Orange bars = Squeeze conditions (compressed between pivots)
Using MA Line:
When Histogram bars cross below or above MA Line in opposite direction, it might be good time to exit.
Default Settings: ATR-based thresholds with 14-period lookback - works great out of the box, but feel free to experiment with the different threshold modes to find what works best for your trading style! Recommended to use with other indicators to confirm signals
How it Works
The indicator calculates the percentage distance between the current price and the most recent pivot high vs. pivot low. When this distance gets compressed (small), the market is "squeezed" and building energy. When it expands rapidly, you get your breakout signal.
The indicator adapts to current market volatility using four different modes:
- ATR-Based
- Bollinger Bands
- Keltner Channels
- Fixed %
What to Look For
🟠 Orange Background = Squeeze Zone
Market is compressed between recent pivots
Low volatility, building pressure
🟢 Green Breakout = Bullish Signal
Price breaking out above recent highs
Momentum shifting upward
Time to look for long opportunities
🔴 Red Breakout = Bearish Signal
Price breaking down below recent lows
Momentum shifting downward
Time to look for short opportunities
Using Histogram Colors:
Green bars = Bullish territory (closer to recent highs)
Red bars = Bearish territory (closer to recent lows)
Orange bars = Squeeze conditions (compressed between pivots)
Using MA Line:
When Histogram bars cross below or above MA Line in opposite direction, it might be good time to exit.
Default Settings: ATR-based thresholds with 14-period lookback - works great out of the box, but feel free to experiment with the different threshold modes to find what works best for your trading style! Recommended to use with other indicators to confirm signals
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。