So i'm needing a little advice to calculate the average high of a custom array set of the the last x candles.
I calculate a live spread of 3 instruments which is held in an array called 'LiveSpread' and i then calculate the moving average of
this which is held in a buffer:
Now the bit i'm stuck with is how can i then use this to calculate the average highest and lowest over the last x candles, initially i thought of
using iHighest and iLowest, but these functions require a string symbol which i won't have given the ma array consists of a calculation of 3
instruments.
Any advice to point me in the right direction would be much appreciated
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Hi all,
So i'm needing a little advice to calculate the average high of a custom array set of the the last x candles.
I calculate a live spread of 3 instruments which is held in an array called 'LiveSpread' and i then calculate the moving average of this which is held in a buffer:
Now the bit i'm stuck with is how can i then use this to calculate the average highest and lowest over the last x candles, initially i thought of using iHighest and iLowest, but these functions require a string symbol which i won't have given the ma array consists of a calculation of 3 instruments.
Any advice to point me in the right direction would be much appreciated
Thanks in advance