Indicator

Indicator

Indicator

Devtrader Dynamic Trading WindowsDevtrader Dynamic Trading Windows
Devtrader Dynamic Trading Windows is an intraday session-mapping tool designed to help traders visually mark their preferred trading windows directly on the chart.
The indicator allows traders to configure multiple ticker-specific profiles and define custom time intervals for each symbol. When the chart symbol matches one of the configured profiles, the indicator automatically applies that ticker’s specific trading windows and draws vertical start/end markers on the chart.
This is useful for traders who focus on specific instruments at specific times of day, such as index killzones, equity opening windows, futures session windows, or personal backtested execution periods.
Main Features
• Multiple ticker profiles
Configure separate profiles for symbols such as GER40, NQ, UK100, INTC, or any custom ticker.
• Ticker-aware behavior
The indicator checks the active chart symbol and only displays the windows configured for the matching ticker profile.
• Multiple intervals per ticker
Each ticker profile can contain multiple editable time intervals, allowing traders to map different trading windows throughout the day.
• Custom vertical lines
Each interval draws vertical markers at the start and end of the configured window.
• Fully editable line style
Customize the color, width, and style of the vertical markers.
• Editable labels
Each interval can display custom labels such as “NQ Open”, “GER40 Main”, “London Window”, or any other preferred text.
• Timezone support
Each ticker profile has its own timezone setting, so the configured sessions can be interpreted correctly for the selected market.
• Intraday-focused design
The script is designed for intraday charts such as 1m, 5m, 15m, and similar timeframes.
• Status label
A small status label shows which ticker profile is currently active and which timezone is being used.
How It Works
1. Add the indicator to an intraday chart.
2. Open the indicator settings.
3. Enable the ticker profile you want to use.
4. Set the ticker match text, for example:
- GER40
- NQ
- UK100
- INTC
5. Define one or more session intervals.
6. Customize the marker text, color, line width, and line style.
7. When the chart symbol matches the profile, the indicator automatically draws the configured window markers.
Example Use Cases
• GER40 / DAX trading window:
Mark the main execution window between 11:20 and 14:00.
• NQ / Nasdaq futures trading window:
Mark the New York open window and afternoon execution window.
• UK100 trading window:
Map the preferred London-session trading period.
• Individual stocks:
Mark opening range, momentum window, or preferred intraday execution periods for stocks such as INTC.
Important Notes
This indicator does not generate buy or sell signals.
It does not predict price direction.
It is not a strategy and does not place trades.
Its purpose is to help traders stay disciplined by visually marking the exact periods when they prefer to focus, observe, or execute trades.
Recommended Usage
Use this indicator as part of a structured trading plan:
• Define your best-performing execution windows.
• Mark only the periods you have backtested or personally validated.
• Avoid overtrading outside your planned windows.
• Combine the window markers with your own market structure, liquidity, volume, price action, or strategy rules.
• Review your trades later to see whether your best results come from specific time intervals.
Why This Indicator Exists
Many intraday traders perform better during specific market periods. For example, some traders prefer the London session, New York open, futures opening range, index killzones, or specific volatility windows.
This tool was created to make those windows visible, consistent, and symbol-specific.
Instead of manually remembering different time windows for each market, traders can configure them once and let the indicator automatically display the correct windows based on the active chart symbol.
Best For
• Intraday traders
• Futures traders
• Index traders
• Stock traders
• Killzone-based traders
• Session-based traders
• Traders who use backtested time windows
• Traders who want more discipline around when they trade
Indicator

Indicator

