OPEN-SOURCE SCRIPT
4H Range Breakout Strategy — ETH 4H optimized + dynamic stop

4H Range Breakout Strategy — ETH Optimized + Risk Management + Forecast
This strategy trades 4H range breakouts on ETH, using the previous confirmed 4-hour candle as the reference range. It combines multi-timeframe context, professional risk management, and a Forecast Engine that sketches likely future paths based on dynamic support/resistance and trend conditions.
Key Features
4H Breakout Logic
Long when price breaks above the prior 4H high; short when it breaks below the prior 4H low.
Optional trend filter (Daily EMA200 + ADX) plus volatility/volume filters to reduce false signals.
Advanced Risk Management
Stop via ATR or fixed percent.
Take-profit via R-multiple, ATR-multiple, or percent.
Scale-out at TP1 (default 60%).
Chandelier-style ATR trailing stop.
Fixed-Risk Position Sizing: each trade risks a fixed % of equity (e.g., 0.5%) for consistent sizing across varying volatility.
Prop-Firm Style Kill Switch
Daily loss cap (% of equity).
Trade halt after N consecutive losses.
Automatic cool-off for a set number of bars.
Optional reset at the start of each trading day.
Auto Regime Engine
Classifies market as Trend, Range, High-Vol, or Neutral using ADX, EMA slope, and ATR Z-score.
Dynamically adjusts buffers, stops, targets, and trailing according to the active regime.
Forecast Path (Scenario Planning)
Draws bullish/bearish path candidates using nearest HTF support/resistance (pivot-based, non-repainting).
Includes an evaluation panel tracking hits/misses to monitor scenario quality over time.
How to Use
Primary timeframes: ETH 1H or 4H (optimized for ETH but adaptable).
Choose a preset (e.g., ETH 4H Optimized or Prop-Firm) or fine-tune inputs.
The Forecast module does not predict; it visualizes conditional paths to aid trade planning and post-analysis.
For robust testing, run backtests across multiple market regimes and review the evaluation panel.
Notes & Best Practices
Combine with higher-timeframe context (Daily/Weekly levels) and news/flow awareness.
Keep risk per trade modest (e.g., 0.25–1.0% of equity).
Consider disabling entries during extremely low volume or during major news releases.
Disclaimer
This script is for educational and research purposes. Trading involves substantial risk. Past results do not guarantee future returns. Always test thoroughly and trade responsibly.
This strategy trades 4H range breakouts on ETH, using the previous confirmed 4-hour candle as the reference range. It combines multi-timeframe context, professional risk management, and a Forecast Engine that sketches likely future paths based on dynamic support/resistance and trend conditions.
Key Features
4H Breakout Logic
Long when price breaks above the prior 4H high; short when it breaks below the prior 4H low.
Optional trend filter (Daily EMA200 + ADX) plus volatility/volume filters to reduce false signals.
Advanced Risk Management
Stop via ATR or fixed percent.
Take-profit via R-multiple, ATR-multiple, or percent.
Scale-out at TP1 (default 60%).
Chandelier-style ATR trailing stop.
Fixed-Risk Position Sizing: each trade risks a fixed % of equity (e.g., 0.5%) for consistent sizing across varying volatility.
Prop-Firm Style Kill Switch
Daily loss cap (% of equity).
Trade halt after N consecutive losses.
Automatic cool-off for a set number of bars.
Optional reset at the start of each trading day.
Auto Regime Engine
Classifies market as Trend, Range, High-Vol, or Neutral using ADX, EMA slope, and ATR Z-score.
Dynamically adjusts buffers, stops, targets, and trailing according to the active regime.
Forecast Path (Scenario Planning)
Draws bullish/bearish path candidates using nearest HTF support/resistance (pivot-based, non-repainting).
Includes an evaluation panel tracking hits/misses to monitor scenario quality over time.
How to Use
Primary timeframes: ETH 1H or 4H (optimized for ETH but adaptable).
Choose a preset (e.g., ETH 4H Optimized or Prop-Firm) or fine-tune inputs.
The Forecast module does not predict; it visualizes conditional paths to aid trade planning and post-analysis.
For robust testing, run backtests across multiple market regimes and review the evaluation panel.
Notes & Best Practices
Combine with higher-timeframe context (Daily/Weekly levels) and news/flow awareness.
Keep risk per trade modest (e.g., 0.25–1.0% of equity).
Consider disabling entries during extremely low volume or during major news releases.
Disclaimer
This script is for educational and research purposes. Trading involves substantial risk. Past results do not guarantee future returns. Always test thoroughly and trade responsibly.
Script de código aberto
No verdadeiro espirito do TradingView, o autor desse script o publicou como código aberto, para que os traders possam entendê-lo e verificá-lo. Parabéns ao autor Você pode usá-lo gratuitamente, mas a reutilização desse código em publicações e regida pelas Regras da Casa.
Aviso legal
As informações e publicações não devem ser e não constituem conselhos ou recomendações financeiras, de investimento, de negociação ou de qualquer outro tipo, fornecidas ou endossadas pela TradingView. Leia mais em Termos de uso.
Script de código aberto
No verdadeiro espirito do TradingView, o autor desse script o publicou como código aberto, para que os traders possam entendê-lo e verificá-lo. Parabéns ao autor Você pode usá-lo gratuitamente, mas a reutilização desse código em publicações e regida pelas Regras da Casa.
Aviso legal
As informações e publicações não devem ser e não constituem conselhos ou recomendações financeiras, de investimento, de negociação ou de qualquer outro tipo, fornecidas ou endossadas pela TradingView. Leia mais em Termos de uso.