Some functions returning zero
They return zero because of 4066/4073.
On MT4: Unless the current chart is that specific pair/TF referenced, you must handle 4066/4073 errors.
Download
history in MQL4 EA -
MQL4 and MetaTrader 4 - MQL4 programming forum
Is it true that functions like iRSI returns 0 (zero) if you haven’t yet open that symbol in the graph window or downloaded its historical data?
In the next simplified code theRsi returns 0 for some symbol/timeframe combinations.
Is there a way to avoid this?