OPEN-SOURCE SCRIPT
Actualizado SPY Breadth Buy Signal

This indicator identifies potential reversal opportunities in SPY by combining five key market conditions into a composite buy signal. It's designed for swing traders and position traders looking to catch relief rallies during oversold conditions.
Key Features:
🎯 Five-Condition Buy Filter:
Volume confirmation (≥150M shares)
VIX elevated (≥30) indicating fear in the market
Market breadth oversold (≤30% of S&P 500 stocks above 50-day SMA)
RSI oversold (≤30)
Slow Stochastic in extreme territory (<20)
The signal triggers when 4 out of 5 conditions are met—providing a balance between sensitivity and false-signal reduction.
How It Works:
Volume - Ensures SPY has institutional participation
VIX - Confirms market-wide volatility spikes (fear gauge)
Breadth - Detects when fewer than 30% of S&P 500 stocks trade above their 50-day moving average (extreme oversold)
RSI - Individual momentum indicator on SPY
Slow Stochastic - Smoothed stochastic %K for momentum confirmation
Display Elements:
Green upward triangle below the bar on signal confirmation
"BUY" label with green background highlight
Debug panel (top-right) showing real-time condition status and count
Customizable Inputs:
Adjust thresholds for all five conditions
Set minimum required conditions (1-5)
Toggle debug panel on/off
Select breadth index (MMFI, S5FI, SPXA50R)
Best Used With:
Daily timeframe (optimal)
As a filter/confirmation tool, not a standalone system
Combine with your own risk management and entry/exit rules
Key Features:
🎯 Five-Condition Buy Filter:
Volume confirmation (≥150M shares)
VIX elevated (≥30) indicating fear in the market
Market breadth oversold (≤30% of S&P 500 stocks above 50-day SMA)
RSI oversold (≤30)
Slow Stochastic in extreme territory (<20)
The signal triggers when 4 out of 5 conditions are met—providing a balance between sensitivity and false-signal reduction.
How It Works:
Volume - Ensures SPY has institutional participation
VIX - Confirms market-wide volatility spikes (fear gauge)
Breadth - Detects when fewer than 30% of S&P 500 stocks trade above their 50-day moving average (extreme oversold)
RSI - Individual momentum indicator on SPY
Slow Stochastic - Smoothed stochastic %K for momentum confirmation
Display Elements:
Green upward triangle below the bar on signal confirmation
"BUY" label with green background highlight
Debug panel (top-right) showing real-time condition status and count
Customizable Inputs:
Adjust thresholds for all five conditions
Set minimum required conditions (1-5)
Toggle debug panel on/off
Select breadth index (MMFI, S5FI, SPXA50R)
Best Used With:
Daily timeframe (optimal)
As a filter/confirmation tool, not a standalone system
Combine with your own risk management and entry/exit rules
Notas de prensa
minor update removing SPXA50RScript de código abierto
Fiel al espíritu de TradingView, el creador de este script lo ha convertido en código abierto, para que los traders puedan revisar y verificar su funcionalidad. ¡Enhorabuena al autor! Aunque puede utilizarlo de forma gratuita, recuerde que cualquier republicación del código está sujeta a nuestras Normas internas.
Exención de responsabilidad
La información y las publicaciones no constituyen, ni deben considerarse como, asesoramiento o recomendaciones financieras, de inversión, de trading u otro tipo, proporcionadas o respaldadas por TradingView. Obtenga más información en Condiciones de uso.
Script de código abierto
Fiel al espíritu de TradingView, el creador de este script lo ha convertido en código abierto, para que los traders puedan revisar y verificar su funcionalidad. ¡Enhorabuena al autor! Aunque puede utilizarlo de forma gratuita, recuerde que cualquier republicación del código está sujeta a nuestras Normas internas.
Exención de responsabilidad
La información y las publicaciones no constituyen, ni deben considerarse como, asesoramiento o recomendaciones financieras, de inversión, de trading u otro tipo, proporcionadas o respaldadas por TradingView. Obtenga más información en Condiciones de uso.