NexusFi: Find Your Edge


Home Menu

 





How bad is NT lag?


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one shortski with 17 posts (2 thanks)
    2. looks_two chipwitch with 16 posts (20 thanks)
    3. looks_3 phantomtrader with 7 posts (6 thanks)
    4. looks_4 llmflyfisher with 3 posts (0 thanks)
      Best Posters
    1. looks_one Fat Tails with 8 thanks per post
    2. looks_two glennts with 4.5 thanks per post
    3. looks_3 Miesto with 4 thanks per post
    4. looks_4 chipwitch with 1.3 thanks per post
    1. trending_up 32,389 views
    2. thumb_up 142 thanks given
    3. group 745 followers
    1. forum 137 posts
    2. attach_file 4 attachments




 
Search this Thread

How bad is NT lag?

  #11 (permalink)
 
glennts's Avatar
 glennts 
Corpus Christi, TX / Westcliffe, CO
 
Experience: Advanced
Platform: NinjaTrader
Broker: DDT / Rithmic / Kinetick / IQ
Trading: 6E, ES
Posts: 420 since Oct 2010
Thanks Given: 24
Thanks Received: 1,022

If you use Task Manager and locate the NinjaTrader in the Details tab and then right click you can change the priority the CPU gives NT. By default it is Normal, competing with other services for CPU cycles and you can change it to High, which I use, or Realtime which I've not tried. There is a script in the NT downloads that you load as an indicator that sets this whenever you start NT7. Don't know if it also works with NT8.

Also, I use the Rithmic DOM for order entry and it is generally 1+ seconds ahead of the NT charts in displaying price changes and during high volume surges it is not uncommon to see a multiple ES point lag. I believe NT uses a split data stream, one for the charts and one for trade execution. You may have seen evidence of this when a trade gets filled at a price that has yet to appear on a chart.

C# being object oriented, every indicator plotted is made up of separate bar to bar data points. If you use a long look back you dramatically increase the computational load as each data point is recalculated with each new bar. So it makes sense to consider how much historical data you need to chart to decide what you are going to do in the next 5 minutes. Perhaps an analysis workspace in which you have multi-week time spans to sketch out your strategy for the day with the chart properties refresh rate set to multiple seconds. Do you really need a weekly bar to refresh every .3 seconds? And a trading workspace in which you show only the amount of data necessary to get you into and out of a trade.

Windows and some of the Speed monitor programs have a Trace function where you can see the tortuous path data follows to get from the data servers to your computer. When you realize how many links are involved it is amazing it works at all let alone with 30ms of latency.

Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Trade idea based off three indicators.
Traders Hideout
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
How to apply profiles
Traders Hideout
MC PL editor upgrade
MultiCharts
Better Renko Gaps
The Elite Circle
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Spoo-nalysis ES e-mini futures S&P 500
29 thanks
Just another trading journal: PA, Wyckoff & Trends
25 thanks
Tao te Trade: way of the WLD
24 thanks
Bigger Wins or Fewer Losses?
22 thanks
GFIs1 1 DAX trade per day journal
17 thanks
  #12 (permalink)
 
chipwitch's Avatar
 chipwitch 
Nashville, TN
 
Experience: Beginner
Platform: NinjaTrader
Broker: NinjaTrader, Continuum Data
Trading: MES for now... baby steps
Posts: 322 since Feb 2022
Thanks Given: 230
Thanks Received: 631


iq200 View Post
Are you running in Replay Sim, Live Sim or live with a broker?

I have a six core I7, 32GB memory and a crappy NIVDIA GT1030 running 30-40 charts at a time on two monitors and I get good performance on Live Sim and Replay Sim.

Live with Broker. Sounds like a similar setup. How much are you relying on tick data? DOM? T&S? Indicators that use either of those?

Started this thread Reply With Quote
  #13 (permalink)
 
chipwitch's Avatar
 chipwitch 
Nashville, TN
 
Experience: Beginner
Platform: NinjaTrader
Broker: NinjaTrader, Continuum Data
Trading: MES for now... baby steps
Posts: 322 since Feb 2022
Thanks Given: 230
Thanks Received: 631



glennts View Post
If you use Task Manager and locate the NinjaTrader in the Details tab and then right click you can change the priority the CPU gives NT. By default it is Normal, competing with other services for CPU cycles and you can change it to High, which I use, or Realtime which I've not tried. There is a script in the NT downloads that you load as an indicator that sets this whenever you start NT7. Don't know if it also works with NT8.

Also, I use the Rithmic DOM for order entry and it is generally 1+ seconds ahead of the NT charts in displaying price changes and during high volume surges it is not uncommon to see a multiple ES point lag. I believe NT uses a split data stream, one for the charts and one for trade execution. You may have seen evidence of this when a trade gets filled at a price that has yet to appear on a chart.

C# being object oriented, every indicator plotted is made up of separate bar to bar data points. If you use a long look back you dramatically increase the computational load as each data point is recalculated with each new bar. So it makes sense to consider how much historical data you need to chart to decide what you are going to do in the next 5 minutes. Perhaps an analysis workspace in which you have multi-week time spans to sketch out your strategy for the day with the chart properties refresh rate set to multiple seconds. Do you really need a weekly bar to refresh every .3 seconds? And a trading workspace in which you show only the amount of data necessary to get you into and out of a trade.

