What does this standard code do?
It is basically to only calculate and draw on the indicator those newly formed bars plus one (ie the limit++).
If you don't have this, it will have to re-calculate/redraw all the bars in the indicator each time you get a tick, and that would be horrific for performance.
Can someone explain to me what does this standard code-block on top of most indicators do?
I looked up the documentation of these functions, but I don't understand what does it accomplish.
Thanks.