How to get the values of PriceVolDistribution() bins using gfxTextOut or exploration or in title

Dear @swalsh,

Thank you for your help, really appriciated.
I'll also share if i can find how to get each bin's range.

Thank you again

@suryarobertson - the lines that you added were wrong (you skipped for loop and left only inside of loop body, instead of copying whole loop) and as such produce obvious error message, no mystery here. The i index used outside loop is one too much (arrays and matrices are numbered from zero. And you i at that point is equal to bins while it should be only (bins-1)

image

There is absolute need for newbies to understand that you MUST NOT access array/matrix elements outside the range and you must do CHECKS if you are unsure.
This was mentioned on the forum infinite number of times that array/matix indices MUST be validated against array/matrix bounds or you will get "subscript out of range" error. See http://www.amibroker.com/kb/2014/09/22/do-not-make-assumptions-on-number-of-bars/

1 Like

Dear @Tomasz
Well noted, really appreciated thank you for your help.

2 Likes