DCA EA

MQL4 Experts Scripts

Job finished

Execution time 138 days

Specification

DCA EA by Trail Results

Please Fully Read and ask questions to insure you can do this job.

Overview

Looking to have an EA that will operate similar to a grid EA with a few differences. The EA will subtract the “current market price” from the “lowest market price”(from the chart) or the “lowest price” that we input. We then take that difference and divide it into equal parts that we specify in the inputs. Once the EA takes profit it will reset using the new “current market price”, and start the process over again. 


Dividing up the trades

The math to divide up the trades is taking the “current market price” and the “lowest market price” and dividing it by a number we input + the “lowest market price” or whatever we input as the “lowest market price”. So if the current market price is 200 and the lowest is 5 and we input to divide the trades by 4, it’ll be 200-5=195 then 195/4=48.5 so a new trade will enter every 48.5 as it goes down until it reaches 5 and 5 is where the 1 additional trade will be added. So it'll actually place 5 trades in this scenario even though the input was set to only divided by 4. It’ll work the same way no matter how many we order we divide into. It'll always add the all time low or lowest price input as an additional trade.


Scaling into trades

As the market price goes lower it enters the new trades which will change the cost basis or average price for that position. The take profit will adjust with the new cost basis also. For example: If the starting market price was at 100 and the lowest market price was 1, we then divide it into 4 parts,(4 parts including 1 for the lowest price we input) so it will place new trades every 24.75 pips((100-1)/4). So the first trade will be at 100, second trade at 75.25, 3rd trade at 50.50, 4th trade at 25.75, and 5th trade at 1. Let's say it goes down to 1 and the lot size is the 1 for each level. The cost bases would be 50.5((100+75.25+50.50+25.75+1) / 5). So the take profit % we input would be based on the new cost basis or average. Let's say the take profit % is 100%, the EA would close all the trades at 101(50.5+50.5) and restart the EA using 101 as the new market price.


Dynamic lots

Taking the current market price and subtracting it from the lowest market price either from the chart or one we specify in the inputs. Then dividing it by the “Divide Trades input”. Then take that answer and subtract it from the market price the same number of times you previously divided by. Now take those figures and divide them all by the "divided risk amount" to get the Dynamic Lot size for each trade as the market price goes down.  


So here's a example

  • Current market Price on the chart: 225

  • Lower price on the chart: 4

  • Divide high and low difference by: 4

  • Divide Risk amount per Sequence by: 5 (Will always be 1 more than the “Divide high and low difference by X” input above)

  • Amount to risk per sequence: $1000


So well have: 

225-4=221 then 221/4=55.25 now 221, 221-55.25=165.75, 165.75-55.25=110.5, 110.5-55.25=55.25

Now $1000/5=$200 so we have:

$200/221=.90 lots for trade 1, $200/165.75=1.21 lots for trade 2, $200/110.5=1.81 lots for trade 3..., $200/55.25=3.62 lots for trade 4 and $200/4=50 lots for trade 5 to finish that sequence.


A Sequence is when one set of orders is running. For the example above that would be 5 trades for that sequence starting at the 225 price. We would like the ability to  push a button on the charts that'll add additional sequences to the same pair, independent from the first sequence that was already entered. So using the example from above, well have 1 set of 5 trades running, then another set of 5 trades can start running at another starting price and so on. The only thing that all the sequences have in common is the averaging cost basis and take profit level if it is the same pair. So multiple sequences on the same pair will all work together to lower the cost bases and will all take profit at the same time.


Pending orders in the sequence

Once an initial trade is entered, the pending orders should only appear 1 at a time. So if there are 5 orders for a sequence, once the first trade has entered the market the 2nd trade should appear as a pending order, and once the second trade level is hit, the 3rd pending order should appear and so on.


INPUTS

  • Current market price - If 0 use the current market price

  • Lowest market price - If 0 use the lowest price on the chart

  • Divide high and low difference by: X

  • Use % of equity to trade per sequence: (true or false)

  • % of equity to trade per sequence: X

  • Use $ amount to be risked per sequence: (true or false)

  • $ amount to be risked per sequence: X

  • Dynamic Lots per Sequence (True or False)

  • Divide Risk amount per Sequence by: X (Will always be 1 more than the “Divide high and low difference by X” input above) not sure if this input is needed..

  • Take profit per pair in % (true or false)

  • Take profit per pair in %: X

  • Take profit per pair in  $ (true or false)

  • Take profit per pair in  $: X

  • Add another sequence of trades each time we place a manual trade: (True or False)



On chart display

Buy Button:

