return value of upper bollinger band when High[i] crosses
Hi Fellow coding enthusiasts,
I am trying to return the value of the upper bollinger band when the price last crossed it using a function (below) I am checking the code by getting it to comment on the chart what should be the price. not sure were I am going wrong any help appreciated thanks.
I guess you should also check if High[i-1] is less than the band so that you could say that a cross. I never tried this indicator so I am not sure. But I use this logic to determine the MA crosses.
Hi Fellow coding enthusiasts,
I am trying to return the value of the upper bollinger band when the price last crossed it using a function (below) I am checking the code by getting it to comment on the chart what should be the price. not sure were I am going wrong any help appreciated thanks.