SetIndexLabel
See function PlotIndexSetString and read article MQL5: Create Your Own Indicator
Thank you kindly.
Hey Rosh, I studied the information you provided and it was very helpful. Thank you. So I got this wild hair that I wanted to get the average of my Bollinger Bandwidth indicator and make a modification.
Bollinger Bandwidth takes the upper and lower band of iBands subtracts the lower from the upper and puts it on a chart. Now I am attempting to get an average of that indicator with a second indicator. The idea is that it should look a little like a stochastic indicator when it is done, with the bandwidth and it's average on the same chart.
Now I know I need to make settings for a second plot and buffer, no problem there. The trick I am trying to figure out is if BBandwidthBuffer is getting populated in the for loop, what would the calculation look like to get the average of it?
I almost want to start a second for loop going through the BBWidth, but I know that is not wise. After all we are in a looping process for the indicator itself and we are already in a for loop to populate the bandwidth, but how do I say:
avgbuffer = (bandwidth[i] + bandwidth[i - 1])/i;
Where i is the increment in the loop.
In MT4 we could set the label of an indicators index of an indicator by the following:
SetIndexLabel(id, string value);
How do we do it in MT5?