Trabalho concluído
Termos de Referência
My Expert Advisor.
How it should work.
The EA opens two opposing trades during trading times/days only.
Each trader has their own Take profit and Stop loss lines.
Each trader uses the Martingale strategy.
IF trades are timed out, lot sizes and trade directions are replicated onto their next trades.
EA Trader A.
EA trader A places a buy trade initially but when it makes its next trade it places a sell trade, it continues alternating these trade types as it goes from buy to sell and sell to buy and so on via a prompt from its Take profit and or Stop loss lines.
Therefore, EA trader A has a Take profit line and a Stop loss line.
When either of these lines are activated it prompts the EA trader to make the opposite trade to the previous trade on its next trade and they of course close the current trade as well.
Furthermore, if the Take profit line is activated the lot size is returned to the default setting size on its next trade.
If the Stop loss line is activated, then its current lot size is doubled on its next trade.
Both lines are stationary and are visible while the trade is in play.
These lines are always set at equal distances.
I would like to set them at 100 points as default, but I would like the ability to amend these settings.
The lot size is also set to the standard lot size as default, but I would also like the ability to amend them to either a micro lot or to a nano lot.
If we are timed out, then the EA is to remember the lot sizes for both Trader A and B as well as their trade types (buy or sell) so it can duplicate these settings onto its next trade.
EA Trader B.
EA trader B places a Sell trade initially but when it makes its next trade it places a Buy trade, it continues alternating these trade types as it goes from sell to buy and buy to sell and so on via a prompt from its Take profit and or Stop loss lines.
Therefore, EA trader B has a Take profit line and a Stop loss line.
When either of these lines are activated it prompts the EA trader to make the opposite trade to the previous trade on its next trade and they of course close the current trade.
Furthermore, if the Take profit line is activated the lot size is returned to the default setting size on its next trade.
If the Stop loss line is activated, then its current lot size is doubled onto its next trade.
Both lines are stationary and are visible while the trade is in play.
These lines are always set at equal distances.
I would like to set them at 100 points as default, but I would like the ability to amend these settings.
The lot size is also set to the standard lot size as default, but I would also like the ability to amend them to either a micro lot or to a nano lot.
If we are timed out, then the EA is to remember the lot sizes for both Trader A and B as well as their trade types (buy or sell) so it can duplicate these settings onto its next trade.
Trading clock.
The trading clock is to be shown at the bottom right-hand corner of the chart.
It is to show the Brokers time.
It uses military time namely the 24-hour clock.
It has a start time and a close time.
They are pre-set to trade between 08.01 the start time and 17.01 the closing time.
These are the times that I wish that EA trader A and B to trade between.
EA is to have two visible vertical lines to shows the trading time zones.
First one is Green for the opening time and the second one is Red for the closing times.
The gap between the green and red lines is called the trading zone.
When price touches the Green line, the EA makes its trades.
When price touches the Red line, the EA closes all trades, but it remembers the trade settings (lot sizes and their trade direction buy or sell) for Trader A and B and then it is to duplicates these settings onto Trader A and B’s next trades.
I would like the ability to amend these times.
Weekday Checker.
The EA has a settings box showing settings from Monday to Friday.
The Weekday checker is set to trade Monday to Friday as Default.
I would like the ability to amend these days via the checkbox so I can trade for one or more days if I choose.
EA Requirements.
The EA should work on both accounts live and or demo.
The EA should work on all time frames and chart types.
The EA should work on all currency pairs.
The EA has different lot sizes to choose from.
The EA allows Arbitrage trading. (Max and a minimum of two trades at one time)
The EA has two traders they are Trader A and Trader B.
Each Trader has their own Take profit and Stop loss lines.
Each Trader uses the martingale strategy regardless of trade type.
The EA has a trading clock and a weekday check box.
The EA opens and closes trades during the trading clocks trading times.
The EA is to carry over lot size settings and trade direction for trader A and B when timed out.
I can manually amend all the above.
Scenario examples.
EA first open and close trades.png explanation.
The EA makes its first set of trades at 08.01 am.
Trader A makes a buy and Trader B makes a sell.
They both currently have lot sizes of 1.0.
Price rises and the TP line for Trader A the buy trade is activated, and we secure its profits.
At the same time, the SL line for Trader B the sell trade is activated, and we deduct its losses.
Both trades are closed.
Trader B Stop loss line was activated, therefore its lot size will be doubled on its next trade and its next trade will be a buy.
Trader A had won so its lot size remains at default and its next trade will be a sell.
EA sec open and close.png explanation.
The EA makes its second set of trades during the trading time zones.
Trader A makes a sell and Trader B makes a buy as these traders are alternating their trade types via the previous Take Profit and Stop loss lines activation.
This time as Trader B had lost its trade last time out its lot size is now doubled from 1.0 to 2.0.
Price continues to rise and the TP line for Trader B the buy trade is activated, and the trade is closed.
Therefore, a sell trade is made next time out and its lot size is set back to default.
The Stop loss line is activated for Trader A the sell trade.
Therefore, its lot size is to be doubled and it is to make a buy trade next time.
The trade is closed.
EA 3 trades.png explanation.
The EA makes its third set of trades during the allotted trading times.
Trader A makes a buy and Trader B makes a sell as these traders are alternating the trade types via TP and SL lines.
As Trader A had lost its previous trade its lot size is now doubled from 1.0 to 2.0.
Trade rises and then falls activating Trader B the sell trades Take profit.
Thus, re setting its lot size and making a buy trade next time.
At the same time the Stop loss for Trader A is activated and therefore its lot will be doubled from 2.0 to 4.0.
It will also make a sell trade next time.
As a new candlestick forms outside the trading times no new trades are made that day.
The EA waits until the next allotted time and day before commencing further trades.
Trader A would be a Sell trade with a lot of 4.0 and trader B would be a Buy trade with standard lot of 1.0.