Job finished
Specification
Hello developers,
I need EA to make modifications in order that are opened manually also open top up orders.
EA will use a risk management strategy called DIAD - Double in a day
This strategy is based on top ups, an open order can generate up to 3 top ups
The idea of strategy is to double the account in just one operation using the top ups.
---------------------------------------------------
EA needs the following inputs:
% target per trade gain from 10% to 100%
Number of pips for the target TP
Initial SL in pips
% of account to be risked
Top up level 1 in%
Top up level 2 in%
Top up level 3 in%
Spread in pips
--------------------------------------------------
The EA should calculate all the risk with the input information.
The EA must calculate the lot value that will be used in the initial order and in each top up according to the input information
The initial lot value that will be used in the manual order must be calculated by the EA and should be shown in the chart at the top left
The first SL and TP will be placed manually, EA should show this SL and TP of which were also placed in the input settings, at the top left along with the initial lot value as in the following example:

The EA must open the operations of the 3 top ups using the lot calculated by the EA and opening the operation according to the level top up% placed in the input settings
At each Top up, all STOP LOSS should be moved to breakeven, in case breakeven be hit that should give a little PROFIT
Also de EA can be attached in multiple charts and timeframes at the same time
The EA should have alerts for each entry of top up, TP and SL hits, the alerts should be by:
message
sound
notify
email
The alert options must be an input with true or false
EA should work on accounts that are ECN,standard, micro and cent.
The EA should show the operations and target in the graphics as in the following image
Note: BE stands for breakeven
Here is a link for the Excel template with strategy and formulas:
https://1drv.ms/x/s!ApNDR2TbtrLjnt5mVnSJMy445kQL3w
Here's an example of how EA should work:
After all inputs have been placed, EA will calculate the information
at the top left of the chart the EA will show which initial lot value, SL and TP should be used to create the first entry that will be manual.
The manual entry will be placed with the value of lot, SL and TP informed
If SL is hit, EA should not do anything.
If the operation is in favor of the analysis, when the top 1 level is reached the ea must open an order with the values of lot calculated according to the inputs for Top up level 1% and must move the SL of the first manual operation to breakeven, so if the breakeven is reached before Top up level 2 the operation is risk free and must have a little profit as indicated in the excel model. This process should be repeated with the other levels of top ups 2 and 3.
NOTE: if possible have an option in inputs to open a random order, just to test the EA in backtest to validate the tops up. Not mandatory
NOTE: I want the mq4 file