![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I am trying to create an indicator to plot the change in gradient of the NonLagMA indicator as a Histogram. What I have done works fine when you first place it on a chart but gets messed up as soon as a new bar appears. Could someone please take a look at the code and show me where I am going wrong? Note: I had to remove some code from the init() function as the post was too long. Nothing that should have any effect on the problem I am having though.