Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 1453
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
And what exactly does the tester do with each tick , if there is not a single symbol in the program it is running, which would give the tester a command?
Well, the tester creates a simulation of the market. It sends a new price to your EA at every tick. And because there are 53 thousand ticks, it needs considerable time to send them all. All this happens before the EA code is executed. What to write in the EA is the programmer's business and has nothing to do with the work of the tester.
The total time includes the tester run time and the tester preparation time. Your tester run time is minimum (processed in) in both modes. The preparation time is standard regardless of the mode.
When testing at OPENING PRICES - out of 160 orders which were opened at EACH TICK, only 120 were opened, and besides not at intra-minute prices (as the code requires).
Here everything is in the hands of the programmer: how to construct the logic, how it will work, look for errors in understanding of the program.
Working on ticks on a long history takes a lot of time. And since there will be a great number of tester runs, the calculation time must be reduced. Therefore, it is better to develop an Expert Advisor with control of opening of a new bar and use the mode - by opening prices. And then study and analyze what is wrong.
Well, the tester creates a simulated market operation. It sends a new price to your EA on every tick. And since there are 53 thousand ticks, it takes a significant amount of time to send them all. All this happens before the EA code is executed. What to write in the EA is the programmer's business and has nothing to do with the work of the tester.
Thank you for the information. However, the yellow and gray phrases seem to contradict each other. It appears that the tester will send ALL ticks with prices to my Expert Advisor by the moment the OnTick() function starts working. But, when OnTick( ) starts working , the tester will not send ticks with prices to the Expert Advisor. In this case, what if it's not ticks that will process program lines of my EA? I'm sorry if I've misunderstood you.
Everything here is in the hands of the programmer: what kind of logic to build, how it will work, look for errors in understanding how the program works.
Working on ticks on a long history takes a lot of time. And because the tester will run a great number of times, the calculation time must be reduced. Therefore, it is better to develop an Expert Advisor with control of opening of a new bar and use the mode - by opening prices. And then study and analyze what is wrong.
Do you agree that if the orders are opened within a minute candle on ticks, the model BAR OPENING PRICES will not open orders at ticks prices within a minute candle? Even if we control the opening of each minute candle.
The total time includes the tester run time and the tester preparation time. Your tester run time is minimum (processed in) in both modes. Preparation takes the standard time irrespective of the mode.
This means that you can only save the tester run time on processed in
It turns out that the tester will send ALL ticks with prices to my Expert Advisor by the moment when OnTick() function starts working.
OnTick() is the function of event capturing, where the event is arrival of a tick to the terminal, or imitation of such arrival in the tester. If there is a code in OnTick(), it will execute every incoming tick. If a new tick comes at the moment of processing the old tick, the new tick is not placed in the queue but skipped (in the trade mode). If there is no code in OnTick(), the tick also activates this function, but the code is not there, so there is nothing to execute.
OnTick() is an event catching function, where the event is the arrival of a tick in the terminal, or a simulated arrival in the tester. Ticks come one after another, and activate the function. If there is code in OnTick(), then it processes every tick that comes. If a new tick arrives while the old one is being processed, the new tick is skipped and not put into the queue. If there is no code in OnTick(), the tick also activates this function, but there is no code there, so there is nothing to work out.
Got it. Thanks.
server,login,leverage);