指定
ea. which uses Bollinger Bands to enter a trade. It has 3 different entry strategies.
Break Out: If the last bar closes above the upper band it enters a Sell Order. If
the close of the last bar is below the lower band a Buy Order is generated.
Break In: If the last bar crosses the upper band from above it enters a Sell Order. If
the last bar crosses the lower band from below a Buy Order is generated
Time:
opens with start of a candle on a specific time with buy or sell
Parameters for the Bollinger Bands EA
Timeframe = The timeframe on which the EA should work regardless of what timeframe your chart is set to.
Averaging Period = Averaging period to calculate the main line (default is 20)
Standard Deviation = Deviation from the
main line (default is 2)
Bands Shift = The indicator shift relative to the chart (default is 0)
The exit strategy is martingale system with pending orders which has
Start lot size
Take profit = Martingale pip step if reached in the opposite direction
Stop loss = Max number of orders
Multiplier
Martingale pip step
Trailing stop with pips
start trading at - specific time < for break out and in
stop trading at - specific time < for break out and in
It must have an option to trade on the same bar for break in and on the next bar
it must a reverse strategy for break in and out
max spread to open trades
it must not open more than ONE process at a time for example:
the process is the number of orders needed for take profit or is forced to close buy stop loss
1 st scenario the break out is active and the take profit is 50 pip , the candle closed above the bb line > sell order is triggered the next candle yet it didn’t reach the take profit and this candle also closed above the line > no other trade shall open in this situation.
2 nd scenario the break out is active and the take profit is 50 pip , the candle closed above the bb line > sell order is triggered the next candle let’s say with a 0.01 lot size but the candle went up buy 50 pips so the martingale is activated and a buy pending order with 0.02 if the multiplier is set to 2 was triggered yet all the candles close above the line > no other trade with 0.01 lot size shall open with the next candle in this situation.
I want to have mt4 ea with source code.