PROTECTED SOURCE SCRIPT
Mis à jour

Elliott Wave - Wave 3 Entry Engine

51
This indicator is a Wave 3 entry engine built on top of an Elliott Wave–style 1-2-3 structure. It automatically finds potential Wave 3 trades, manages a simple R-multiple target/stop model, and marks outcomes directly on the chart.

What the indicator does

At a high level, the script:

  • Detects swing points on three “degrees”
  • Small (S) – fast, local swings
  • Medium (M) – broader swings
  • Large (L) – higher-timeframe context only
  • Looks for a 3-pivot pattern (W0 → W1 → W2)
  • Bullish setup: Low → High → Higher Low (L-H-L)
  • Bearish setup: High → Low → Lower High (H-L-H)
  • Checks whether that pattern is a valid Wave 1–2 structure


Using multiple rules:

  • Wave 2 retraces Wave 1 by a configurable fraction
  • Wave 1 is strong enough (percentage move + slope)
  • Wave 2 doesn’t overshoot Wave 0 too far
  • Trend direction and swing “consensus” across S/M/L degrees line up
  • Scores the setup (Pre-W3 Score)


The script calculates a 0–1 score based on:

  • How “nice” the Wave 2 retracement is vs the ideal level
  • How much stronger Wave 1’s slope is vs Wave 2’s pullback
  • How much consensus there is across the swing engine (S/M/L)
  • Only setups above your chosen minimum Pre-W3 score and that pass alignment checks become Wave 3 candidates.
  • Waits for breakout → creates a Wave 3 “entry”
  • For longs: price breaks above the Wave 1 high (plus an optional tick buffer)
  • For shorts: price breaks below the Wave 1 low (minus buffer)


When triggered, the indicator:

  • Stores entry price (close at breakout)
  • Sets a stop beyond Wave 2 (with optional extra ticks)
  • Calculates a target based on a fixed R multiple (e.g., 2R)
  • Tracks the trade until exit or timeout


For each open W3 trade, it monitors:

  • Target hit → marks “W3 ✅”
  • Stop hit → marks “W3 ❌”
  • Bar where both could have hit → conservative loss “W3 ?/❌”
  • Time-based expiry (too many bars in trade) → “W3 ⏰”
  • Candidates that never get a breakout within your chosen max bars from W2 can also be marked as timeout (⏰).



Visual elements on the chart


The script can plot several helpful visuals:

  • Swing connector lines (Small/Medium/Large)
  • Small = blue
  • Medium = purple
  • Large = orange
  • These show the detected swings at each degree
  • Pre-W3 labels at Wave 2 (optional)


Signals :
  • "Pre-W3 Long XX%" or"Pre-W3 Short XX%"
  • Placed at the Wave 2 pivot
  • Colored yellow, with the % score rounded to an integer
  • W3 Entry labels (optional)
  • "W3 Long Entry" below the bar for longs (green)
  • "W3 Short Entry" above the bar for shorts (red)
  • Outcome labels (optional)
  • W3 ✅ – target hit
  • W3 ❌ – stop hit
  • W3 ?/❌ – both hit on same bar, treated as loss
  • W3 ⏰ – candidate or trade timed out



All these can be toggled in the “Wave 3 Engine (Pre-W3 + Entries + Outcomes)” group.

Input groups & how to use them

  • Swing Detection (Small / Medium / Large)
  • These groups control how the script finds swing highs/lows using a multi-parameter pivot scan:
  • Left Min / Left Max / Right Min / Right Max
  • Define the pivot “strength” ranges (how many bars to the left/right the high/low must dominate).
  • Minimum swing % (post-aggregation)
  • Ensures that, once swings are merged and cleaned up, each swing is at least this % move from the prior opposite swing.
  • Loop Filters (Small/Medium/Large loop min % change)
  • Extra gating inside the pivot-search loop, so small noise pivots can be ignored even before final swing construction.


Practical use:

  • Tighten % thresholds or increase left/right bars to reduce noise.
  • Loosen them to get more swings and more potential W3 setups.
  • Wave 3 Logic
  • Wave 2 depth
  • W2 min / max retracement of W1 (fraction)
  • Example: 0.30–0.80 means W2 must retrace 30–80% of W1.
  • Ideal W2 retracement (for scoring)
  • Often set around 0.618 (classic fib). The closer W2 is to this, the higher the retracement part of the score.
  • Max W2 beyond W0 (%)
  • How far W2 may push past W0 (in %) before the setup is invalid. Set to 0 to disable this filter.
  • Wave 1 strength
  • Min W1 move (%)
  • Ensures Wave 1 itself is meaningful.
  • Min |W1 slope| / |W2 slope|
  • Wave 1 must be “steeper” than Wave 2’s correction.
  • Slope ratio for max score
  • Above this, extra slope advantage doesn’t improve the score further.


Scoring & Trend Alignment


  • Min Pre-W3 score (0..1)
  • Hard gate: anything below this won’t become a W3 candidate.
  • Trend alignment (S/M/L)


Options:

  • None – ignore swing directions, purely pattern/score based
  • Majority – at least 2 of S/M/L must point in the W3 direction
  • AllThree, S+M, S+L, M+L – stricter alignment variants
  • Alignment uses the latest swing direction (up or down) for each degree.



Max W3 candidates to track
Limits how many candidates + trades are stored. Old, already-closed items are pruned first; open trades are never pruned.



This is an indicator, not an order engine**:** it doesn’t place trades; it only marks hypothetical Wave 3 entries and outcomes based on your settings. Always validate on historical data and combine with your own analysis and risk management before using it in live trading.
Notes de version
Updated settings and removed the Zigzag lines plotting by default

Clause de non-responsabilité

Les informations et publications ne sont pas destinées à être, et ne constituent pas, des conseils ou recommandations financiers, d'investissement, de trading ou autres fournis ou approuvés par TradingView. Pour en savoir plus, consultez les Conditions d'utilisation.