Questions from Beginners MQL5 MT5 MetaTrader 5 - page 491

 
Only the indicator handles all ticks in OnCalculate(). There are no skips.
 
Alexey Kozitsyn:
It depends on how the indicator is written. If it has the logic of a zero candle update, then yes. If not, then the indicator will be updated only with the arrival of a new candle. The variant of the total recalculation of the indicator at every tick is also possible.

Thank you all for your replies.

The indicator is not talking about candlesticks, if I understand correctly, so the default is to recalculate with each tick.

 
kashi_ann:

Thank you all for your replies.

The indicator doesn't talk about candles, if I understand correctly, so the default is to recalculate with each tick.

If so, this is not a good thing. The indicator consumes a lot of extra resources.
 
Hello! Can you help me understand one question when genetic selection works in the strategy tester of the 5th Metatrader.
How to correctly build an algorithm so that, say, if X=1, only the value of Y was selected, and if X=2, only the value of Z was selected
Or at least a link where an answer to such a question was found?
 
Alexey Kozitsyn:
If so, this is not a good thing. The indicator consumes a lot of unnecessary resources.
Nothing extra is being consumed. Only the last indicator value is recalculated. All previous values are not recalculated.
 
newnek:
Hello, could you help me clarify one question when working with genetic selection in the strategy tester of the 5th Metatrader.
How to correctly build an algorithm, so, say, if X=1, only the value of Y was matched, and when X=2, only the value of Z was matched
Or at least a link to where I skipped the answer to such an answer?

To do this, you need to make a variable to be searched and create an algorithm for generating an array of settings that will change depending on the value of the first variable.

 
Vasiliy Sokolov:
Nothing unnecessary is consumed. Only the last indicator value is recalculated. All previous values are not recalculated.

That's good, thank you.

Another question:

OrderSelect

Selects an order for further work with it. Returns true on successful completion of the function. Returns false if the function fails. You need to call theGetLastError() function to get information about the error.

boolOrderSelect(
ulong ticket// order ticket
);

Parameters

ticket

[The ticket of the order.

How is this ticket assigned? Where can I get it? Or how do I set it?

 
-Aleks-:

To do this, you need to make a variable to be enumerated, and create an algorithm for generating an array of settings that will change depending on the value of the first variable.

The algorithm for generating an array of settings - this is the algorithm I'm consulting about. The settings array...is something like a bitwise mask in a time filter....aha I get the idea. Too bad if there are no other ways, has it been written anywhere about these algorithms so I don't have to reinvent the wheel?
 
newnek:
The algorithm for generating a settings array - this is the algorithm I'm consulting on. The settings array...is something like a bitmask in a time filter ....aha I get the idea THANK YOU. Too bad if there are no other ways, has it been written somewhere about these algorithms. so as not to reinvent the wheel?
You're welcome. I haven't seen such an algorithm code - I composed it myself and it was custom written for me, I also had a trick to exclude variables, if logically their characteristics overlap.
 
Can you tell me if the opening scripts work over the weekend?