Windows and some of the Speed monitor programs have a Trace function where you can see the tortuous path data follows to get from the data servers to your computer. When you realize how many links are involved it is amazing it works at all let alone with 30ms of latency.

Yes, I've done all that. I was able to make some adjustments, but everything was already close to optimum. My main chart is a 2 range chart for entries. It also has the T&S and Cumulative Delta both running tick data. One of my indicators uses drawn bars using the drawing tools. I'm not sure how inefficient that is compared to the OnRender() method... but I have been avoiding taking on too heavy graphics. Still, it seems that it should be able to handle what I throw at it.

I went back and reviewed the charts where the lag occurred... It was relatively short and a lot of movement. I still don't think it was significant enough to slow it down that much. On my 2 range chart there were probably 50 bars painted in about 30 seconds... One particular bottleneck had 20 bars or so in about 3 seconds. You would think the lag could be monitored from within NT and shut down most graphic elements or at least give priority to just the price bar on the chart. Maybe paint the background red as an indication of the event.

Started this thread Reply With Quote
  #14 (permalink)
 
glennts's Avatar
 glennts 
Corpus Christi, TX / Westcliffe, CO
 
Experience: Advanced
Platform: NinjaTrader
Broker: DDT / Rithmic / Kinetick / IQ
Trading: 6E, ES
Posts: 420 since Oct 2010
Thanks Given: 24
Thanks Received: 1,022

>>One particular bottleneck had 20 bars or so in about 3 seconds.<<

This is asking your chart to refresh every .15 seconds if it is going to keep up. The default chart properties refresh rate is .3 seconds with a caution that anything shorted will result in CPU overload. That it chokes is not surprising.

You may want to consider a 2 (tick?) range bar to not be practical.

Reply With Quote
Thanked by:
  #15 (permalink)
 iq200 
London, UK
 
Experience: Intermediate
Platform: Ninjatrader, Tradestation
Broker: Kinetick, InteractiveBrokers
Trading: Equities, Futures
Posts: 408 since Jun 2010
Thanks Given: 145
Thanks Received: 278


chipwitch View Post
Live with Broker. Sounds like a similar setup. How much are you relying on tick data? DOM? T&S? Indicators that use either of those?

I am looking at around 12 different watch equity symbols and for each equity, I have a 1 minute and 5minute chart w/T&S. I also have L2 window but separately from my broker software. I am however using a 1 tick stream on each chart to calculate orderflow bound to two indicators I have written. So thats 24 charts.

On top of that I have am viewing 4 trading symbols (2 charts per symbol again 1 & 5min) which I switch based on whats happening on the watch charts and 8 index charts.

I should refine my previous post. I have noticed a certain lag very occasionally when the stock market opens on days of huge volatility when I assume, there is massive amounts of order flow happening. This doesn't happen to all the charts however. I don't remember noticing lag when I am using a a couple of charts in my workspace. In any case after the market has settled all is usually fine. I havent looked at this as in great detail because I am planning to upgrade my computer to a very powerful spec when I go live.

One thing I have found that may make a difference in performance charts is that I have set my indicators that need tick data to update per tick (2 indicators per chart) and others I have set to price change.

Also make sure you turn off the debug for your indicators. You can check this by going to the NT editor, loading up an indicator and right click and see if the Debug setting is checked.

Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
  #16 (permalink)
 
chipwitch's Avatar
 chipwitch 
Nashville, TN
 
Experience: Beginner
Platform: NinjaTrader
Broker: NinjaTrader, Continuum Data
Trading: MES for now... baby steps
Posts: 322 since Feb 2022
Thanks Given: 230
Thanks Received: 631


iq200 View Post
Also make sure you turn off the debug for your indicators. You can check this by going to the NT editor, loading up an indicator and right click and see if the Debug setting is checked.

Thanks for the reminder. I'll double check. I haven't used the debugger yet, but I got it installed and may have turned it on to try it out. I know it's a resource hog, so I think I would have turned it off.

Started this thread Reply With Quote
  #17 (permalink)
 erwinbeckers   is a Vendor
 
Posts: 29 since Aug 2018
Thanks Given: 10
Thanks Received: 32


chipwitch View Post
Thanks for the reminder. I'll double-check. I haven't used the debugger yet, but I got it installed and may have turned it on to try it out. I know it's a resource hog, so I think I would have turned it off.

A friend of mine had extreme lag. We tried everything, even completely reinstalling a completely blank NinjaTrader with no 3rd party indicators
Nothing helped. He was getting extreme lag even with a clean NinjaTrader.
Notice his machine is a beast, with more than enough CPU power, memory, and GPU power. Also, he has a high bandwidth internet connection
In fact, his PC is and internet connection is way higher & faster than mine, yet he experienced extreme lack while I did not.

