Questions from Beginners MQL5 MT5 MetaTrader 5 - page 146

 
stringo:
Thanks, I'll definitely give it a try when my optimisation is over.
 
stringo:

I tried, in optimization lines where stop < start are marked red. But still found two identical red lines (numbers stop and start coincide)

But for zeros, red lines, it seems that no time is taken at all (milliseconds)

 
Which function can be used to run a single test of all the runs one after the other?
 

Hi all! I have this situation... I create a pending order at the current takeprofit price, but the new order will work, but the current order will not close at takeprofit, or will close late.... but their prices are the same....

here is the situation... but i need TP to close then open a new order...

sleep (1000) also did not help....

 
Sultonboy:

Hi all! I have this situation... I create a pending order at the current takeprofit price, but the new order will work, but the current order will not close at takeprofit, or will close late.... but their prices are the same....

here is the situation... but i need TP to close then open a new order...

sleep (1000) also did not help....

You need to prescribe the TP to close the order and then enter the market.) ECN will help you and +1 point.
 
zfs:
You need to prescribe definitions for closing an order by tp and then enter the market). ECN will help you and +1 point.
ECN or +1 point? I tried alpari's ECN, it's a bit different in my opinion....
 
Can you tell me which formula is used to calculate "LR Correlation" in the tester and which functions can be used to optimise for this criterion?
 

writing to a file

      Handfile_Bin_W=FileOpen("DATA.bin",FILE_WRITE|FILE_BIN);
      if(Handfile_Bin_W!=INVALID_HANDLE)
        {
         FileWriteArray(Handfile_Bin_W,File_Chain_Max,0,WHOLE_ARRAY);
        }
      else Print(GetLastError(),"        При записи не открылся файл!!!!");
      FileClose(Handfile_Bin_W);

File_Chain_Max array has type double, with what accuracy data will be written to the file ??????

I have no more than 4 decimal places

Or advise me how to write and read data with high accuracy ?

 
dentraf:

writing to a file

File_Chain_Max array has type double, with what accuracy data will be written to the file ??????

I have no more than 4 decimal places

Or advise me how to write and read data with high accuracy ?

DoubleToString(value,5) or NormalizeDouble(value,5).
 

What is the definition of ENUM_DEAL_ENTRY

Сделки различаются не только по типу, задаваемого в перечислении ENUM_DEAL_TYPE, но и по способу изменения позиции. Это может быть простое открытие позиции или наращивание объема ранее открытой позиции (вход в рынок), закрытие позиции сделкой противоположного направления соответствующим объемом (выход их рынка) или переворот позиции в том случае, когда объем сделки в противоположном направлении перекрывает объем ранее открытой позиции.

If we reverse. We send an order and the current position is closed by several deals. Theoretically, the 1st trade may be OUT, the 2nd INOUT and the 3rd IN?

That is, you can characterize these types as follows. OUT - a trade with the direction opposite to the current position and with a volume smaller than the current position. IN - a deal without the current position. INOUT - a deal in the direction opposite to the current position and with a volume higher than the current position?

The essence of the problem is that for some reason the position identifier remains the same when we reverse. Although it is obvious that it is a new entry and a completely different position. Because of this it is difficult to implement money management algorithm - lot size when opening a position. That is, if we need to decide on the size of the position to be opened based on the results of previous trades (entries). So we have to search through all trades, but it is still unclear how to do it correctly and unambiguously. How to determine that a trade in the history of trades opens a new trade at reversal?

Reason: