Skip to content
All library documents

BHS Expert Advisor: Round-Price Stop Orders with an Adaptive Moving Average

Article MQL5 code base

Summary

The BHS Expert Advisor uses an adaptive moving average (AMA) and nearby round-number prices to choose an initial pending order. When the current bar's close is above the indicator, it places a Buy Stop at the next upper round price; when the close is below, it places a Sell Stop at the next lower round price. The round-price spacing is configurable. Pending orders also receive an expiration time based on the last known server time, and buy and sell positions have separately configured trailing stops.

Inputs include trade volume, side-specific stop losses and trailing stops, round-price step, pending-order lifetime, and an EA identifier. The document describes the mechanics and mentions testing on EURUSD hourly data, but gives no test period, performance statistics, or risk-adjusted results. It does not specify enough detail to assess entry frequency, execution assumptions, or whether the method has an advantage across instruments and market conditions.

Key ideas

  • The EA selects Buy Stop or Sell Stop direction according to the close's position relative to AMA.
  • Entry orders are placed at configurable upper or lower round-number prices.
  • Pending orders expire after a configured lifetime, and buy and sell positions use separate trailing stops.
  • The listed settings include volume, stop losses, price step, lifetime, and a unique EA identifier.
  • The document mentions EURUSD hourly testing but reports no results or evaluation details.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.