We need a on chart button to place manual buys that will start a sequence at the price we place the buys at, and if we start multiple sequences it will use all the sequences to calculate 1 cost basis. And all the trades for all the sequences will take profit and restart.


Close pair trades button. Will Close all the trades for the chart it's on.

Close all trades button. Will close all open and pending trades for all pairs.

We also need an on screen legend to display the cost bases for each pair traded with a line on the chart to show the cost bases and the take profit levels.

Responded

1
Developer 1
Rating
(10)
Projects
12
42%
Arbitration
2
50% / 50%
Overdue
1
8%
Free
2
Developer 2
Rating
(62)
Projects
84
26%
Arbitration
22
23% / 50%
Overdue
23
27%
Working
3
Developer 3
Rating
(7)
Projects
14
21%
Arbitration
1
0% / 100%
Overdue
3
21%
Free
4
Developer 4
Rating
(1)
Projects
2
0%
Arbitration
1
0% / 100%
Overdue
0
Free
5
Developer 5
Rating
(194)
Projects
198
27%
Arbitration
0
Overdue
3
2%
Free
6
Developer 6
Rating
(55)
Projects
80
54%
Arbitration
9
33% / 33%
Overdue
7
9%
Working
7
Developer 7
Rating
(264)
Projects
538
50%
Arbitration
55
40% / 36%
Overdue
224
42%
Working
8
Developer 8
Rating
(143)
Projects
255
35%
Arbitration
12
25% / 58%
Overdue
42
16%
Free
9
Developer 9
Rating
(253)
Projects
406
38%
Arbitration
84
43% / 19%
Overdue
70
17%
Working
Similar orders
Additions 1. Trailing by points is available, add trailing by money 2. Once certain DD is reached hedge with opposite positions, close all positions of one side [buy or sell] when they are in profit by say 5 points and start martingale to close the other side of trades by summing up all open trade quantities and opening the same quantity at the same time of closing profitable trades of one side following changes
Hi I need a experience programmer to build me 1 harmonic pattern EA scanner that send alert with arrow on screen without open trades Multiple times frame M15 H1 H4 D1 W1 MN multiple currency pairs and i want to see all historical patterns that already happened
The specifications cover 4 requests: 1- Addition of a Trailing Take Profit function 2- Addition of a function to calculate the distance according to a decreasing mode (20, 15, 10, 5...pips) 3- Addition of a function Global Profit decrement /increment size in pourcentage 4- E rror s correction in coding
i want an mt4 indicator Daily Opening Price (24 Range Horizontal Line) : Calculate the daily opening price based on the 24-hour range. Display this price as a horizontal line on the chart. Color the line green. 7:30 AM EST Opening Price (Orange Line) : Determine the opening price at 7:30 AM EST. Display this price as a horizontal line on the chart. Color the line orange. High and Low of the London Session (Blue
Can you convert my tradingview indicator into a mt4 ea ? Indicator called ut bot alerts on tradingview Its open script already Will my ea have same settings for the indicator as in the indicator version on tradingview ? And I need trailing input added Daily equity protector as well Also for inputs I need option for it to close existing trade when opposite confirmed Also input for time schedule to trade Like New York
Hello, I need a professional programmer to help me design an EA that can be able to take trades towards a market direction with accurate prediction. This EA should be able to identify the market trend direction and take multiple trades towards the direction and also able to close the trades together when market wants to reverse at the best profit level. The input at the beginning will be for the EA to be input with a
Hello, I have EA's which were previously developed that are not running correctly and giving errors. Need an experienced MQL developer to fix all issues as well as add some new settings. Thanks
Looking for a developer to create an MT4 indicator and an EA / Robot. Indicator-based strategy consisting of several moving averages, PSAR Indicator and Pinescript indicator called Coral Trend Indicator by LazyBear (pinescript source code will be provided and will need converting to MT4 code - 34 lines of code). Strategy to be an intra-day trading period on 5-minute timeframe for the European session but “Trading”
Need a simple EA That opens a long position if the MA cross up above another MA and opens a short position if the MA cross down below another MA . - The EA should only allow for one position to be open at any given time. It should close the current position if it is going to open a new position. - I want to have option to input for a lot size, a stop loss, take profit, and an input for total profit/loss USD - I want
Pls good people my budget is $50 . I have choch indicator I want to use it for my strategy but the ea will have two options the second option will base on manual example I will do my analysis of a pair then decide if buy or sell before putting those pairs in the ea base on the direction I choose for it but first option will make use of the indicator. Will explain better on video screen pls check my attachments below

Project information

Budget
80+ USD
For the developer
72 USD