Expert Advisor that closes open positions on the chart if average profit in pips/points on all open positions is achieved

MQL4 Experten Skripte

Spezifikation

I am looking for an expert advisor that manages open positions on my MT4 platform (Broker Details: FXCM; 5 Digits account; 30:1 leverage; Instruments: FX & CFDs) that are manually openend.

Logic: If average profit from all open positions in FX-Pair/CFD-contract is more than X-amount in pips/points, then close x-% of all open positions

Example: 

1.    If the average profit from all open positions in EURUSD is:

a.    more than 10 pips/points, then close 33% of all open positions

b.    more than 20 pips/points, then close 33% of all open positions

c.    more than 30 pips/points, then close 33% of all open positions

2.    If there are for example 5 positions open at the moment the first profit target is reached, the EA should close 2 positions (so round up because it is not possible to close 1,66 (5*33%) positions). If the second profit target is reached (and there were no new positions created in the meantime) the EA should close 1 position ((5-2)*33% = 1)

3.    While the EA is running in the background, the programm always has to monitor the change in open positions. So in case new positions are manually openend or closed the EA has to recalculate its next operations.

a.    Example from above: If the Second profit target was reached and there were new positions entered in the meantime, the EA should start with the initial configuation, so that if the „new“ average profit from all open positions in EURUSD is:

                                       i.    more than 10 pips/points, then close 33% of all open positions

                                      ii.    more than 20 pips/points, then close 33% of all open positions

                                    iii.    more than 30 pips/points, then close 33% of all open positions

4.    The EA should either use the FIFO (First in First out) or LIFO (Last in First out) principle, when closing positions

5.    I would like to enter several closing instructions; i.e.:

a.    1) If the average profit then…

b.    2) If the average profit then…

c.    3) If the average profit…

d.   

ð  If there needs to be a limit, than I would prefer 3 different closing instructions

6.    Under some circumstances the EA also needs to be able to work with magic numbers, so that it only closes positions that were assigned a certain magic number (on/off function).


Bewerbungen

1
Entwickler 1
Bewertung
(52)
Projekte
133
44%
Schlichtung
14
50% / 29%
Frist nicht eingehalten
55
41%
Frei
2
Entwickler 2
Bewertung
(885)
Projekte
1410
67%
Schlichtung
123
32% / 41%
Frist nicht eingehalten
218
15%
Frei
Veröffentlicht: 1 Beispiel
3
Entwickler 3
Bewertung
(84)
Projekte
149
31%
Schlichtung
32
34% / 41%
Frist nicht eingehalten
43
29%
Frei
4
Entwickler 4
Bewertung
(1235)
Projekte
2820
80%
Schlichtung
156
22% / 43%
Frist nicht eingehalten
487
17%
Frei
5
Entwickler 5
Bewertung
(206)
Projekte
333
35%
Schlichtung
66
12% / 58%
Frist nicht eingehalten
87
26%
Frei
6
Entwickler 6
Bewertung
(221)
Projekte
369
66%
Schlichtung
10
50% / 0%
Frist nicht eingehalten
46
12%
Frei
7
Entwickler 7
Bewertung
(33)
Projekte
49
12%
Schlichtung
16
0% / 88%
Frist nicht eingehalten
10
20%
Frei
8
Entwickler 8
Bewertung
(629)
Projekte
849
47%
Schlichtung
29
38% / 14%
Frist nicht eingehalten
63
7%
Arbeitet
9
Entwickler 9
Bewertung
(52)
Projekte
89
25%
Schlichtung
8
75% / 13%
Frist nicht eingehalten
44
49%
Beschäftigt
10
Entwickler 10
Bewertung
(33)
Projekte
35
40%
Schlichtung
11
9% / 91%
Frist nicht eingehalten
4
11%
Frei
Veröffentlicht: 4 Beispiele
11
Entwickler 11
Bewertung
(136)
Projekte
196
43%
Schlichtung
17
29% / 59%
Frist nicht eingehalten
28
14%
Frei
12
Entwickler 12
Bewertung
(59)
Projekte
182
55%
Schlichtung
31
45% / 16%
Frist nicht eingehalten
103
57%
Frei
13
Entwickler 13
Bewertung
(195)
Projekte
395
28%
Schlichtung
155
20% / 52%
Frist nicht eingehalten
112
28%
Frei
14
Entwickler 14
Bewertung
(493)
Projekte
1022
58%
Schlichtung
30
27% / 23%
Frist nicht eingehalten
133
13%
Arbeitet
15
Entwickler 15
Bewertung
(2643)
Projekte
3359
68%
Schlichtung
77
48% / 14%
Frist nicht eingehalten
342
10%
Arbeitet
Veröffentlicht: 1 Beispiel
16
Entwickler 16
Bewertung
(43)
Projekte
74
50%
Schlichtung
5
0% / 60%
Frist nicht eingehalten
19
26%
Frei
17
Entwickler 17
Bewertung
(65)
Projekte
87
39%
Schlichtung
3
0% / 33%
Frist nicht eingehalten
29
33%
Frei
18
Entwickler 18
Bewertung
(574)
Projekte
945
47%
Schlichtung
309
58% / 27%
Frist nicht eingehalten
125
13%
Frei
19
Entwickler 19
Bewertung
(69)
Projekte
146
34%
Schlichtung
13
8% / 62%
Frist nicht eingehalten
26
18%
Frei
Veröffentlicht: 6 Beispiele
20
Entwickler 20
Bewertung
(1)
Projekte
1
0%
Schlichtung
1
0% / 100%
Frist nicht eingehalten
0
Frei

Projektdetails

Budget
50 - 150 USD