PROTECTED SOURCE SCRIPT

S/D Boring-Explosive (Non-Repaint)

62
S/D Boring-Explosive Zone Detector (Non-Repaint)
📊 Overview
This indicator automatically identifies high-probability Supply and Demand zones using the "Boring-Explosive" pattern - a proven price action concept where consolidation (boring candles) precedes explosive moves. The script provides clean, non-repainting zones with intelligent retest alerts for optimal entry timing.
🎯 Core Concept: The Boring-Explosive Pattern
What is a Boring Candle?

A candle with wicks larger than its body
Represents consolidation, indecision, or accumulation/distribution
Often marks institutional order flow areas

What is an Explosive Candle?

A candle significantly larger than the preceding boring candle (default: 50% bigger)
Represents a breakout with strong momentum
Confirms the zone as a valid supply/demand area

The Pattern:

Price creates a boring candle (consolidation)
Within 3 bars, an explosive move occurs
The boring candle's range becomes a supply/demand zone
Future retests of this zone offer high-probability entries

✨ Key Features
🎨 Automatic Zone Detection

Demand Zones (Green): Form after bullish explosive moves - act as support
Supply Zones (Red): Form after bearish explosive moves - act as resistance
Non-Repainting: All zones confirmed on closed candles only
Customizable Size: Adjust explosive multiplier to filter zone quality

🔔 Smart Retest Alerts

Multiple Entry Signals: Get alerts each time price retests a valid zone
Time-Based Filtering: Configurable minimum time between retests (default: 60 min) prevents alert spam
Visual Labels: Clear "RETEST ▲" and "RETEST ▼" labels at retest points
Respect-Based Logic: Labels only appear when price enters zone and closes outside (showing respect)

📈 Multi-Timeframe Support

Higher Timeframe Zones: Overlay HTF zones on lower timeframe charts
Visual Distinction: HTF zones shown in blue/orange with thicker borders
Combined Analysis: View both current and higher timeframe zones simultaneously

🧹 Clean Chart Management

Auto-Delete on Fill: Zones automatically removed when price breaks through
Configurable History: Keep zones for 100-5000 bars
Label Lifecycle: Retest labels deleted when their zone is invalidated
Decluttered View: Only shows relevant, active zones

⚙️ Settings Guide
Zone Detection

Explosive Size Multiplier: How much bigger explosive candle must be (1.5 = 50% larger)
Bars Back to Check: How long to maintain zones (500 = keep zones for 500 bars)
Delete Zones After Fill: Remove zones when price closes through them
Fill Type: Choose "Close" (zone filled on close) or "Wick" (filled on touch)

Multi-Timeframe

Use Higher Timeframe: Enable HTF zone detection
Higher Timeframe: Select HTF (e.g., 60min, 240min, Daily)
Show Current TF Zones: Toggle current timeframe zones on/off

Retest Settings

Show Retest Labels: Display visual labels at retest points
Min Minutes Between Retests: Time filter to prevent duplicate signals (1-60+ minutes)
Label Text Size: Adjust label visibility
Alert on Zone Retest: Enable push/email/sound alerts

Styles

Customize colors for demand/supply zones
Adjust border width (1-5)
Toggle zone extension to the right

📖 How to Use
For Day Traders:

Set "Min Minutes Between Retests" to 15-30 minutes
Use on 5min or 15min charts
Enable HTF zones (60min) for additional confluence
Take entries on retest labels aligned with HTF zones

For Swing Traders:

Set "Min Minutes Between Retests" to 60-240 minutes
Use on 1H or 4H charts
Enable HTF zones (Daily or Weekly)
Look for zones that hold multiple retests

Entry Strategy:

Wait for zone to form (boring + explosive pattern)
Wait for price to return to the zone
Enter when retest label appears (price entered zone and closed outside)
Place stop loss beyond the zone
Zone remains valid until price closes through it

🎓 Trading Logic
Demand Zone Retest (Long Entry):

Price drops into green zone (low touches zone)
Candle closes ABOVE the zone top
Shows buyers defended support → Entry signal

Supply Zone Retest (Short Entry):

Price rises into red zone (high touches zone)
Candle closes BELOW the zone bottom
Shows sellers defended resistance → Entry signal

⚠️ Important Notes

Non-Repainting: Uses confirmed bars [1] for all detections
Zone Validity: Zones deleted when filled (if enabled) or after bars back limit
Multiple Retests: Same zone can generate multiple signals based on time filter
Timeframe Compatibility: Works on all timeframes (1min to Monthly)
Best Practice: Combine with trend analysis and risk management

🔧 Technical Details

Uses confirmed candle data only (no repainting)
Tracks zone state (untested vs. respected)
Links labels to zones for automatic cleanup
Validates zone existence before creating signals
Supports up to 500 zones simultaneously

📱 Alerts Available

Demand Zone Retest: Fires when price respects support zone
Supply Zone Retest: Fires when price respects resistance zone
Configurable: Enable/disable in retest settings


Perfect for: Price action traders, supply/demand traders, institutional order flow analysis, multi-timeframe analysis
Compatible with: All markets (Forex, Stocks, Crypto, Futures, Indices)

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 o de otro tipo proporcionadas o respaldadas por TradingView. Más información en Condiciones de uso.