İş Gereklilikleri
I need an expert advisors that:
a) enters a long position when the closing price of a bar is below the lower Bollinger band while the closing price of the previous one was above.
b) a) enters a short position when the closing price of a bar is above the upperBollinger band while the closing price of the previous one was below.
c) Profit is taken on tick anytime the take profit limit defined is pips is reached OR
d) Profit is taken on tick anytime the price comes inside the smaller Bollinger bands “SUPO” and “SLOBO”
e) Stop loss is triggered on tick whenever the Stop loss level is reached.
Further details and structure below…
Inputs :
• N = Number of bars used for AVERAGE and STANDARD DEVIATION calculation
• X= Multiplier of the BigBollinger
• Y= Multiplier of the SmallBollinger
• TP=Take Profit level in pips
• SL=Stop Loss level in pips
• BLK= Slope Blocker Level in % (X.YZ%)
• BEGIN = GMT time where trading starts
• END=GMT time where trading ends
• NOTRADAY=days of the week where trading does not take place
• VOL = volume, number of USD per pip
Variables:
• AVG = simple average of “open, high, low, close” prices for each bar over past N bars
• STDEV = standard deviation of “open, high, low, close” prices for each bar over past N bars
• BUBO = AVG + (X * STDEV) “Big Upper Bollinger of last bar”
• BUBO1 = AVG + (X * STDEV) “Big Upper Bollinger of previous bar”
• SUPO = AVG + (Y * STDEV) “Small Upper Bollinger of last bar ”
• SLOBO = AVG – (Y * STDEV) “Small Lower Bollinger of last bar”
• BILOBO = AVG – (X * STDEV) “Big Lower Bollinger of last bar”
• BILOBO1 = AVG – (X * STDEV) “Big Lower Bollinger of previous bar”
• CL0 = last price of last bar
• CL1=last price of previous bar
• SLOPE = (CL1-CL0)/CL0
Trade Initiation rule :
• Buy and Sell trades are initiated at the time the last price of a bar is released and trading takes place immediately after that
• Stop loss and take profit are triggered anytime a tick reaches the corresponding price
• No trade takes place before GMT time START and any opened trade is closed after GMT time END
• No trade takes place on days of the week specified as NOTRADAY
Trading Rules:
SELL TRADE
On the last price of any bar: IF && CL0>BUBO && CL1<BUBO1 && SLOPE<BLK BUY
Take profit on any tick if:
Profit in pips > TP
OR
IF CLO <= SUPO
Stop loss on any tick if:
Loss in pips >=SL
BUY TRADE
On the last price of any bar: IF && CL0<BILOBO && CL1>BILOBO1; SLOPE>-BLK BUY
Take profit on any tick if:
Profit in pips > TP
OR
IF CLO >= SLOBO
Stop loss on any tick if:
Loss in pips >=SL
• I need the MT4 full source code
• When compiled, the EA must return no error