Using Bollinger Band Edges for Pending Orders in a Forex Example
Summary
This coding example describes a simple Forex robot that places a sell pending order at the upper Bollinger Band and a buy pending order at the lower band. It uses the bands’ central simple moving average as a position-closing level. The shown setup is tied to the 15-minute timeframe, with a note that the timeframe can be changed in the code.
The document explicitly presents the system as a coding illustration rather than a profitable strategy and advises against using it in a live account. It provides no backtest, risk controls, order-management details, or results. In particular, it does not explain how pending orders are updated as bands move, how simultaneous positions are handled, or how transaction costs affect outcomes. The example can help a coder understand how Bollinger Band values might be used in automated order placement, but it offers no evidence that this approach is suitable for trading.
Key ideas
- The example places a sell pending order at the upper Bollinger Band and a buy order at the lower band.
- The central simple moving average is used as a position-closing level.
- The illustrated setup uses a 15-minute timeframe, which can be changed.
- The author labels the example unprofitable and discourages live-account use.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.