EA to Close Trades Using Exchange File

MQL4 Эксперты

Работа завершена

Время выполнения 20 часов
Отзыв от исполнителя
His project description is very clear. He is smart and professional in EA description.5 stars. Thank you.
Отзыв от заказчика
He demonstrated his professional skills when he completed the job correctly and promptly. Great work!

Техническое задание

I need an EA that compares the candle close price of 2 MT4 terminals, and closes trades according to a formula. I already have a seperate arbitrage EA to open and close the trades. This EA that you are doing will add an additional method to close the trade, in case the original EA fails to close it. Reliability and stability of this EA is the priority.


On the same computer, I will use 2 MT4 terminals - Primary MT4 and Secondary MT4. There will also be 2 EAs - Primary EA and Secondary EA. The Primary EA will be installed in Primary MT4 M1 chart. Secondary EA will be installed in Secondary MT4 M1 chart. There will be one Secondary EA, and one Primary EA.

The Secondary EA will send candle close prices (bid price) of all the symbols in the market watch to an exchange file. This exchange file is to be located in C:\Users\Username\AppData\Roaming\MetaQuotes\Terminal\Common\Files. The secondary will send the candle close prices of the previous minute and the previous previous minute, as well as the corresponding time of the candle. For example, if the broker time is 10:03:23, secondary EA will send the close prices of the 10:02 and 10:01 candles, and their candle times. For each symbol in the secondary market watch, the exchange file will contain 4 data: 10:01 candle close price, 10:01 candle time, 10:02 candle close price, 10:02 candle time. Secondary EA will update the exchange file every second. So whenever a new candle is formed, the exchange file will get updated. The exchange file will contain data for all the symbols in the market watch.

This is an example of what the exchange file should look like. You can use a different format, as long as all the required data is included.
AUDCAD 10:01 0.91978
AUDCAD 10:02 0.91944
AUDJPY 10:01 80.381
AUDJPY 10:02 80.393
GBPAUD 10:01 1.87760
GBPAUD 10:02 1.87743

etc



The Primary EA will read the exchange file every second. First, it will look at the same symbol. Then, it will look at the secondary MT4 candle times, and compare that candle to the same candle in the primary MT4. For example, for each symbol, the primary EA will look at the 10:01 and 10:02 candle in the primary MT4, and compare it to the same candle in the exchange file.


The Primary EA will close trades according to the following formula:

Close trade condition:
(ClosePrimary - CloseSecondary) of previous minute = (ClosePrimary - CloseSecondary) of previous previous minute

ClosePrimary- Candle closing price of primary MT4
CloseSecondary- Candle closing price of secondary MT4


The Primary EA will do this calculation every second to check the close trade condition. This calculation is done for all the symbols. For any particular symbol, if the close trade conditions are met, all trades of that symbol will close.

Please show the calculation in the Experts log when Primary EA closes a trade. This is so that I can check if calculation is correct. 

Sometimes, the broker will have missing candles. If any of the 4 candles are missing, calculation cannot be done and EA does not close trade. EA will wait until all 4 candle data are present before doing a calculation.



Note 1: Primary MT4 and Secondary MT4 are using same broker and have the same broker time.
Note 2: The suffix of the Primary and Secondary MT4 are different. Maybe I need to input the suffix in the EA settings.


Откликнулись

1
Разработчик 1
Оценка
(30)
Проекты
52
52%
Арбитраж
6
0% / 100%
Просрочено
18
35%
Свободен
2
Разработчик 2
Оценка
(103)
Проекты
119
32%
Арбитраж
4
0% / 50%
Просрочено
2
2%
Свободен
3
Разработчик 3
Оценка
(5)
Проекты
6
50%
Арбитраж
2
0% / 50%
Просрочено
0
Свободен
4
Разработчик 4
Оценка
(42)
Проекты
47
30%
Арбитраж
12
17% / 75%
Просрочено
6
13%
Свободен
5
Разработчик 5
Оценка
(155)
Проекты
239
70%
Арбитраж
3
67% / 33%
Просрочено
20
8%
Свободен
6
Разработчик 6
Оценка
(63)
Проекты
84
26%
Арбитраж
23
22% / 48%
Просрочено
23
27%
Свободен
Похожие заказы
Hello, send robot models with a solid strategy (to trade forex), I want to use it to make money for the week. It is important that you present me with your profitability graph and a test. I also want to hire him for future jobs
I am looking to develop an automated trading bot based on a strategy involving the crossing of four Simple Moving Averages (SMA). The bot should be capable of entering trades based on this strategy. Additionally, I would like to incorporate some custom diversions tailored for NinjaTrader
Seeking an experienced MQL5 developer to create a sophisticated Expert Advisor focused on harmonic pattern trading . The EA will be designed to identify and trade based on popular harmonic patterns in the forex market. Entry and Exit Logic: Develop smart entry and exit rules based on pattern completions and price action confirmations. Risk Management: Incorporate adjustable risk-per-trade settings and position sizing
preciso de um robô com duas médias móveis, uma exponencial high e uma exponencial low. preciso também ter a opção de utilizar e todos os tempos gráficos e alterar os parâmetros das médias. entrada de compra será feita quando um candle de alta romper e fechar a cima da média high e fechará a posição quando um candle de baixa romper e fechar a baixo da média low. a venda será feita quando o candle de baixa romper e
Description - An expert advisor(s), placing sell trades in EUR/USD, based on the close price of the previous two candles, as shown in the figure below. The trades would be made in the 5 minute, 1 hour, and 1 day timeframes. In the 5 minute and 1 hour timeframes the market orders would be placed at the start of a new candle, at specific times EST. The order would be cancelled at the close of that candle, i.e after 5
Hi, I have an indicator from my friend, I want to copy it to my own Traidingview or MT5 can you do that for me. Here is the link
Develop a simple trading robot from rainbow oscillator Additional features Include timeframe specification in rainbow oscillator trailing features moving average filter TP (true/false) SL (true/false) Fixed lot Risk percentage Percentage profit lock
Hi, I have an indicator from my friend, I want to copy it to my own Traidingview or MT5 can you do that for me. Here is the link
I need a dashboard that shows my various accounts that shows balance, equity, number of trades open, drawdown and some more information. I want to use it to monitor my accounts in one screen or chart. If there is anyone who can do it please show me the screenshot of your sample
Hi, I need a robot, which wil get instructions to trade in 3 symbols at the same time based on few parameters and calculations. Example: There is 1 symbol called Gold-Near and the rate for it is 1000-1002 If i specify that when the rate reaches 1050, it should sell 1 lot Upon execution it will have to sell 1 lot of cme gold, buy 3 lots of mcx gold and buy currently (lots will be based on calculation). All the

Информация о проекте

Бюджет
50+ USD
Исполнителю
45 USD