Very interesting article for those who start..... I hope that
others as this.... thanks
if(prev_calculated==0) // check for the first start of the indicator
first=MAPeriod-1+begin; // start index for all the bars
else first=prev_calculated-1; // start index for the new bars
when first=MAPeriod-1+begin; which is current bar ? [0] or [rates_total] ?
when first=prev_calculated-1; it is a large number, need repeat calculate ?
64661
New article Custom Indicators in MQL5 for Newbies is published:
Author: Nikolay Kositsin