Quantum Catalyst Nexus [AnkeAlgo]Quantum Catalyst Nexus
This publication introduces an institutional-grade catalyst engine built for traders who want more than decorative clouds and generic momentum arrows. Quantum Catalyst Nexus combines structural displacement, participation analysis, internal delta pressure, and higher-timeframe bias into a single execution framework designed for real chart work.
What Makes This Different
Most public indicators stop at one layer: trend, volume, or market structure. This one was engineered as a decision stack.
Structure Layer: detects confirmed Market Structure Shift events instead of blindly reacting to every swing break.
Participation Layer: measures relative volume expansion so weak breakouts are filtered out.
Internal Delta Layer: estimates whether the bar closes with true directional pressure inside its own range.
Impulse Layer: checks body efficiency so low-quality candles do not get promoted into premium signals.
MTF Bias Layer: aligns the active chart with a higher-timeframe context, defaulting to an automatic 3x timeframe.
Signal Hierarchy: separates Standard catalysts from Prime catalysts so the chart communicates quality, not just direction.
The goal is not to print more signals. The goal is to rank directional events by quality so the trader can focus on expansion with context.
Core Design Philosophy
Quantum Catalyst Nexus was designed around one institutional idea: meaningful moves tend to occur when structure shifts, participation expands, and directional pressure aligns across timeframes. When these conditions converge, the market is no longer just drifting. It is transitioning.
Indicator Architecture
Detect local swing structure with confirmed pivots.
Require a minimum ATR-based displacement before labeling a break as an MSS event.
Measure relative volume against a rolling average to detect participation shock.
Compute internal buy-vs-sell pressure from the candle's close location inside its range.
Smooth delta pressure to reduce single-bar noise.
Project a higher-timeframe bias using the default Auto 3x framework.
Score each event and classify it as Standard or Prime.
Render the result through a clean cloud, premium candle coloring, HTF rails, HUD, and alert conditions.
Core Code: Auto 3x Higher-Timeframe Engine
The indicator automatically derives a higher-timeframe context from the active chart. A 5-minute chart reads from 15-minute logic, a 15-minute chart reads from 45-minute logic, a 1-hour chart reads from 3-hour logic, and so on.
f_autoTripleTf() =>
timeframe.isseconds ? str.tostring(timeframe.multiplier * 3) + "S" :
timeframe.isminutes ? str.tostring(timeframe.multiplier * 3) :
timeframe.isdaily ? str.tostring(timeframe.multiplier * 3) + "D" :
timeframe.isweekly ? str.tostring(timeframe.multiplier * 3) + "W" :
timeframe.ismonthly ? str.tostring(timeframe.multiplier * 3) + "M" :
timeframe.period
activeHtf = htfMode == "Auto 3x" ? f_autoTripleTf() : customHtf
htfFast = request.security(syminfo.tickerid, activeHtf, ta.ema(hlc3, math.max(3, lookback)))
htfSlow = request.security(syminfo.tickerid, activeHtf, ta.ema(hlc3, math.max(6, lookback * 2)))
htfDelta = request.security(
syminfo.tickerid,
activeHtf,
ta.ema(((close - low) / math.max(high - low, syminfo.mintick) * volume - (high - close) / math.max(high - low, syminfo.mintick) * volume) / math.max(volume, 1) * 100.0, deltaSmooth)
)
htfTrend = htfFast > htfSlow ? 1 : htfFast < htfSlow ? -1 : 0
htfBull = htfTrend >= 0 and htfDelta >= 0
htfBear = htfTrend <= 0 and htfDelta <= 0
Why This Matters
A signal on the execution timeframe becomes dramatically more relevant when the higher timeframe is already supportive. The default 3x model keeps the workflow fast and practical without forcing the user to manually synchronize timeframes.
Core Code: Market Structure Shift + Participation Logic
Structure alone is not enough. A true catalyst must displace with intent.
atr = ta.atr(14)
priceRange = math.max(high - low, syminfo.mintick)
bodyPct = math.abs(close - open) / priceRange * 100.0
ph = ta.pivothigh(high, lookback, lookback)
pl = ta.pivotlow(low, lookback, lookback)
bullMss = not na(lastPh) and close > lastPh and close <= lastPh and close - lastPh > atr * mssAtrConfirm
bearMss = not na(lastPl) and close < lastPl and close >= lastPl and lastPl - close > atr * mssAtrConfirm
avgVol = ta.sma(volume, volumeLookback)
relVol = avgVol > 0 ? volume / avgVol : 0.0
isVolumeSurprise = relVol >= volThresh
buyIntensity = (close - low) / priceRange * volume
sellIntensity = (high - close) / priceRange * volume
deltaFlow = ((buyIntensity - sellIntensity) / math.max(volume, 1)) * 100.0
deltaTrend = ta.ema(deltaFlow, deltaSmooth)
Logic Walkthrough
1. MSS Filter
A break is only accepted when price takes out the last confirmed structural pivot and exceeds an ATR-based displacement threshold. This reduces fragile one-tick violations and improves the quality of structural events.
2. Relative Volume Filter
The script measures current volume against a rolling average. A catalyst should not just break structure; it should break structure with participation. Relative volume is the proxy for that expansion.
3. Internal Delta Approximation
The indicator estimates directional pressure by observing where the candle closes inside its own range. A bullish bar closing near the high with strong volume carries very different information from a weak close in the middle of the range.
4. Impulse Quality
The body percentage test acts as a quality gate. Efficient candles are more likely to represent committed flow rather than indecision.
Core Code: Signal Scoring and Prime Classification
bullImpulse = bodyPct >= bodyImpulseMin and close > fastFlow
bearImpulse = bodyPct >= bodyImpulseMin and close < fastFlow
bullCloudAlign = fastFlow > slowFlow
bearCloudAlign = fastFlow < slowFlow
htfPassBull = not useHtfBias or htfBull
htfPassBear = not useHtfBias or htfBear
bullScore = (bullMss ? 2 : 0) + (isVolumeSurprise ? 1 : 0) + (bullPressure ? 1 : 0) + (bullImpulse ? 1 : 0) + (bullCloudAlign ? 1 : 0) + (htfPassBull ? 1 : 0)
bearScore = (bearMss ? 2 : 0) + (isVolumeSurprise ? 1 : 0) + (bearPressure ? 1 : 0) + (bearImpulse ? 1 : 0) + (bearCloudAlign ? 1 : 0) + (htfPassBear ? 1 : 0)
bullCatalyst = bullMss and htfPassBull and bullScore >= minCatalystScore
bearCatalyst = bearMss and htfPassBear and bearScore >= minCatalystScore
bullPrime = bullCatalyst and bullScore >= primeCatalystScore and relVol >= volThresh * 1.1 and bodyPct >= bodyImpulseMin + 5
bearPrime = bearCatalyst and bearScore >= primeCatalystScore and relVol >= volThresh * 1.1 and bodyPct >= bodyImpulseMin + 5
Prime vs Standard Signals
Standard Catalyst: A valid event that satisfies the minimum directional quality threshold.
Prime Catalyst: A higher-grade event with stronger scoring, stronger participation, and cleaner impulse quality.
S+ / S-: Standard Bull and Standard Bear catalysts.
P+ / P-: Prime Bull and Prime Bear catalysts.
This hierarchy is important because real markets do not deliver the same quality of expansion every time. The chart should tell you when a move is merely acceptable and when it is exceptional.
Visual System
The chart is not designed as a toy dashboard. Every element exists to compress information.
Dynamic Delta Cloud: visualizes local flow direction through a fast-vs-slow trend envelope.
Premium Candle Coloring: reflects trend, delta support, and Prime/Standard signal quality.
HTF Structure Rails: marks the most relevant higher-timeframe pivot references.
HUD: surfaces live structure, HTF bias, catalyst state, score, relative volume, and delta condition.
How To Use It
Trend Continuation Workflow
Wait for the cloud to align with the higher timeframe.
Look for a fresh Standard or Prime catalyst in the same direction as the HTF bias.
Prioritize Prime signals when relative volume expands and the score remains elevated.
Use the last structural invalidation or the opposite rail as your contextual risk reference.
Early Trend Transition Workflow
Watch for an MSS against the previous intraday bias.
Confirm that relative volume expands.
Require deltaTrend to flip and stay supportive.
Upgrade conviction only if the event becomes Prime or if the HTF bias also begins to turn.
Cross-Timeframe Workflow
The default design uses a 3x higher-timeframe relationship.
5m chart -> 15m bias
15m chart -> 45m bias
1H chart -> 3H bias
4H chart -> 12H bias
1D chart -> 3D bias
This keeps the indicator highly usable for intraday traders, swing traders, and multi-session traders without requiring manual reconfiguration. If you need a more specific framework, switch the HTF mode to Custom and select the exact timeframe yourself.
Recommended Settings
Fast intraday trading: lower lookback slightly, keep Auto 3x enabled, keep Prime filtering active.
Balanced execution: default settings are already tuned for practical signal density.
Higher selectivity: increase Min Catalyst Score and Prime Catalyst Score.
Cleaner charting: disable mini levels and pulse background, keep HUD on.
HUD Interpretation
The HUD is meant to answer the six questions a professional trader asks before acting.
Structure: Is the local market structurally bullish, bearish, or neutral?
HTF Bias: Is the larger context supporting the trade?
Catalyst: Is the current event Prime, Standard, or inactive?
Score: How many quality layers are currently aligned?
Rel Volume: Is participation above average?
Delta: Is internal directional pressure reinforcing the move?
Alert Setup
Quantum Catalyst Nexus includes separate alert conditions for precise workflow automation.
newBullPrime = bullPrime and not bullPrime
newBearPrime = bearPrime and not bearPrime
newBullStandard = bullStandard and not bullStandard
newBearStandard = bearStandard and not bearStandard
newAnyCatalyst = (bullCatalyst or bearCatalyst) and not (bullCatalyst or bearCatalyst )
alertcondition(newBullPrime, "Prime Bull Catalyst", "Prime Bull Catalyst detected on {{ticker}} | TF: {{interval}}")
alertcondition(newBearPrime, "Prime Bear Catalyst", "Prime Bear Catalyst detected on {{ticker}} | TF: {{interval}}")
alertcondition(newBullStandard, "Standard Bull Catalyst", "Standard Bull Catalyst detected on {{ticker}} | TF: {{interval}}")
alertcondition(newBearStandard, "Standard Bear Catalyst", "Standard Bear Catalyst detected on {{ticker}} | TF: {{interval}}")
alertcondition(newAnyCatalyst, "Any Catalyst Signal", "A Catalyst signal was detected on {{ticker}} | TF: {{interval}}")
How To Configure Alerts In PulseWire
Add the indicator to the chart.
Open the PulseWire alert dialog.
Select Quantum Catalyst Nexus as the condition source.
Choose one of the dedicated conditions: Prime Bull, Prime Bear, Standard Bull, Standard Bear, or Any Catalyst Signal.
Use Prime alerts for high-conviction monitoring, or Any Catalyst for broad market scanning.
Professional Use Cases
Intraday continuation after an opening range shift.
Momentum confirmation after a retest and reclaim.
Bias alignment between execution timeframe and supervisory timeframe.
Event filtering for semi-systematic discretionary trading.
Screening catalyst events across multiple watchlist instruments.
Important Interpretation Note
This indicator is not trying to predict every turning point. It is built to highlight moments when structure, participation, and internal pressure synchronize. In professional execution, that synchronization matters far more than decorative overfitting.
Final Word
Quantum Catalyst Nexus is built for traders who want a premium catalyst framework instead of a noisy momentum overlay. If you trade structure, respect participation, and care about cross-timeframe alignment, this tool was engineered for that exact workflow.
If this release helps your process, boost it with a rocket and share how you are using Prime versus Standard catalysts in your own market environment. Indicator

