OPEN-SOURCE SCRIPT
已更新

The Barking Rat Lite

1 577
Momentum & FVG Reversion Strategy
The Barking Rat Lite is a disciplined, short-term mean-reversion strategy that combines RSI momentum filtering, EMA bands, and Fair Value Gap (FVG) detection to identify short-term reversal points. Designed for practical use on volatile markets, it focuses on precise entries and ATR-based take profit management to balance opportunity and risk.

快照

Core Concept
This strategy seeks potential reversals when short-term price action shows exhaustion outside an EMA band, confirmed by momentum and FVG signals:

EMA Bands:
Parameters used: A 20-period EMA (fast) and 100-period EMA (slow).

Why chosen:
- The 20 EMA is sensitive to short-term moves and reflects immediate momentum.
- The 100 EMA provides a slower, structural anchor.

When price trades outside both bands, it often signals overextension relative to both short-term and medium-term trends.

Application in strategy:
- Long entries are only considered when price dips below both EMAs, identifying potential undervaluation.
- Short entries are only considered when price rises above both EMAs, identifying potential overvaluation.

This dual-band filter avoids counter-trend signals that would occur if only a single EMA was used, making entries more selective..

Fair Value Gap Detection (FVG):
Parameters used: The script checks for dislocations using a 12-bar lookback (i.e. comparing current highs/lows with values 12 candles back).

Why chosen:
- A 12-bar displacement highlights significant inefficiencies in price structure while filtering out micro-gaps that appear every few bars in high-volatility markets.
- By aligning FVG signals with candle direction (bullish = close > open, bearish = close < open), the strategy avoids random gaps and instead targets ones that suggest exhaustion.

Application in strategy:
- Bullish FVGs form when earlier lows sit above current highs, hinting at downward over-extension.
- Bearish FVGs form when earlier highs sit below current lows, hinting at upward over-extension.

This gives the strategy a structural filter beyond simple oscillators, ensuring signals have price-dislocation context.

RSI Momentum Filter:
Parameters used: 14-period RSI with thresholds of 80 (overbought) and 20 (oversold).

Why chosen:
- RSI(14) is a widely recognized momentum measure that balances responsiveness with stability.
- The thresholds are intentionally extreme (80/20 vs. the more common 70/30), so the strategy only engages at genuine exhaustion points rather than frequent minor corrections.

Application in strategy:
- Longs trigger when RSI < 20, suggesting oversold exhaustion.
- Shorts trigger when RSI > 80, suggesting overbought exhaustion.

This ensures entries are not just technically valid but also backed by momentum extremes, raising conviction.

ATR-Based Take Profit:
Parameters used: 14-period ATR, with a default multiplier of 4.

Why chosen:
- ATR(14) reflects the prevailing volatility environment without reacting too much to outliers.
- A multiplier of 4 is a pragmatic compromise: wide enough to let trades breathe in volatile conditions, but tight enough to enforce disciplined exits before mean reversion fades.

Application in strategy:
- At entry, a fixed target is set = Entry Price ± (ATR × 4).
- This target scales automatically with volatility: narrower in calm periods, wider in explosive markets.

By avoiding discretionary exits, the system maintains rule-based discipline.

Visual Signals on Chart
  • Blue “▲” below candle: Potential long entry
  • Orange/Yellow “▼” above candle: Potential short entry
  • Green “✔️”: Trade closed at ATR take profit
  • Blue (20 EMA) & Orange (100 EMA) lines: Dynamic channel reference


快照
快照

⚙️Strategy report properties
Position size: 25% equity per trade
Initial capital: 10,000.00 USDT
Pyramiding: 10 entries per direction
Slippage: 2 ticks
Commission: 0.055% per side
Backtest timeframe: 1-minute
Backtest instrument: HYPEUSDT
Backtesting range: Jul 28, 2025 — Aug 17, 2025

Note on Sample Size:
You’ll notice the report displays fewer than the ideal 100 trades in the strategy report above. This is intentional. The goal of the script is to isolate high-quality, short-term reversal opportunities while filtering out low-conviction setups. This means that the Barking Rat Lite strategy is very selective, filtering out over 90% of market noise. The brief timeframe shown in the strategy report here illustrates its filtering logic over a short window — not its full capabilities. As a result, even on lower timeframes like the 1-minute chart, signals are deliberately sparse — each one must pass all criteria before triggering.

For a larger dataset:
Once the strategy is applied to your chart, users are encouraged to expand the lookback range or apply the strategy to other volatile pairs to view a full sample.

💡Why 25% Equity Per Trade?
While it's always best to size positions based on personal risk tolerance, we defaulted to 25% equity per trade in the backtesting data — and here’s why:
  • Backtests using this sizing show manageable drawdowns even under volatile periods.
  • The strategy generates a sizeable number of trades, reducing reliance on a single outcome.
  • Combined with conservative filters, the 25% setting offers a balance between aggression and control.
  • Users are strongly encouraged to customize this to suit their risk profile.


What makes Barking Rat Lite valuable
  • Combines multiple layers of confirmation: EMA bands + FVG + RSI
  • Adaptive to volatility: ATR-based exits scale with market conditions
  • Clear, actionable visuals: Easy to monitor and manage trades

快照
發行說明
Update to chart thumbnail
發行說明
Update to chart thumbnail 2.0
發行說明
Added alert functionality for entry signals and exits:
- Long Entry Alert – triggers when a long position is opened.
- Short Entry Alert – triggers when a short position is opened.
- Long Exit Alert – triggers when a long position reaches the ATR-based take profit.
- Short Exit Alert – triggers when a short position reaches the ATR-based take profit.

免責聲明

這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。