OPEN-SOURCE SCRIPT
업데이트됨

SMC Elemental

973
What does this indicator do?

SMC Elemental detects three core Smart Money structures on your chart: Fair Value Gap (FVG), Liquidity Sweep, and Order Block (OB). Each element is independently filtered for quality using ATR, so only significant structures appear — not every tiny gap or wick.


How does each element work?

Fair Value Gap (FVG)
A three-candle imbalance where price moved so fast it left an unfilled gap:
- Bullish FVG: candle[2].high < candle[0].low — gap up (demand zone)
- Bearish FVG: candle[2].low > candle[0].high — gap down (supply zone)
- Quality filter: gap size must be >= ATR x configurable multiplier (default 0.3x)
- Auto-fill detection: when price closes back into the gap zone, the box stops extending and switches to a dashed border

Liquidity Sweep
A stop-hunt pattern where price wicks beyond a swing level then closes back:
- Swing highs/lows are detected using ta.pivothigh / ta.pivotlow with configurable lookback (default 10 bars, confirmed — no repaint)
- Bearish sweep: high > swing high AND close < swing high (wick grabbed buy stops, then reversed)
- Bullish sweep: low < swing low AND close > swing low (wick grabbed sell stops, then reversed)
- Quality filter: wick length >= body x configurable ratio (default 1.5x) — filters out weak wicks and doji bars (body < ATR x 0.05 excluded)

Order Block (OB)
The last opposing candle before a strong impulse move — marks institutional entry zones:
- Bullish OB: bearish candle[1] followed by bullish candle[0] where |body[0]| >= ATR x multiplier (default 1.5x)
- Bearish OB: bullish candle[1] followed by bearish candle[0] with same impulse filter
- The OB box covers the full range (high to low) of the pre-impulse candle
- Mitigation: when price closes inside the OB zone, the box stops extending and fades — the zone has been "used up"


Why combine these three?

These aren't just mashed together — they represent the three stages of how institutional order flow typically works:

1. Order Block = where institutions placed their orders (cause)
2. Fair Value Gap = the imbalance their orders created (effect)
3. Liquidity Sweep = the stop hunt that fuels the next move (trigger)

When a Sweep occurs near an unfilled FVG or active OB, it provides much stronger confluence than any single element alone. This indicator lets you visually spot these overlaps without adding three separate scripts.


How to use it?

- FVG zones extend right until filled — watch for price to return and react at unfilled zones
- Sweep labels mark potential reversal points — especially powerful near OB/FVG zones
- OB zones extend right until mitigated — these are potential bounce/rejection areas
- Toggle each element on/off independently via settings
- Adjust ATR multipliers to tune sensitivity for your timeframe and market


What makes it different from other SMC indicators?

1. ATR-adaptive filters on every element — not just raw detection
2. Auto-cleanup: filled FVGs and mitigated OBs automatically fade (dashed border) and stop extending — your chart stays clean over time
3. Configurable max counts: limit active zones per element to prevent chart clutter
4. All colors defined as constants at the top of the source — easy to restyle in one place
5. No repaint: all logic gated by barstate.isconfirmed and pivot confirmation


Settings explained

ATR Length (default 14) — Base period for all quality filters
FVG Min Size x ATR (default 0.3) — Minimum gap size to qualify as FVG
Max Active FVGs (default 5) — Oldest auto-deleted when exceeded
Pivot Lookback (default 10) — Bars left+right for swing detection
Min Wick/Body (default 1.5) — Sweep wick quality threshold
Max Sweeps (default 3) — Recent sweep labels kept on chart
OB Impulse x ATR (default 1.5) — Minimum impulse strength for OB
Max Active OBs (default 3) — Oldest auto-deleted when exceeded


Disclaimer

This is a visualization tool — not a trading strategy. No backtesting has been performed. I built it for my own manual trading to identify key SMC zones at a glance. Currently testing it live. Use at your own discretion.
릴리즈 노트
Update: Footprint Order Flow Confirmation

This update integrates Pine Script v6's new request.footprint() to add real volume delta confirmation on every detected zone.


What changed?

Each FVG, Sweep, and Order Block is now cross-checked against actual buy/sell volume delta at the time of formation. If the delta direction aligns with the expected direction, the zone appears with stronger visual emphasis.


What you see on chart:

Confirmed zones (footprint delta supports the structure):
- FVG/OB: thicker border (2px) + stronger color
- Sweep: label shows "Sweep ✓" with brighter color

Unconfirmed zones (no footprint data, or delta contradicts):
- FVG/OB: thinner border (1px) + faded color
- Sweep: label shows "Sweep" in softer color


Confirmation logic:

- Bullish FVG/OB: confirmed when volume delta > 0 (net buying pressure)
- Bearish FVG/OB: confirmed when volume delta < 0 (net selling pressure)
- Bullish Sweep: confirmed when delta > 0 after wick below swing low (reversal flow)
- Bearish Sweep: confirmed when delta < 0 after wick above swing high (reversal flow)


Important notes:

- Requires TradingView Premium or Ultimate plan for footprint data
- Without Premium/Ultimate, the indicator works exactly as before — all zones show in the default style, nothing breaks
- Confirmation is an additional filter, not a guarantee — it means the volume flow at formation was directionally aligned
- A new "Footprint Tick Size" setting controls price granularity for footprint rows (default 100)


New setting:

Footprint Tick Size (default 100) — Price granularity for footprint data rows. Smaller = more detail, larger = smoother. Only active with Premium/Ultimate plans.

면책사항

해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.