Develop an MT4 expert advisor that triggers trades and adjusts loss making trades using the profitable trades

Tâche terminée

Temps d'exécution 11 jours
Commentaires du client
Exceptional work. Many developers tried to make this EA work for me but failed. Eric managed to get it done correctly. I am impressed. Thank you Eric.

Spécifications

Developers from Africa should not apply for this job.


Green candle means - Closing price is greater than Opening price.
Red candle means - Closing price is less than Opening price.

Timing Of Triggering Trades:

1 trade is triggered every time a candle closes, except on the candle that ends are rollover time. The candle that closes at 0:00 will also trigger a trade but it should be 300seconds before so it would trigger at 23:55:00

If the chart timeframe if H1 then 23 trades will be triggered when the candle closes and 1 trade will be triggered at 23:55:00
If the chart timeframe if H4 then 5 trades will be triggered when the candle closes and 1 trade will be triggered at 23:55:00
If the chart timeframe if D1 then there is only 1 trade per day and it will be triggered at 23:55:00


The conditions & direction of trades:

If a candle is green and it is time to trigger a trade EA will trigger a Buy trade
If a candle is red and it is time to trigger a trade EA will trigger a Sell trade


Types of trades & workings of EA

Settings – Input Section
Main Trade Size = 0.10 lots
Main Trade Profit = 0.00100
The EA first triggers a Main Trade let’s say it is a 0.10 lot buy order @ 1.17200 and feeds in take profit level of 1.17300
Price goes up and hits take profit. Trade closes. Next time conditions are met since there are no active trades, EA again triggers a Main Trade.


Settings – Input Section
Counter Trade Size = 0.70 lots
Counter Trade Profit = 0.00100

IF however, price does not reach 1.17300, but instead moves down. When the conditions are met EA triggers a Counter Trade and let’s say it is a 0.70 lot sell order @ 1.16850 and feeds in take profit level of 1.6750

Price moves down further, and hits take profit. A profit of 100 points x 0.70 lots = $70 – commission charges = $65 net profit

Now the EA automatically adjusts the loss of the Main trade. The Main Trade is currently making a loss of 1.17200 – 1.16750 = 450 points x 0.10 lots = $45 + commission charges = lets say this is $48

The EA just closes the entire 0.10 Main trade since the loss of the Main Trade is less than the profit of the Counter Trade.

If however, the active loss was something like $95 and the Counter Trade profit was $65 then the EA would only close part of the Main Trade. ($65/$95)x100 = It would close less than 68.42% of the Main Trade so 0.06842 lots but rounded down so it would close 0.06 lots

0.04 lots of the main trade would remain active. Now conditions for a new trade are met again and a new trade is triggered. It will be a Counter Trade again since there is an active Main Trade that is in a loss.

*Note* The gross profit must be taken from the terminal since the above calculation will not always be accurate. If we are trading the EURAUD chart and funds are in USD then there will be a conversion rate due to which the profit might be 35% or 30% lower. Therefore, we take the profit from the terminal – commission – swap charges to land the net profit.

Similarly, the loss on the loss making trade should also be calculated from the terminal.

In this way the Counter Trades will be placed again and again until all the Trades are closed. Counter Trades will also be placed to reduce losses on other loss-making counter trades. It is not only restricted to reducing the losses on Main Trades.

Counter Trades will be restricted when trades are in profit.

In some cases, I need the EA to restrict placing a trade. This is when another active trade is in profit. So, if there is a buy order at 1.12530 with take profit 1.12630 (whether it is a Main Trade or a Counter Trade). If price rises to 1.12670 and the time comes to trigger another buy order, the EA will not place this trade since there is an active buy order in profit. However, if the price was 1.12620 then it would trigger the trade.

Therefore by this logic if there is an active trade at 1.12630 then the EA will only place another buy order if the price is lower than 1.12630

The same rule applies for sell orders. If there is an active sell order at 1.10450 then it can place another sell order only at prices above 1.10450

Répondu

1
Développeur 1
Évaluation
(74)
Projets
121
43%
Arbitrage
12
33% / 50%
En retard
17
14%
Gratuit
2
Développeur 2
Évaluation
(557)
Projets
924
48%
Arbitrage
301
59% / 25%
En retard
123
13%
Chargé
3
Développeur 3
Évaluation
(272)
Projets
394
63%
Arbitrage
70
53% / 26%
En retard
198
50%
Gratuit
4
Développeur 4
Évaluation
(11)
Projets
12
42%
Arbitrage
2
0% / 50%
En retard
0
Chargé
Commandes similaires
I need someone to help me convert my tradingview pinescript to mt4, my budget for this project is $20 and I need this done fast in two days, Also, I am going to need you to be able to build a new indicator because that's the nest project, But I need to know if you can do this first , Thank you
I need you to convert my tradingview pinescript to mt4, I have just $10 for it now, But i am going to give you more work later on cause i still have more work i am going to need you to work on for me, and i will be paying with crypto, Thank You
Hello, I am in need of an expert to help me convert my tradingview pinescript to mt4, I will attach the file, But for now, I only got $15 for this project and the only payment method I can use right now is crypto, I will send it to you through crypto, Also I need someone that is ready to work because I still have lot of projects I will need him to do for me
Hi, Use MQL5 connect to only one binance websocket API: binance.com/stream?streams=btcusdt@aggTrade and get the returned data successfully(you no need process returned data). MUST use this MQL library to connect binnace: https://www.mql5.com/en/articles/8196 Source code need Related binance websocket document: https://binance-docs.github.io/apidocs/spot/en/#websocket-market-streams Thanks
Hi, I want a custom indicator to be coded based on 2 default Indicators. Add alerts for signals and news filter alerts to be sent through metaquotes id, email and phone. Popup alerts for pc/laptop as well. I would like it to have a display panel that logs the trade history and a buy/sell button with risk % based on balance and equity, fixed lots and some other features
Hello I am looking for a developer to help me do modification on my custom ninjatrader 8 strategy and also backtest it in other to work perfectly your expertise is highly needed for this project Kindly reach out to me and let get started on the project Thanks
Hello I'm in possesion of a straightforward MT% Expert AdvisorThat I want to convert into DXTrade. Are you able to do this conversion? Kindly let me know if the fil atached will be enough
Hello, I need a quote for developing a bot for my renko based trading system on ctrader platform and based on the attached specification your expertise is highly needed for this project Thanks
Hello, please let me know if any of these strategies can be turned into a bot (automation) and run 24/7 on a vps. Also note that they might not use the latest versions of indicators, if this matters, then please check for the latest versions. Thank you! Dan https://1drv.ms/f/s!Alr17W7ddJLYgYgiFKZYluOfokbfQg
Hello! Thanks for reading. I need an EA with an inbuilt/already made strategy that I can use for prop firms. The drawdown should be very low of only 2-4% max and another criteria is that no one else other than you are currently using it and if you happen to use it you must tell me which prop firm you are using it on to avoid us using the same EA on the same prop firm to get the account denied. As you know or may

Informations sur le projet

Budget
50+ USD
Pour le développeur
45 USD
Délais
de 1 à 4 jour(s)