EA-13678 · Scalping

negative_spread_FORTS

This EA exploits negative spread conditions (when bid > ask) on the FORTS (Russian derivatives) market by placing pending limit orders at the favorable side of the book. It opens a SELL_LIMIT at bid when negative spread is detected, then immediately attempts to close the position with a BUY_LIMIT at ask, capturing the inverted spread as profit. The strategy relies on order book depth events rather than technical indicators.

Open the interactive view (equity curve, symbol switch)

Key facts

CategoryScalping
RiskHigh risk
Rating★★☆☆☆
TypeTrading EA
TimeframesM1, M5
IndicatorsOrder Book (Depth of Market)
Author1987pavlov

Backtest results (H1, about 1 year)

Not backtested yet — this EA could not be converted automatically.

Strategy analysis

The strategy concept exploits rare negative spread anomalies in the market order book where bid exceeds ask, creating a risk-free arbitrage opportunity. Entry conditions are triggered in OnBookEvent when the best ask minus the best bid is less than zero, detected by iterating through MqlBookInfo entries. The FORTS version places a SELL_LIMIT pending order at the bid price, while the standard version immediately sends a market sell order. Exit conditions differ between versions: the FORTS version places a BUY_LIMIT at ask to close the position, while the standard version uses CTrade.PositionClose to close immediately after opening. Position sizing is fixed via the Lots input parameter with no dynamic adjustment or risk-based sizing. Money management is essentially absent — TP and SL are set to 5000 points but the FORTS version does not set TP for sell orders, and orders are either quickly filled or deleted, making stop-loss and take-profit largely irrelevant. A significant risk is the blocking while-loop that waits for position changes, which could freeze the EA or cause timeout issues during periods of market stress.

Strengths

  • Exploits market microstructure anomalies (negative spread) for arbitrage, theoretically a low-risk strategy
  • Triggered by order book depth data (Level 2), enabling faster response than typical tick-driven strategies
  • FORTS version uses pending limit orders instead of market orders, providing better price control and execution timing

Weaknesses

  • Blocking while-loops waiting for execution can freeze the EA or cause timeout errors — a critical programming flaw
  • FORTS version does not set TP for sell orders, and the SL/TP parameters are practically useless for quickly filled or cancelled pending orders
  • Lacks frequency control and deduplication — the same negative spread event could trigger a flood of duplicate orders
  • Negative spreads are extremely rare and fleeting in real markets, making the strategy's practical utility very limited

Possible improvements

  • Replace blocking while-loops with a non-blocking state machine pattern using OnTrade or OnBookEvent callbacks for execution confirmation to prevent EA freezing
  • Add order frequency limiting and deduplication logic to prevent duplicate orders from the same event; implement order book data validity checks and timeout protection

Risk assessment

Overall risk: High risk

  • Blocking while-loops can cause EA unresponsiveness, preventing timely action during extreme market volatility
  • No order frequency limiting — sustained negative spread could trigger a flood of orders, risking exchange penalty or ban
  • SELL_LIMIT orders lack TP — if the close order fails after fill, an unprotected naked position remains open

Evaluation scores

Code quality2.0
Strategy logic3.0
Risk management1.0
Robustness1.0
Innovation3.0
Documentation1.0
Overall1.8

Parameters

ParameterDefaultDescription
Lots1Trade lot size
TpPips5000Take profit in pips
SlPips5000Stop loss in pips
FillingORDER_FILLING_RETURNOrder filling type

Similar Scalping EAs

Backtests are historical simulations and do not guarantee future results. Not financial advice.

Get the weekly Arena report

One email a week: ranking changes, new signals and new research. No spam; unsubscribe any time.