In the end, we finally figured it out. He is using 6x 4k monitors and NinjaTrader can't seem to handle this
We changed the screen resolution for each monitor from 4k to 1920x1080 and boom Ninjatrader did not lag anymore
Next, we reinstalled all his 3rd party indicators, chart templates, workspaces, you name it and NinjaTrader performed just fine

So.. never use 4k monitors with NinjaTrader with a 4k screen resolution

Erwin

Reply With Quote
  #18 (permalink)
 
chipwitch's Avatar
 chipwitch 
Nashville, TN
 
Experience: Beginner
Platform: NinjaTrader
Broker: NinjaTrader, Continuum Data
Trading: MES for now... baby steps
Posts: 322 since Feb 2022
Thanks Given: 230
Thanks Received: 631


erwinbeckers View Post
A friend of mine had extreme lag. We tried everything, even completely reinstalling a completely blank NinjaTrader with no 3rd party indicators
Nothing helped. He was getting extreme lag even with a clean NinjaTrader.
Notice his machine is a beast, with more than enough CPU power, memory, and GPU power. Also, he has a high bandwidth internet connection
In fact, his PC is and internet connection is way higher & faster than mine, yet he experienced extreme lack while I did not.

In the end, we finally figured it out. He is using 6x 4k monitors and NinjaTrader can't seem to handle this
We changed the screen resolution for each monitor from 4k to 1920x1080 and boom Ninjatrader did not lag anymore
Next, we reinstalled all his 3rd party indicators, chart templates, workspaces, you name it and NinjaTrader performed just fine

So.. never use 4k monitors with NinjaTrader with a 4k screen resolution

Erwin

Did you try doing just one or two 4k monitors? 6 is a lot. I'm currently just using 2 1920x1080 monitors but was thinking about upgrading to 3 4k. Of course, a new GPU is in order if I did. I don't want to spend all that money if it's just going to cause lag.

I was thinking that it might help if I ran all my charts on the ES but kept a minute chart of the MES limited to trade execution and management. My understanding is that one instrument is all crammed on one core. So, I have 5 cores just sitting there doing nothing. Maybe NT 9 will make improvements in CPU resource management.

Started this thread Reply With Quote
  #19 (permalink)
 iq200 
London, UK
 
Experience: Intermediate
Platform: Ninjatrader, Tradestation
Broker: Kinetick, InteractiveBrokers
Trading: Equities, Futures
Posts: 408 since Jun 2010
Thanks Given: 145
Thanks Received: 278


erwinbeckers View Post
A friend of mine had extreme lag. We tried everything, even completely reinstalling a completely blank NinjaTrader with no 3rd party indicators

Nothing helped. He was getting extreme lag even with a clean NinjaTrader.

Notice his machine is a beast, with more than enough CPU power, memory, and GPU power. Also, he has a high bandwidth internet connection

In fact, his PC is and internet connection is way higher & faster than mine, yet he experienced extreme lack while I did not.



In the end, we finally figured it out. He is using 6x 4k monitors and NinjaTrader can't seem to handle this

We changed the screen resolution for each monitor from 4k to 1920x1080 and boom Ninjatrader did not lag anymore

Next, we reinstalled all his 3rd party indicators, chart templates, workspaces, you name it and NinjaTrader performed just fine



So.. never use 4k monitors with NinjaTrader with a 4k screen resolution



Erwin


I assume you mean Ninjatrader 8?
What kind of lag are you referring to?
Did you or your friend only experience the lag with Ninjatrader?
What about using other apps? With/without Ninjatrader?
Did u use any resource monitor to try to pinpoint the issues?

I’ve been using Ninjatrader 8 with two 55” 4k monitors each running at 3840x2160 for the last 4 years. Earlier on I even had a workspace with around 50-60 charts covering both monitors. Haven’t experienced the lag you mentioned.

I’ve read about issues with Ninjatrader & large monitors but those are more drawing issues.

Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
  #20 (permalink)
 erwinbeckers   is a Vendor
 
Posts: 29 since Aug 2018
Thanks Given: 10
Thanks Received: 32


>I assume you mean Ninjatrader 8?
Yes although it also happens with NinjaTrader 7
NinjaTrader is famous for its lag, complains about it date back many many years.
Just google and you will find dozens (if not hundreds) of complaints, also on Ninja's own forum

>What kind of lag are you referring to?
Charts & Orders lagging for 10 seconds or more

>Did you or your friend only experience the lag with Ninjatrader?
yes.

>What about using other apps? With/without Ninjatrader?
Every other app just runs fine, only NinjaTrader lags
We tried TOS and MultiCharts on the same machine, with no issues, no lag.
Also, any other app for example browsing the internet just works fine

>Did u use any resource monitor to try to pinpoint the issues?
Oh, we tried everything, you can think of. I tried everything NinjaTrader suggests
Including using the NinjaScript Utilization Monitor, Chartlag indicator, and windows task manager.
As I said, we even did a completely clean install of NinjaTrader without any 3rd party indicators and with a clean database
The lag only finally disappeared when lowering the screen resolution to 1920x1080

Reply With Quote
Thanked by:




Last Updated on October 23, 2022


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts