OPEN-SOURCE SCRIPT

RealVardi - SMT Divergence - NQ vs ES

831
SMT Divergence — NQ vs ES
This indicator detects Smart Money Technique (SMT) divergences between Nasdaq (NQ) and S&P 500 (ES) futures — a concept popularized in ICT methodology. When two correlated instruments stop moving in sync at key swing points, it often signals that institutional order flow is shifting, providing early clues about potential reversals.
How It Works
The indicator identifies confirmed swing highs and swing lows on both NQ and ES using a user-defined lookback period. It then compares consecutive pivots across both instruments to detect divergences:

Bearish SMT — NQ prints a higher high while ES prints a lower high. This failure by ES to confirm NQ's new high suggests weakness and a potential move down.
Bullish SMT — NQ prints a lower low while ES prints a higher low. This failure by ES to confirm NQ's new low suggests strength and a potential move up.

A proximity filter ensures that only swing points occurring within a reasonable window of each other are compared, keeping signals relevant.
Features

Works on any timeframe
Optional Higher Timeframe (HTF) bias filter — only show bullish signals when the HTF candle is bullish, and bearish signals when bearish, to trade in the direction of the larger trend
Customizable swing lookback length to tune sensitivity
Toggle bullish and bearish signals independently
Built-in alert conditions for all signal types
Labels are time-anchored so they stay fixed when scrolling

Inputs

ES Symbol — the correlated pair to compare against (default: ES1!)
Swing Lookback Length — number of bars on each side to confirm a pivot (default: 10)
HTF Filter — optional higher timeframe candle direction filter
Colors & Label Size — fully customizable appearance

How To Use
SMT divergences are most effective when combined with other confluence factors such as liquidity sweeps, order blocks, fair value gaps, or key support/resistance levels. Use them as confirmation rather than standalone entry signals. The HTF filter can help reduce noise by aligning signals with the broader market direction.
Default Pair: NQ vs ES — You can change the comparison symbol in the settings to explore divergences between other correlated instruments.

免責聲明

這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。