Hi Members,
HighValue = H[0];
HighValue = LastValue(High);
If i try to print the HighValue ideally it should print the same value.. but when i try to run the code it gives me different high values.. what am i missing ?
Thanks
Hi Members,
HighValue = H[0];
HighValue = LastValue(High);
If i try to print the HighValue ideally it should print the same value.. but when i try to run the code it gives me different high values.. what am i missing ?
Thanks
@SUMITJAIN the last value in Amibroker is not at zero bar.
HighValueIndex = H[BarCount - 1];
HighValueFunction = LastValue( High );
Title = StrFormat( "High value using index: %g - High value using LastValue() function: %g", HighValueIndex, HighValueFunction );
This is different from other trading platform like TS.
From the documentation (I suggest to read this very carefully).
All array indices in AFL are zero-based, i.e. counting bars starting from bar 0 (oldest). The latest (newest) bar has an index of (BarCount-1).
thanks a lot @beppe