Indicator

Indicator

Indicator

Indicator

Indicator

Indicator

Indicator

Gold Levels Dashboard
Dashboard for full setup entry SL TP support
Key levels: R3, R2, R1, Pivot, S1, S2, S3, MAJR (Major Support), SAR (Parabolic SAR)
Trade setup: Entry, SL, TP1, TP2, TP3
Multi-timeframe bias: Daily, 4H, 1H, 15M
Indicator scorecard: RSI, MACD, ADX, etc.
Pivot points (calculated from previous day's OHLC)
Parabolic SAR
RSI, MACD, ADX for bias determination
EMA for trend bias per timeframe
Table display with colored cells like the image Indicator

Asymmetric Volatility Trend Line [QuantAlgo]🟢 Overview
Asymmetric Volatility Trend Line is a trend-following indicator built on adaptive standard deviation thresholds rather than fixed bands or moving average crossovers. It quantifies the statistical volatility of recent price movement to determine asymmetric conditions for trend continuation versus trend reversal, then uses those conditions to anchor a dynamic trend line that adjusts position in response to confirmed directional moves, helping traders distinguish between genuine breakouts and noise-driven fluctuations across every timeframe and market.
🟢 How It Works
The foundation of the indicator is a rolling standard deviation applied to the selected price source over a configurable lookback window, scaled by a threshold multiplier to produce the volatility boundary used in all trend logic:
vol_threshold = ta.stdev(src, lookback) * threshold_mult
This threshold is intentionally asymmetric in application. When the trend line is in a bullish state, a smaller fraction of the threshold (0.5x) is required for price to confirm continuation, while a full threshold breach in the opposite direction is needed to trigger a reversal. The same asymmetry applies in reverse during bearish states:
if trend_dir >= 0
if src > trend_line + vol_threshold * 0.5
trend_line := math.max(trend_line, src - vol_threshold * 0.25)
trend_dir := 1
else if src < trend_line - vol_threshold
trend_line := src + vol_threshold * 0.25
trend_dir := -1
This design means continuation requires less evidence than reversal. A directional move only needs to exceed half the volatility threshold to sustain the current trend, but must overcome the full threshold to flip it. The 0.25x offset applied when repositioning the trend line keeps it anchored within the volatility envelope rather than jumping directly to price, producing a smoother line that does not overreact to a single bar.
When a reversal is confirmed, the trend line is placed on the opposite side of price at a quarter-threshold distance, giving it room to develop without immediately triggering another flip:
trend_line := src + vol_threshold * 0.25 // repositioned on bearish flip
trend_dir := -1
Direction state is tracked through two integer variables, with reversal conditions derived from comparing the current and prior bar states:
turned_bullish = trend_dir == 1 and trend_dir == -1
turned_bearish = trend_dir == -1 and trend_dir == 1
is_reversal = trend_dir != prev_dir and bar_index > 0
🟢 Signal Interpretation
▶ Bullish Trend (Green): When price closes above the trend line by more than half the volatility threshold, the indicator enters bullish mode with green colouring applied across the trend line, gradient fill, and reversal marker (⦿). This state persists until price closes below the trend line by the full volatility threshold, allowing normal pullbacks to occur without triggering a direction change.
▶ Bearish Trend (Red): When price closes below the trend line by more than half the volatility threshold, the indicator enters bearish mode with red colouring across all visual elements. A full threshold breach to the upside is required to exit this bearish state.
🟢 Features
▶ Preconfigured Presets: Three parameter sets cover different trading approaches. "Default" targets swing trading on 4-hour and daily charts with moderate threshold sensitivity. "Fast Response" reduces the volatility barrier and shortens the lookback for intraday charts where the indicator needs to adapt to shorter-duration moves. "Smooth Trend" raises the reversal threshold substantially for position trading on daily and weekly timeframes, where the cost of a false flip is higher than the cost of a delayed one. Selecting a preset overrides the individual multiplier and lookback inputs.
▶ Built-in Alerts: Three alert conditions cover all directional states. "Bullish Trend Signal" fires on the bar where the trend direction flips from bearish to bullish. "Bearish Trend Signal" fires on the bar where it flips from bullish to bearish. "Any Trend Change" combines both into a single condition for traders who want a unified notification regardless of direction.
▶ Visual Customisation: Six colour presets (Classic, Aqua, Cosmic, Cyber, Neon, and Custom) apply coordinated bullish and bearish colour schemes across the trend line, gradient fill, reversal markers, and optional bar and background colouring. Bar colouring tints price candles with the active trend colour at a configurable transparency level, and background colouring extends the directional tint across the full chart pane. Both are disabled by default and controlled independently.
Indicator

Indicator

Indicator

Complex Single Trade StrategyThis 'Complex Single Trade Strategy' is a generic trading strategy that features three different types of stops, and four take profits.
It takes a Buy/Sell source input of:
The first signal will trigger a position to open immediately in that direction, but subsequent signals in the same direction will be ignored whilst the position remains open, as this strategy allows only one position at once.
A signal in the opposite direction to the current position can either be ignored, or it can close the position, or it can close it then immediately open another one in the opposite direction.
It also takes an optional 'Cancel' indicator just to close positions. Other signals will be ignored.
The three different types of stops, that can be applied individually, or together:
* Regular Stop
* Initial Trailing Stop
* Trailing Stop
The initial trailing stop works like a regular trailing stop until it reaches the cut off level, a percentage of the current asset price above or below the entry level, then it will no longer trail the price, remaining statically at this level.
From here the regular trailing stop can take over trailing the price. This is useful to move the stop to the entry level (or there abouts) fairly quickly. From there you might want to trail the price with a larger trailing stop for the rest of the trade.
0 cut off means it stops trailing the price at your entry level, positive above, negative below, for a long trade. For a short it would be the opposite.
Typically you would want:
Trailing Stop > Initial Trailing Stop >= Stop
The four take profits each specify an amount to reduce the position size by, and at what specified percentage gain in price this is triggered.
My 'Simple Buy/Sell Indicator' and 'Custom Buy/Sell Indicator' (coming soon - watch this space) can be used to combine other indicators together into BUY/SELL strategies, using multiple custom rules. These can then be used as inputs to this strategy.
Strategy

Indicator

Session Boxes Pro By AvishSession Boxes Pro - Asia / London / NY
A clean, professional session visualization tool that highlights the three major Forex trading sessions directly on your chart - Asia, London, and New York.
Each session is drawn as a dynamic price box that builds in real time, capturing the exact high and low range as the session develops. When the session closes, the box locks in permanently as a reference level for the next session.
What is included:
Session Boxes - Asia (purple), London (red), New York (green). Each box tracks the live high and low range and updates bar by bar.
Session Labels - Asia, London, New York - pinned inside each box at the top corner so you always know which zone you are looking at.
Boundary Lines - dashed vertical lines mark the open and close of every session, giving you clean visual separation between market periods.
Dashboard Table - a live top-right panel showing each session current status (LIVE or Closed), the session range in price units, and a Bull or Bear bias based on where price sits relative to the session midpoint.
200 EMA - fully integrated with toggle, colour picker, width control, and three style options (Solid, Dashed, Dotted) so it fits any chart setup.
Fully customisable - every colour, time window, label size, and toggle is editable from the Settings panel. Works on all assets and timeframes including Forex, Gold, indices, and crypto.
Best used on: 1m, 5m, 15m, 20m, 1H timeframes. Indicator

maXXit LevelTRG [V6 2.0]# maXXit Level Trigger — Overview
**Platform:** PulseWire Pine Script v6 · Overlay indicator
---
## What does the Level Trigger do?
The Level Trigger automates trade entries and exits based on a freely configurable price level. False breakouts are filtered by an **N-closes confirmation** — only after N consecutive candles close through the level is an action triggered. The trigger fires JSON alerts to an external webhook server connected to a broker API (IBKR, OANDA, IG Markets).
If the signal generation is based on futures contracts (highly recommended), the mirror instruments are mapped through configurable parameters inside the script to the pre-configured broker API. The trigger does not fire position entries or exits inside PulseWire directly. A plain-text message can be sent as an alternative.
All state machine logic runs **live only** — no historical replay arming.
---
## Flow (State Machine)
```
1. ARMED — Price touches the trigger level from the opposite side (intrabar, live bar only)
2. ENTRY — N consecutive closes back through the level → BUY / SELL alert
3. POSITION — Stop and TP monitor the open position
4. EXIT — SL or TP fires → closing order alert
```
---
## Features
| Feature | Description |
|---|---|
| **Long & Short** | Both directions configurable |
| **N-Closes (1–3)** | Consecutive closes required for arming confirmation, entry and SL/TP (Close mode) |
| **Live arming only** | Trigger arms only on real-time bars — no historical replay |
| **Trigger-level stop** | N closes back through the trigger level = automatic stop exit. Active only when no Absolute SL is set |
| **Absolute Stop Loss** | A separate SL level — fires immediately on intrabar touch, no close confirmation. When set, the trigger-level stop is deactivated |
| **Take Profit — Close mode** | TP arms on intrabar touch (high/low crosses TP level), exits on N consecutive closes back through TP |
| **Take Profit — Touch mode** | Exit fires immediately on intrabar TP touch |
| **Trailing stop** | Auto-stop locks at the TP level when TP is first reached — acts as a floor stop while price runs |
| **JSON alerts** | Direct broker integration (IBKR, OANDA, IG Markets) via webhook |
| **Symbol mapping** | Pre-defined instrument parameters for 15+ futures/CFDs |
| **Lock to Symbol** | Trigger stays bound to the selected instrument ticker prefix across chart changes |
| **Position Lock** | Preserves position state (LONG/SHORT) when inputs are changed mid-trade |
| **Fractal Grid** | Optional overlay of highest-high / lowest-low grids (5 levels, 10–50 bars) |
---
## Stop Loss Logic — Three-tier hierarchy
Only one tier is active at a time:
| Priority | Condition | Stop mechanism | Trigger |
|---|---|---|---|
| **1 — Absolute SL** | SL Level > 0 | Fixed price level | Intrabar touch — immediate |
| **2 — Auto-SL (TP lock)** | TP reached → auto_sl set | Old TP level becomes new stop | N consecutive closes through the level |
| **3 — Trigger-level stop** | No SL, no auto_sl | Trigger level acts as stop | N consecutive closes |
### How tiers interact
- When **Absolute SL is set**: tiers 2 and 3 are deactivated. Only the intrabar stop fires.
- When **TP is reached** (intrabar touch in Close mode): the TP level locks as a trailing stop (`auto_sl`). The Absolute SL can now be removed — `auto_sl` takes over with N-close confirmation.
- When **neither SL nor auto_sl is active**: the trigger level itself acts as the stop (N closes back through it).
### After a stop fires
The trigger does not re-arm automatically. To re-activate, change the Trigger Level input — this resets all state.
---
## Worked Example — LONG, N = 2 closes
**Setup:** Direction = LONG · Trigger = 5000 · TP = 5100 · Closes required = 2
### Phase 1 — Entry
| Event | What happens |
|---|---|
| Price dips below 5000 (intrabar, live) | Trigger **arms** — indicator starts watching |
| Price rises, 2 consecutive closes above 5000 | **Entry alert fired** → BUY order sent · stop activates at 5000 |
| Price dips back, 2 closes below 5000 (before TP) | **Stop exit** → SELL alert · trigger deactivates |
### Phase 2a — TP exit (Close mode, price reverses after TP)
| Event | What happens |
|---|---|
| Price rises through 5100 (intrabar) | TP **arms** — stop locks at 5100, indicator waits for reversal |
| Price falls back, 2 consecutive closes below 5100 | **TP exit alert** → SELL order sent · position closed |
### Phase 2b — Trailing stop (price keeps running above TP)
| Event | What happens |
|---|---|
| Price rises through 5100 | TP arms — stop **locks at 5100** (yellow line) |
| Price continues above 5100 | Position stays open · stop remains at 5100 |
| User raises TP to 5200 | `tp_armed` resets · stop stays locked at old 5100 level (use Active Position to preserve state) |
| Price reaches 5200 | Stop locks at 5200 |
| Price falls, 2 closes below 5200 | **Stop exit alert** → SELL order sent |
> The locked stop (old TP level) works exactly like the trigger-level stop: N consecutive closes through the level fire the exit.
### Workflow — raising TP while stop is locked
Pine Script resets all computed state (`tp_armed`, `auto_sl`) on every input change. To preserve the locked stop when raising TP:
| Step | Action |
|---|---|
| 1 | Note the current locked stop level (yellow line, e.g. 5100) |
| 2 | Set **Active Position** = `LONG` (or `SHORT`) |
| 3 | Set **Trigger Level** = locked stop value (e.g. 5100) |
| 4 | Set **TP Level** = new target (e.g. 5200) |
| 5 | After recalc: position restored · Trigger Level acts as stop · new TP active |
> **Why Trigger Level:** it is a persistent input that survives recalculation. When in position with no Absolute SL and no `auto_sl`, the trigger level acts as the N-closes stop.
---
## Visual Display
### Trigger label (at trigger level)
| State | Label | Color |
|---|---|---|
| Armed, LONG direction | TOUCHED ↑ | Green |
| Armed, SHORT direction | TOUCHED ↓ | Red |
| Active LONG position | LONG ↑ | Green |
| Active SHORT position | SHORT ↓ | Red |
| SL/Trigger crossed while in position | CAUTION | Orange |
| TP armed (acting as SL) | IDLE | Gray |
| No trigger configured | IDLE | Gray |
### SL label (at SL level)
| State | Label | Color |
|---|---|---|
| In LONG position | ARMED ▼ | Dark orange |
| In SHORT position | ARMED ▲ | Dark orange |
| Armed, LONG direction | ARMED ▼ | Dark orange |
| Armed, SHORT direction | ARMED ▲ | Dark orange |
| Hidden when TP is armed (TP line acts as SL) | — | — |
### TP label (at TP level)
| State | Label | Color |
|---|---|---|
| Position open, TP not yet reached | TP ACTIVE | Green |
| TP reached, acting as trailing stop (LONG) | SL ACTIVE ↑ | Green |
| TP reached, acting as trailing stop (SHORT) | SL ACTIVE ↓ | Red |
| TP exit just fired | TP CLOSED | Gray |
| No position | IDLE | Gray |
### Lines
- **Trigger line** — dashed · color matches trigger label state
- **SL line** — solid · dark orange when armed or in position · hidden when TP is acting as SL
- **TP line** — dashed · green (active) · color matches TP label state
- **Auto-SL line** — solid yellow · shows locked stop level when TP has armed
---
## Design Decisions & Rationale
### Why live-only arming (`barstate.isrealtime`)
All state machine logic runs only on real-time bars. Trigger levels are set manually based on the current Elliott Wave analysis. A historical simulation of manually-set levels would be meaningless — the level is valid only in the context of the current wave structure. Live-only arming ensures clean state on each session start and prevents false fills from historical data replay.
### Why the trigger does not re-arm automatically after exit
After a trade closes, re-entry at the same level requires re-analysis and a conscious decision. Re-arming is triggered by changing the Trigger Level input, which reloads all state. This is intentional: the wave structure has either confirmed or invalidated at that level.
### Why position sizing is manual
Risk per trade depends on the SL distance, which varies with each wave setup. The analyst calculates `quantity = max_risk_USD / (entry_price - SL_level)` before setting inputs. Automating this inside the script would require the entry price to be known in advance, which conflicts with the trigger-based entry mechanism.
### Why PulseWire webhooks (no direct broker connection)
PulseWire provides the charting and signal generation layer. The broker API integration lives in a separate webhook server. This separation keeps the Pine Script simple and broker-agnostic — switching brokers requires only a server-side change, not a script rewrite.
### Why N-closes confirmation instead of intrabar triggers
Intrabar wicks frequently penetrate Elliott levels without confirming. N confirmed closes through a level provide meaningful structure confirmation — a wick is noise, a close is a statement. The cost is a few points of slippage on the entry; the benefit is fewer false signals.
### Why TP Close mode arms on intrabar touch (not N closes)
TP is a profit target, not a structural level. Waiting for N closes above the TP level before arming would delay the trailing stop activation unnecessarily — the first intrabar touch is sufficient evidence that the target was reached. The exit itself still requires N closes back through the TP level, preserving the confirmation logic on the way out.
---
## Settings Reference
| Input | Group | Description |
|---|---|---|
| Send JSON Alert | Account & Broker | ON = JSON webhook · OFF = plain-text alert |
| Webhook Secret | Account & Broker | Token included in JSON payload for server authentication |
| Account ID | Account & Broker | Broker account identifier (IBKR, OANDA, IG Markets, etc.) |
| Use predefined mapping | Instrument | Uses built-in symbol → broker mapping table |
| Mirror Trade | Instrument | NO = trade the chart future · YES = trade mirror instrument (STK/CFD) |
| Mirror Instrument | Instrument | STK (IBKR ETF) or CFD (OANDA / IG Markets) |
| Quantity | Instrument | Size of the order |
| Direction | Level Trigger | LONG or SHORT |
| Trigger Level | Level Trigger | Price level. 0 = disarmed |
| Stop Loss Level | Level Trigger | Absolute SL. 0 = use trigger-level stop instead |
| TP Level | Level Trigger | Take profit level. 0 = disabled |
| TP Arm Mode | Level Trigger | Touch = immediate intrabar exit · Close = N-close reversal confirmation |
| Closes required | Level Trigger | 1–3 consecutive closes needed for arming, entry and SL/TP |
| Lock to Symbol | Level Trigger | Ticker prefix to lock trigger to one instrument (e.g. MNQ, FXXP) |
| Active Position | Level Trigger | Auto / LONG / SHORT — preserves position state across input changes |
| Fractal Grid | Position Management | Shows highest-high / lowest-low grid overlay |
---
## Supported Instruments
| Prefix | Instrument | Exchange | Mirror (STK) | Mirror (CFD OANDA) | Mirror (CFD IG) |
|---|---|---|---|---|---|
| MNQ | Micro Nasdaq-100 | CME | QQQ | NAS100_USD | NASDAQ |
| MES | Micro S&P 500 | CME | SPY | SPX500_USD | SPTRD |
| MYM | Micro Dow Jones | CBOT | DIA | US30_USD | DOW |
| FXXP / FSXE | Euro Stoxx 50 | EUREX | IMEU | EU50_EUR | STXE |
| MGC | Micro Gold | COMEX | GLD | XAU_USD | SPOTGOLD |
| MCL | Micro Crude Oil | NYMEX | USO | WTICO_USD | USOIL |
| MNG | Micro Nat Gas | NYMEX | — | NATGAS_USD | NATURALGAS |
| MHG | Micro Copper | COMEX | — | XCU_USD | COPPER |
| ZW | Wheat | CBOT | — | WHEAT_USD | — |
| ZN | 10Y T-Note | CBOT | — | USB10Y_USD | — |
| CN1 | FTSE China A50 | SGX | — | CN50_USD | — |
| EURUSD | EUR/USD Spot | IDEALPRO | — | EUR_USD | — |
| BTCUSD | Bitcoin | — | — | BTC_USD | BITCOIN |
| ETHUSD | Ethereum | — | — | ETH_USD | ETHUSD |
---
## Later Enhancements Planned
| # | Enhancement | Rationale |
|---|---|---|
| **1** | **Multi-level trigger** — two simultaneous trigger levels with independent directions | Allows monitoring Wave 3 and Wave 5 levels simultaneously without two separate chart instances |
| **2** | **Partial exits / scale-out** — e.g. 50% at TP1, remainder with trailing stop | Elliott Wave extensions are common; closing the full position at the first TP level often leaves significant profit on the table |
| **3** | **Volatility-adaptive N-closes** — automatically tighten/loosen confirmation count based on ATR or session volatility | A single N-close setting behaves differently in a quiet overnight session vs. a high-impact news event |
Indicator

Indicator

Indicator
