Questions from a "dummy" - page 193

 
G001: I am writing an informative indicator. But data does not matchttp://championship.mql5.com/2012/en/users/wlagor Help find the error. Thank you
Judging by the formula, expected payoff is a result of simple division. Try to print the divisor and divisible, which is calculated by your code.
 

) Sorry, I added the wrong code, here'sthe expectation:

double ExpectedPayoff = (1.0*ProfitTrades()/TotalTrades())*(GrossProfit()/ProfitTrades())+
(1.0*LossTrades()/TotalTrades())*(GrossLoss()/LossTrades());

I have a different problem there )

 

All fixedthe expectation, added:

      + HistoryDealGetDouble(Ticket,DEAL_COMMISSION)
      + HistoryDealGetDouble(Ticket,DEAL_SWAP);
 

Good afternoon. Does anyone know: is the structure of double different on different processors (mantissa, sign and degree position)?

 
Hello. Can you please tell me how to transfer number double from one terminal (MT4) to another (MT5). I can't transfer it through a file as only the terminal folder can be used. Maybe through a memory cell somehow?
Документация по MQL5: Стандартные константы, перечисления и структуры / Состояние окружения / Состояние клиентского терминала
Документация по MQL5: Стандартные константы, перечисления и структуры / Состояние окружения / Состояние клиентского терминала
  • www.mql5.com
Стандартные константы, перечисления и структуры / Состояние окружения / Состояние клиентского терминала - Документация по MQL5
 
lsvit:

Hello. Can you please tell me how to transfer number double from one terminal (MT4) to another (MT5). I can't transfer it through a file as only a folder of the terminal can be used. Maybe through a memory cell somehow?

https://www.mql5.com/ru/code/817

There is a link to MQL4 part and source DLL projects

Мониторинг котировок (пример для маппинга)
Мониторинг котировок (пример для маппинга)
  • votes: 12
  • 2012.01.13
  • o_O
  • www.mql5.com
Пример использования DLL для работы с функциями File Mapping. В данном примере запущенный эксперт создает виртуальный файл в памяти и начинает обновлять в нем котировку символа. При запуске экспертов в других терминалах, эти эксперты открывают созданный файл и аналогично начинают обновлять свои котировки в нем. Таким образом, эксперты через один общий файл обмениваются своими котировками.
 
Is it possible in MT5 to trade on the same currency pair using different strategies, for example as it was possible to do in MT4, using different magic numbers for different strategies? I understand that in MT5 there is only one common position for each instrument. I would like to know if it is possible to use one account for 2 strategies instead of two separate ones?
 
solandr:
Is it possible in MT5 to trade on the same currency pair using different strategies, like you could do in MT4, using different magic numbers for different strategies? I understand that in MT5 there is only one common position for each instrument. I would like to know if it is possible to use one account for 2 strategies instead of 2 separate ones.

Can.

You would need an EA (master) that receives trade orders from others in the form of chart events or something else. He or she will maintain the aggregate position and keep records of magicians. We cannot do without virtual orders here. There is an article on this topic, search for it.

Документация по MQL5: Стандартные константы, перечисления и структуры / Торговые константы / Типы торговых операций
Документация по MQL5: Стандартные константы, перечисления и структуры / Торговые константы / Типы торговых операций
  • www.mql5.com
Стандартные константы, перечисления и структуры / Торговые константы / Типы торговых операций - Документация по MQL5
 
joo:

You can.

For this, we need an EA (master) that takes trade orders from others in the form of chart events or whatever. This EA will be engaged in maintaining an aggregate position and keeping records of magicians. We cannot do without virtual orders here. There is an article on this topic, search for it.

Wouldn't it be easier not to mess around with magicians and just hold a position for each strategy.

Essentially, if the volume in the TS is 0, then we are waiting for the entry point conditions to be met. After entering, the volume is not zero, so we need to reverse trade with this volume when the exit conditions are met.

We store the volume in a variable and double-check it on every tick, eco better than holding the account balance.

 
St.Vitaliy:

Wouldn't it be easier not to mess around with magicians and just hold a position for each strategy?

Basically, if the TS volume is 0, then we are waiting for the entry point conditions to be met. After entering, the volume is not zero, so we need to make a reverse trade with this volume when the exit conditions are met.

We store the volume in a variable and double-check it on every tick, eco better than holding the account balance.

The position is one. And it is the same for all trading robots that are bleeding their depo on a common symbol.

Sometimes one has to remember (or learn, depending on how and when it happens), but there is no way out.

Reason: