We’ve learned that for some users, MQ Gravity Lines started running slowly as of the beginning of February 2021. We’re working to identify the cause, and will provide an update once it’s available. We’ll make a note in the Recent Updates knowledge base article when any new version is available.
One thing we’ve discovered is that some users see performance degradation when loading a large amount of bars. Users may not realize that they’re loading tens of thousands of bars, or even millions of bars. This can happen when choosing “Days” in the “Load data based on” setting. In a recent analysis, loading 20 days of CL futures data loads over 13,000 bars. Loading 20 days of NQ futures data loads over half a million bars. And that’s just one chart! When combining multiple charts in multiple tabs at once, all of these add up to a very large amount data, plots, graphical elements, etc. This eats up memory and CPU power, potentially slowing your system.
Therefore, if your system slows, one of the first things to do is try using “Bars” rather than “Days”, and set the number of bars to a reasonable number of bars, such as 1,000 or 2,000 bars. This will cut the number of bars by 80% in most cases, and by much much more in some cases.
To test this out, save your favorite workspace as new via the NinjaTrader Control Panel’s Workspaces menu (hover over your workspace name in the menu to find the save as menu. Then try reducing the number of bars in each chart using the load Bars rather than Days, and see if you get comparable trading charts but with much greater efficiency. If you don’t like it, you can revert to the original version. If you do like it, then try it out for a bit to see if you like it better.
Note that Gravity Lines can sometimes warn you when there’s not enough bars loaded when it’s clear that more than 23 bars have been loaded, for example. Switching to 1000 bars often resolves that issue. And it should work with greater efficiency. If another indicator you own requests more bars, experiment with the minimum number of bars to add. Now you don’t want to go too low, as you want sufficient data that an indicator wants to use – but you don’t need to load many times more than you need if you rarely or never scroll back in time.
You can also look into the number of charts that you load at one time. Some users are able to reduce the number of charts by using the time selector, switching from 2 minute, to 5, to 30, to 240, etc., rather than maintaining a separate chart for each time frame. You can also link your charts together by symbol or interval. If you link your charts by interval, you can change all of your linked charts to the same time by just changing it on one of the linked charts. If you’re able to reduce 4 sets of charts down to 1 set, you’ve reduced memory and processing demands by 75%.
Please let us know you're having this issue
If you tried the suggestions listed above and it still doesn’t resolve the issue for you, please contact support for additional suggestions. If you want to quickly remove the indicator from all of your charts, you can temporarily remove the indicator from NinjaTrader 8. That’s done by using NinjaTrader 8’s Control Panel / Tools / Remove Ninja Script Assembly, select MQ Gravity Lines from the dialog box that pops up and select the Remove button.
Be sure to let us know via a message to support if you have this issue, so we can help you resolve it.