NexusFi: Find Your Edge


Home Menu

 





Give NT preference over other application that are running


Discussion in NinjaTrader

Updated
    1. trending_up 3,135 views
    2. thumb_up 7 thanks given
    3. group 2 followers
    1. forum 9 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
 JimWalker 
Fairfax VA
 
Experience: Beginner
Platform: NinjaTrader
Posts: 41 since Dec 2009
Thanks Given: 1
Thanks Received: 39

All the applications running on your computer equally share your computer's resources. The NinjaTrader application runs at Normal Priority with all the other applications. Especially during fast markets, when other applications are running on your computer, NT is not processing incoming data as quickly as your computer would allow and possibly losing trade data from your market data service.

I have created a NT Indicator that sets NinjaTrader's Process Priority to High, giving NT preference over other applications that are running. It has been saved in the Futures.io Download Area.

NT 8 Version: https://nexusfi.com/local_links.php?linkid=1665
NT 7 Version: https://nexusfi.com/download/ninjatrader-7/indicators/1666-download.html?view

Adding this Indicator to one chart in your Workspace will set NinjaTrader's Process Priority High until you exit NT. The Indicator will check before setting the Priority and do nothing if Priority is already set to the Priority specified in its parameter.

Everyone trading with NT should run this indicator or running at High Process Priority should be coded into NinjaTrader.


Started this thread Reply With Quote
Thanked by:

Can you help answer these questions
from other members on NexusFi?
CFTC Requests Tag 50 Trader Identity Data From CME and I …
Traders Hideout
Penalties in Budapest, Peace Deadline in Tehran: Arsenal …
Prediction Markets & Event Contracts
Asia Equities Crash Overnight -- Nikkei -5.2%, KOSPI -6. …
Traders Hideout
SEC Advisory Committee Backs Tokenized Securities Exempt …
Traders Hideout
Hormuz Surges From 14% to 26.5% Intraday as Irans Answer …
Prediction Markets & Event Contracts
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Sober Journey With S&P
21 thanks
2026 Jlab journal
10 thanks
Algo automated / semi-automated trading anyone?
6 thanks
Lady Vols Primer: Trading Volatility Journal
6 thanks
2026 Fire Horse
5 thanks
  #2 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,669 since Jun 2009
Thanks Given: 33,669
Thanks Received: 102,557

I admire the ingenuity, but you might consider just setting it one time on start-up. Create a script that launches NinjaTrader, and then sets the priority, and it's done. Instead of an indicator that is constantly checking. You can replace the shortcut with a link to the script.

Changing Windows process priority via command line - Super User

This was the approach I used 5-6 years ago when I was using NT and wanted to accomplish the opposite of your intent, by setting NT to a lower priority since I was using it mainly for backtesting.

Mike




We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on X Visit my NexusFi Trade Journal Reply With Quote
Thanked by:
  #3 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,669 since Jun 2009
Thanks Given: 33,669
Thanks Received: 102,557


Actually here is what I used exactly, it's even simpler.

unix - Windows Equivalent of 'nice' - Stack Overflow

Mike




We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on X Visit my NexusFi Trade Journal Reply With Quote
Thanked by:
  #4 (permalink)
 JimWalker 
Fairfax VA
 
Experience: Beginner
Platform: NinjaTrader
Posts: 41 since Dec 2009
Thanks Given: 1
Thanks Received: 39

Your suggestion for Below Normal and Low Priority is a very good one. Currently the Indicator's Priority Parameter allows selection of Above Normal, or Normal. It is two line of NinjaScript to add the new ones.

The only Indicator overhead is an OnStateChange() test for (State == State.Configure), which would be done when Chart is loaded or Indicator parameters changed. If NT's Process Priority is already set to the specified Priority Parameter then nothing is done. Otherwise, NT's Process Priority is set to the Parameter value. There is no OnBarUpdate processing.


Started this thread Reply With Quote
Thanked by:
  #5 (permalink)
 
sam028's Avatar
 sam028 
Site Moderator
 
Posts: 3,756 since Jun 2009
Thanks Given: 3,825
Thanks Received: 4,632

Unless having a run-queue higher than the available CPU, let's say a run-queue of 12 with only 4 cores, then I don't think that will help.
If you mine bitcoins or search for E.T. with SETI project while using trading with NinjaTrader then it might help!


Success requires no deodorant! (Sun Tzu)
Follow me on X Reply With Quote
Thanked by:
  #6 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,669 since Jun 2009
Thanks Given: 33,669
Thanks Received: 102,557


sam028 View Post
Unless having a run-queue higher than the available CPU, let's say a run-queue of 12 with only 4 cores, then I don't think that will help.
If you mine bitcoins or search for E.T. with SETI project while using trading with NinjaTrader then it might help!

Agreed setting higher priority won't help speed anything up with Ninja. Lower priority did help though for backtesting, to still have a responsive machine.

Mike




We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on X Visit my NexusFi Trade Journal Reply With Quote
  #7 (permalink)
 JimWalker 
Fairfax VA
 
Experience: Beginner
Platform: NinjaTrader
Posts: 41 since Dec 2009
Thanks Given: 1
Thanks Received: 39


sam028 View Post
. . . I don't think that will help. . . .

I will be traveling for a couple of weeks. When I return I will convert another of my NT 7 Indicators. Testing it will also test your hypothesis and the improvement from NT 8 multi-threading. Will post the results. Thanks for your comments. Jim


Started this thread Reply With Quote
  #8 (permalink)
 JimWalker 
Fairfax VA
 
Experience: Beginner
Platform: NinjaTrader
Posts: 41 since Dec 2009
Thanks Given: 1
Thanks Received: 39

I have updated the NT 8 version with Big Mike's suggestion to add BelowNormal Priority value to selectable parameter. Other changes include:
New parm Show NT Priority.
Priority now also checked/set in State.Terminated.
Improved debugging information.
https://nexusfi.com/local_links.php?linkid=1665

Working on the NT 7 version to bring up to NT 8 level of features.


Started this thread Reply With Quote
Thanked by:
  #9 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,669 since Jun 2009
Thanks Given: 33,669
Thanks Received: 102,557

Notifications sent.

Mike




We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on X Visit my NexusFi Trade Journal Reply With Quote
  #10 (permalink)
 JimWalker 
Fairfax VA
 
Experience: Beginner
Platform: NinjaTrader
Posts: 41 since Dec 2009
Thanks Given: 1
Thanks Received: 39


NT 7 version of SetNinjaTradersPriorityHigh now has all NT 8 features.

Updated: Oct 22, 2015 8:30AM - New Priority value of BelowNormal. New parm ShowNTPriority. Priority changed only when required. New parameter Debug message to Output Window.


Started this thread Reply With Quote




Last Updated on October 22, 2015


© 2026 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 - Downloads - Top
no new posts