Optimizing on minor fx pairs using custom symbols

altmql
18

When optimizing (on every tick) with mt5 stretagy tester on minor FX pairs I notice that the tester downloads tick data from major forex pairs before running the optimisation. For example if I optimize on AUDCAD(custom symbol) the tester donwloads tick data form USDCAD and AUDUSD before running the optimisation. Does anyone know why that happens? 

When I try to optimize on minor pairs i get the error message "no memory for tick generating". I do not get this error when optimizing on major pairs, so I assume that the error has to do with the tester downloading tick data from other pairs when optimizing for minor pairs. (My pc has 256gb DDR). 

I also do not get any errors when optimizing on 1m OHLC or open prices only

Fernando Carreiro
10955
altmql: When optimizing (on every tick) with mt5 stretagy tester on minor FX pairs I notice that the tester downloads tick data from major forex pairs before running the optimisation. For example if I optimize on AUDCAD(custom symbol) the tester donwloads tick data form USDCAD and AUDUSD before running the optimisation. Does anyone know why that happens? When I try to optimize on minor pairs i get the error message "no memory for tick generating". I do not get this error when optimizing on major pairs, so I assume that the error has to do with the tester downloading tick data from other pairs when optimizing for minor pairs. (My pc has 256gb DDR). I also do not get any errors when optimizing on 1m OHLC or open prices only

You forget that your tester account currency is in USD. The tester needs to download the extra quotes history and also tick data for USDCAD and AUDUSD to calculate the tick value in USD for the AUDCAD currency pair.

If, however, you don’t have enough disk space to store and generate all the data, then the tester will give an error.

When testing only on OHLC data, then it only downloads the extra quote history, and not the tick data as well, which results in less space being used up.

altmql
18
altmql  
Fernando Carreiro #:

You forget that your tester account currency is in USD. The tester needs to download the extra quotes history and also tick data for USDCAD and AUDUSD to calculate the tick value in USD for the AUDCAD currency pair.

If, however, you don’t have enough disk space to store and generate all the data, then the tester will give an error.

When testing only on OHLC data, then it only downloads the extra quote history, and not the tick data as well, which results in less space being used up.

Thanks for the clarification Fernando! Makes sense with the tick value and account currency, but does the tester really need the tick data (from USDCAD and AUDUSD in this example) for the entire testing period? Does tickvalue for each symbol change over time? I would imagine that once the tick value has been identified, it is static for the rest of the testing period. Or is this a false assumption?

I have 900Gb free disc space on my C drive, so I doubt the error has to do with that. The error message specificly says that there is a lack of memory. But also that I find hard to understand with 256GB ram. 

Do you know if there is anything I can do with my code to make it less taxing on the tester, both in terms of memory and storage to get around this issue? 


Thanks again:)

Fernando Carreiro
10955
altmql #: Does tickvalue for each symbol change over time? I would imagine that once the tick value has been identified, it is static for the rest of the testing period. Or is this a false assumption?

If you were trading xxxUSD with a USD based account, then the tick value would remain constant, but you are trading AUDCAD with a USD account.

Is it then not obvious that it in such a triangular setup, the tick value will change constantly? Are you not trading the Forex based on that very fact?

EDIT: If you don't want the tick value to change, then trade AUDCAD with a CAD based account instead of USD.

altmql #: I have 900Gb free disc space on my C drive, so I doubt the error has to do with that. The error message specificly says that there is a lack of memory. But also that I find hard to understand with 256GB ram. Do you know if there is anything I can do with my code to make it less taxing on the tester, both in terms of memory and storage to get around this issue? 

It depends on several factors, including if the EA is depending on multiple time-frames or just the current one.

Also, during optimisation, it is running a test pass on each core or thread (depending on circumstances), and you will require sufficient RAM for each of them, not to mention the extra memory used for the indicators if you use many of them.

So, you should make your code more efficient, reduce the number of indicators if possible, or make the indicators more efficient specifically for EA use, and/or reduce the number of cores/threads available to the optimisation process.

altmql
18
altmql  
Fernando Carreiro #:

If you were trading xxxUSD with a USD based account, then the tick value would remain constant, but you are trading AUDCAD with a USD account.

Is it then not obvious that it in such a triangular setup, the tick value will change constantly? Are you not trading the Forex based on that very fact?

It depends on several factors, including if the EA is depending on multiple time-frames or just the current one.

Also, during optimisation, it is running a test pass on each core or thread (depending on circumstances), and you will require sufficient RAM for each of them, not to mention the extra memory used for the indicators if you use many of them.

So, you should make your code more efficient, reduce the number of indicators if possible, or make the indicators more efficient specifically for EA use, and/or reduce the number of cores/threads available to the optimisation process.

ok, will follow your advice. thanks!!
Fernando Carreiro
10955
altmql #: ok, will follow your advice. thanks!!
Also, if you don't want the tick value to change, then trade AUDCAD with a CAD based account instead of USD.