Questions from Beginners MQL5 MT5 MetaTrader 5 - page 374

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
Then you just need to take the value of iHigh(Symbol(),PERIOD_D1,0), after a certain period of time. This only makes sense for the current day candle, which is not yet completely formed. But if you take the values of past days, they will be the same at any time.
That's the trouble, I need to look at it retrospectively....
I see. You need to fix all intraday price extremes. I cannot think fast enough how to do that on historical data.
The first thing that comes to mind is to analyze the fractals formed on intraday timeframes.
I do not know how to put it more clearly, in general, how to set the name of the array as a variable?
For example, there are 2 arrays Mass1 and Mass2, you need to make it run the same function, but by condition with two different arrays:
and type of function:
A=Имя_массива[123];
I do not know how to put it more clearly, in general, how to set the name of the array as a variable?
For example, there are 2 arrays Mass1 and Mass2, you need to make it run the same function, but by condition with two different arrays:
and type of function:
I do not know how to put it more clearly, in general, how to set the name of the array as a variable?
For example, there are 2 arrays Mass1 and Mass2, you need to make it run the same function, but by condition with two different arrays:
Well and type function:
No way. Becausean array is a numbered set of variables.
I do not know how to put it more clearly, in general, how to set the name of the array as a variable?
For example, there are 2 arrays Mass1 and Mass2, you need to make it run the same function, but by condition with two different arrays:
Well and type a function:
Make a function inside which you perform operations on the array. And by condition, pass different arrays to the function:
And simply declaring two arrays prevents what beliefs?
Make a function inside which you perform operations on an array. And pass different arrays into the function by condition:
oops, but inside theWorkWithMassive function,how do you refer to this array?
An array is passed by reference and you are referring to the exact array you pass to the function via the input parameters. For example (purely hypothetical)
It is better, of course, to pass all the necessary parameters to the function:
well and you can use function overloading - a function with the same name does different things depending on the input parameters and type:
Right.
1. Determine the opening time of the daily candle;
Determine the number of bars num on the TF you want (if you want to check the extremum of the day every 15 minutes - M15 bars);
3. Receive the data high for num bars;
3. In the loop, compare all the values of high bars with the variable dayHigh for the desired day candle (initially dayHigh = 0);
4. If high > dayHigh, you store the new value in the variable dayHigh;