[WARNING CLOSED!] Any newbie question, so as not to clutter up the forum. Professionals, don't go by. Can't go anywhere without you. - page 294
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
The first time the indicator is called, the first calculation will be made. If there are other calls of the same indicator on this call of the start function, the calculation will not be performed. The next calculation of this indicator will be performed only at the first call of this indicator on the next tick (at the next call of the start function of the EA)
...If this call of the start function is followed by another call of the same indicator, the calculation will not be performed.
- I.e., the indicator is called in four consecutive strings, and only at the first call will it be calculated? And the next calls will only read the specified parameters? This is interesting... ...and nice.
...The first indicator call will perform the first calculation.
- I.e. one pass that is made in the indicator at the first tick? Or is the concept of TIC not used in this case?
It would have been better to move the logic to the EA
The indicator can be simplified. It will be faster to calculate
I repeat my question=)
how in mql can i close an open position before the swap close???
and what is the best time to close a position before 00.00 (I assume this is the server time???)?
and 25 percent is sufficient for the simulation? and how can this percentage be increased?
THANKS ALL!
I repeat my question=)
how in mql can i close an open position before the swap close???
and what is the best time to close a position before 00.00 (I assume this is the server time???)?
and 25 percent is sufficient for the simulation? and how can this percentage be increased?
THANK YOU ALL!
1: Every night the position has to be rolled over by the brokerage companies and the times may differ.
2 On M1 it depends on the quality of the data whether there are gaps in the data as far as open differs from close (there is data where all four points are equal) on M1 the highest quality will be the ones you have accumulated, the older the TF the less the relative quality of the modelling depends on M1.
In Metatrader, time is set in seconds. If you want to add an hour, it is 3600 seconds
datetime NextOpenH1 = OpenH1 + 3600;
>> Thank you!
And two more questions. 1) In my TS there are three different functions modifying SL and TP, depending on the incoming modification signal. So, when I run this EA in the tester, it becomes difficult to determine which criterion triggered Modify. Maybe, my view has become sloppy :) My question is, is there no way to insert a comment into Ordermodify()? In the ordersend function you can! Or maybe somebody knows some other way to distinguish functions?
2) How can I increase the number of optimisation passes? I click on the optimisation checkbox - press start, it makes 1 pass and that's it. But what happens next? I do not understand the meaning of optimization, what it does?
As for optimisation, this is a good place to start.
Testing and optimising EAs
...... In my TS there are three different functions modifying SL and TP, depending on the modification signal coming in. So, when I run this EA in the tester, it becomes difficult to determine which criterion triggered Modify. Maybe, my view has become sloppy :) My question is, is there no way to insert a comment into Ordermodify()? In the ordersend function you can! Or maybe someone knows some other way to distinguish functions?
Try to provide for each optimization criterion a different colour in OrderModify.
Who knows - maybe that's what you'll get....
Try providing a different colour for each optimisation criterion in OrderModify.
Who knows - maybe that's what you need....
Well, basically, yeah. :))) Thanks