mt5/mt4? - page 5

 

How can I download the minute quotes archive from mt5 for a specified symbol for example a year? (I suppose there may be scripts)

Maybe I am imagining something wrong, but my idea of testing is that a sample should not be representative, but it should be taken from the real time interval from the nearest past, and it should be assembled from different time periods reflectingIt may even include synthetic spikes "from the chief" that would load quotes, cut them up and make editing (like in a video clip or sound) and feed the tester with it. But these are just beginner's thoughts, sorry if I'm going in the wrong direction...

 

You cannot load your own quotes into MetaTrader 5.

The system is very complex and interconnected, requiring a huge number of correct instrument settings and therefore the terminal only trusts the correct environment provided by the server. This is the ideology of the platform.

 
Alex_Bondar:

How can I download the minute quotes archive from mt5 for a specified symbol for example a year? (I suppose there may be scripts)

Maybe I'm imagining something wrong, but my idea of testing is that the sample should not be representative, but it should be taken from the real time interval from the nearest past; it should be assembled from different time periods reflecting different types of market behavior so that the robot would be ready for different tests, maybe even add synthetic spikes "from the boss", for this we should download quotes, cut them up and do editing (like in a video clip or sound) and feed the tester with it. But these are just beginner's thoughts, sorry if I'm going in the wrong direction...

It would be a cool tool to do research on a generated story. I'd love to use it. That is, a tool that allows you to generate history and has settings for introducing "noise", volatility, flat/trend and their frequency/repeat, spread, etc. that could still change over time. Something like that... In the tester, you could choose whether to run a test on the history provided or enable generation mode. And there is no problem in this case with the lack of historical data, and the limitation is only in the computer resources.

But there is a way around this. Looks like another article should be noted in the plan. )))

 

There is always the option of using MT4 as an extension of MT5. If you look at the question from this angle, then

(1) MT4 will only die when MT6 comes out

(2) The capabilities of MT5 are greatly expanded.

 
Alex_Bondar:

How can I download the minute quotes archive from mt5 for a specified symbol for example a year? (I suppose there may be scripts)

The quotes archive can be saved as *.csv from menu File/Save (Ctrl+S) for the current open symbol, but in my case only the last 2 months are saved. I haven't figured out how to save a longer period of time. I cannot download it, that's why I should use catamaran quotes either inmt4 or other software.

Your idea about artistic approach to generate a sample for testing is not new, but very relevant especially for training neural network algorithms that may be harmful to consume too much data, and proper sample generation is not less important than its preprocessing (normalization, filtering, etc.).

 
EvMir:

The quote archive can be saved in *.csv from File/Save (Ctrl+S) by the current open symbol, but I have only saved the last 2 months as far as the minutes are concerned. I haven't figured out how to save a longer period of time. But I can't download it, that's why I should use catamaran quotes either inmt4 or other softwares.

...

See this article >> How to prepare MetaTrader 5 quotes for other programs

And in the code base there is more script >> sHistoryExport - convenient script for exporting historical data in MT4

 
gpwr:

...

1. a better optimiser (number of parameters not limited)

...

Checked it just in case. )) There is a limit of 1024 parameters. Here is a script for quick check:

//+------------------------------------------------------------------+
//|                                        Generate1030InpParams.mq5 |
//|                        Copyright 2010, MetaQuotes Software Corp. |
//|                                              http://www.mql5.com |
//+------------------------------------------------------------------+
#property copyright "Copyright 2010, MetaQuotes Software Corp."
#property link      "http://www.mql5.com"
#property version   "1.00"
//---
#define CNTPRM 1030 // Кол-во параметров
//---
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
// Получим хэндл файла для записи
   int hFl=FileOpen("1030.mq5",FILE_WRITE|FILE_TXT|FILE_ANSI,"");
//---
   if(hFl!=INVALID_HANDLE) // Если хэндл получен
     {
      string
      inputs="input ",
      types="int ",
      names="param_",
      equals="=",
      end=";";
      int values=0;
      //---
      string n="";
      //---
      for(int i=1; i<CNTPRM; i++)
        {
         n=IntegerToString(i);
         FileWrite(hFl,inputs,types,names+n,equals,values,end);
        }
      //---
      FileWrite(hFl,"void OnInit(){}");
      FileWrite(hFl,"void OnDeinit(const int reason){}");
      FileWrite(hFl,"void OnTick(){}");
     }
//---
   FileClose(hFl); // Закроем файл
  }
//+------------------------------------------------------------------+

//---

The script writes an Expert Advisor for the test with the specified number of parameters, which should then be compiled and moved to the Expert Advisor folder. If there are more than 1024 parameters, then on startup in the tester we see:

 
tol64:

Have a look at this article >> How to prepare MetaTrader 5 quotes for other programs

And in the code base there is more script >> sHistoryExport - handy script to export historical data in MT4 format

I have seen this script, thank you. I saw it, thank you. 1 year (370 000 min bars) it writes off in 0.5 sec. but 370 001 is already hanging up (on 4 core i7 2600k 4GHz, 16Gb of RAM), there is either error in the script or in the data, as the CPU and memory do not bother me when running the script.

 
EvMir:

Saw this script, thanks. 1 year (370 000 minute bars) it writes off in 0.5 sec, however 370 001 is already causing a hangup (on a 4-core i7 2600k 4GHz, 16Gb RAM), somewhere there is an error or in the script or in the data, because the CPU and memory when running the script is not at all disturbing.

Try asking the author of the script there in the comments.
 
tol64:

Checked it just in case. )) There is a limit of 1024 parameters. Here is a script for a quick check:

//---

The script writes an Expert Advisor for the test with the specified number of parameters, which should then be compiled and moved to the Expert Advisor folder. If there are more than 1024 parameters, then on startup in the tester we see:

I made a wrong statement. I meant the number of calculated values (steps) of input parameters.

Reason: