Questions from Beginners MQL5 MT5 MetaTrader 5 - page 1153

 
Franklins100:
Thanks for the replies. Code by code. The code will be optimized, but as we add new indicators and increase the history the 'run' time increases. How much does PC hardware affect the 'run' time (need a tricked out CPU or GPU)? There are a huge number of questions and I'd love to talk to a guru about it)

Testing can be accelerated many times over if it is possible to split variables into groups and cross-test them. This scheme is possible if you understand how an EA is built and it has independent variables, i.e. their change does not affect the result when other variables are run.

If there are a lot of variables, time for testing can be reduced by hundreds of times.

Also, mt5 allows you to connect third parties for testing.

Как протестировать торгового робота перед покупкой
Как протестировать торгового робота перед покупкой
  • www.mql5.com
Покупка торгового робота в MQL5 Маркете имеет одно большое преимущество перед всеми другими подобными предложениями -  вы можете устроить комплексную проверку предлагаемой автоматической системы прямо в терминале MetaTrader 5. Советник перед покупкой можно и нужно тщательно прогнать во всех неблагоприятных режимах во встроенном тестере торговых...
 
BenditO:

Testing can be accelerated many times over if it is possible to split variables into groups and cross-test them. This scheme is possible if you understand how an EA is built and it has independent variables, i.e. their change does not affect the result when other variables are run.

If there are a lot of variables, time for testing can be reduced by hundreds of times.

Also, mt5 allows connecting third parties for testing.

This is an idea but cross testing will not give exact results in my opinion. Testing, again in my inexperienced opinion, should be done in a final, complete version. And here a question - how and by what computer parameters can you speed up testing as much as possible without resorting to third-party power. GPU or CPU?

 
Franklins100:

This is an idea, but cross-testing will not produce accurate results, in my opinion. Testing, again in my inexperienced opinion, should be done in a final, complete version. And here the question is - how and by what computer parameters is it possible to speed up testing as much as possible, without resorting to the use of third-party power. GPU or CPU?

Optimize code.

 
Vladimir Karputov:

Optimise code.

Let me try to be more direct - I have the following configuration: 2pc Intel® Xeon® Gold 6126, 4pc Samsung DDR4 2666 Registered ECC LRDIMM 64Gb, 2pc Tesla P100 or 2080ti (I am pondering) Will I get any speed in this case with this configuration or can I just not bother with it and optimize the code on the calculator? I want to "play" with a large number of indicators, history, to test all possible outcomes, strategies and variations - to get experience, etc.

 
Franklins100:

Let me try to be more direct - I have the following configuration: 2pc Intel® Xeon® Gold 6126, 4pc Samsung DDR4 2666 Registered ECC LRDIMM 64Gb, 2pc Tesla P100 or 2080ti (I am pondering) Will I get the speed in this case with this configuration or I just decided not to bother with it and optimize the code on the calculator? I want to "play" with a large number of indicators, history, to test all possible outcomes, strategies and variations - to get experience, etc.

We have to open a new branch with a specific question - "What hardware do I need to optimize any Expert Advisor instantly?

 

What should this function return?

Print(SYMBOL_POINT);

For EURUSD I get 16, but it should be 0,00001

but Print(SymbolInfoDouble(Symbol(),SYMBOL_POINT));

It returns 9.999999999999996e-06

Is this a glitch or is it the same for everyone?
 
SEM:

What should this function return?

Print(SYMBOL_POINT);

For EURUSD I get 16, but it should be 0,00001

but Print(SymbolInfoDouble(Symbol(),SYMBOL_POINT));

It returns 9.999999999999996e-06

https://www.mql5.com/ru/docs/convert/doubletostring

Документация по MQL5: Преобразование данных / DoubleToString
Документация по MQL5: Преобразование данных / DoubleToString
  • www.mql5.com
[in]  Формат точности. Если значение digits лежит в диапазоне от 0 до 16, то будет получено строковое представление числа с указанным количество знаков после запятой. Если значение digits лежит в диапазоне от -1 до -16, то...
 
how do I get a Single Point Value for EURUSD? I get 16 instead of 0.00001.
 
SEM:
how do you get the Single Point Value for EURUSD? I get 16 instead of 0.00001

What exactly are you printing out?

SYMBOL_POINT is a predefined constant. That is, you print the numeric value of the constant.

Документация по MQL5: Константы, перечисления и структуры / Состояние окружения / Информация об инструменте
Документация по MQL5: Константы, перечисления и структуры / Состояние окружения / Информация об инструменте
  • www.mql5.com
Для получения текущей рыночной информации служат функции SymbolInfoInteger(), SymbolInfoDouble() и SymbolInfoString(). В качестве второго параметра этих функций допустимо передавать один из идентификаторов из перечислений ENUM_SYMBOL_INFO_INTEGER, ENUM_SYMBOL_INFO_DOUBLE и ENUM_SYMBOL_INFO_STRING соответственно. Некоторые символы (как...
 
Artyom Trishkin:

What exactly are you printing out?

Trying to normalise TakeProfit for Sell, I get TP = -130

 int TakeProfit=100;//Profit

double _PriceCurrent_TakeProfit = NormalizeDouble(m_position.PriceOpen()-(TakeProfit*SYMBOL_POINT),SYMBOL_DIGITS) ;
Reason: