Blog / Strategy
Strategy

Directional Flow Reservoir

Disclaimer: This article is for educational and informational purposes only. It does not constitute financial or investment advice. Trading forex and CFDs carries significant risk of loss. Past performance of any strategy — including backtests — does not guarantee future results. Never trade with money you cannot afford to lose.

What Is This Strategy?

The Directional Flow Reservoir is a trend-following Expert Advisor (EA) for MetaTrader 5 that trades from a single custom quantity — a "leaky reservoir of directional pressure" — computed entirely from raw price data (open, high, low, close). Rather than relying on a classical indicator such as a moving average, RSI, or MACD, it builds its own signal from scratch: it measures how much net progress each bar makes relative to the market's typical activity, then accumulates that signed pressure into a fading memory that slowly leaks back toward zero. In plain terms, it is a momentum-and-regime system that tries to distinguish a genuine one-sided drift from directionless churn.

The core idea is a physical analogy. Imagine a tank that is filled, bar by bar, with signed "directional pressure" and that continuously leaks that pressure out over time. When steady buying or selling keeps charging the tank faster than it can drain, the reservoir level rises well above (or falls well below) what its own recent behaviour considers normal — the strategy reads that as a coherent directional regime and takes a position. When the flow becomes two-sided and choppy, the leak wins, the level drains back through zero, and the strategy steps aside.

As a learning tool, the Directional Flow Reservoir is well suited to traders who want to study how a self-calibrating momentum model behaves without any traditional indicator on the chart. It is designed for trending market conditions and is intended to sit out balanced, sideways phases. This article is a strategy analysis, not a profit opportunity — the goal is to understand the mechanics, the parameters, and the trade-offs so you can evaluate the approach on your own terms.

How It Works

The strategy acts once per completed bar. On each new bar it updates its internal reservoir value and then checks whether to manage an open trade or open a new one. Here is the logic in plain English:

Entry conditions:

Exit conditions:

Whichever comes first — the reservoir-release exit or the ATR stop/target — closes the trade.

directional flow reservoir MT5 EA
Illustrative example of the strategy’s entry and exit logic — not real trading results.

Strategy Parameters

Parameter Default Min Max Description
Window 20 8 60 Number of bars used for the typical-churn scale and the reservoir-dispersion band. Larger values smooth the signal and slow reactions.
Retention 0.85 0.50 0.97 The reservoir leak retention (lambda). Higher values give the reservoir a longer directional memory; lower values make it forget quickly.
ThresholdK 1.20 0.50 3.00 Confidence multiple — how many reservoir standard deviations define "significant" pressure. Higher values demand stronger moves before entry.
AtrPeriod 14 5 40 Number of bars used to calculate ATR for the volatility stop and target.
StopAtrMult 1.50 0.50 4.00 Stop-loss distance expressed as a multiple of ATR. Larger values give the trade more room but increase risk per trade.
RewardRiskRatio 1.80 1.00 4.00 Take-profit distance as a multiple of the stop distance (the reward-to-risk ratio).
Lots 0.10 0.01 1.00 Fixed position size in lots for each trade.
directional flow reservoir MT5 EA — MQL5 source code

Recommended Chart Settings

The Directional Flow Reservoir is a single-timeframe strategy — every calculation uses the chart's own timeframe, so you attach it to one chart and it works from that period alone. Because the model is self-scaling (it divides everything by the market's typical range), it is not tied to one specific instrument. A reasonable starting point for study is a major forex pair such as EUR/USD on the H1 (1-hour) timeframe, which offers enough clean trending phases to observe the reservoir mechanics without excessive noise.

That said, no single setting is optimal everywhere. Results will vary considerably across different symbols, timeframes, and market conditions. Treat the recommended settings as a baseline for experimentation on a demo account, not as a fixed prescription. If you test on faster timeframes, expect more signals and more sensitivity to spread; on slower timeframes, expect fewer but potentially cleaner regimes.

How to Install on MetaTrader 5

What to Consider Before Using This EA

Strengths of the approach. The most interesting feature is that the Directional Flow Reservoir tunes its own entry threshold. Because the band is derived from the reservoir's own recent dispersion, the strategy adapts to changing volatility instead of relying on a fixed number that may suit one regime and fail in another. The dimensionless flow calculation also makes the logic transportable across symbols. The dual-exit design — reservoir release and an ATR stop — means a trade can be closed either when momentum fades or when price moves against it sharply, which is a thoughtful piece of risk logic to study.

Known limitations. Like all trend-following systems, this one is built for directional markets and will tend to underperform in ranging or choppy conditions, where it may enter on a burst of pressure only to be stopped out or released as the move fizzles. Because it acts once per completed bar, entries and exits happen at bar close rather than intrabar, which can introduce slippage relative to the signal. The self-calibrating band also has a subtle trade-off: during long quiet periods the band can become very tight, which may lead to more frequent, lower-quality signals. Finally, the fixed lot size does not scale position size to account equity, so risk per trade is not automatically proportional to your balance.

Where it may struggle. Expect weaker behaviour during news-driven whipsaws, tight consolidations, and low-liquidity sessions where the "typical range" scale can be distorted. No parameter set removes these structural challenges — they are inherent to momentum strategies and worth understanding before you commit real capital.

Risk Management Tips

Sound risk management matters more than any single entry rule. Consider these general principles as part of your education:

Risk Warning

Trading foreign exchange, CFDs, and other leveraged financial instruments involves substantial risk of loss and is not suitable for all investors. The strategies and tools discussed on this page are provided for educational purposes only and do not constitute financial advice, investment recommendations, or solicitation to trade. Always consult a qualified financial adviser before making trading decisions. Past backtest performance is not indicative of future results.

Downloads

← Back to Blog