Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

How to monitor resources

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How to monitor resources

    I've been developing some strategies which started out very simply with perhaps a few dozen lines of actual executable code (not counting variable declarations, parameters and the like).

    Over time, some of these strategies have ballooned to hundreds of lines. The vast majority is just assigning values to variables, and/or logic, and some basic indicator references (getting moving average values for example). My strategies tend to be run on Range bars and are COBC = FALSE.

    My question is: is there a way to determine how much actual time Ninja takes to update a strategy for a tick? Or, some other performance metric(s) that tells me how much the strategy is impacting the available resources.

    So far I haven't had any problems, but as I add more instruments and the strategies become ever more complex, I'd prefer to know, ahead of time, where I might get in trouble.

    What is best way to monitor system performance and/or anticipate problems? Or is it really just a subjective and empirical thing, just need to wait and watch for any problems?

    #2
    Hello,

    The best way to ensure your functions are being called as you expected is to use Print statements and checking the System time they are being printed. More advanced method would be using .NET's Stopwatch Class: http://msdn.microsoft.com/en-us/libr...stopwatch.aspx
    MatthewNinjaTrader Product Management

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by rtwave, 04-12-2024, 09:30 AM
    2 responses
    20 views
    0 likes
    Last Post rtwave
    by rtwave
     
    Started by tsantospinto, 04-12-2024, 07:04 PM
    5 responses
    68 views
    0 likes
    Last Post tsantospinto  
    Started by cre8able, Today, 03:20 PM
    0 responses
    7 views
    0 likes
    Last Post cre8able  
    Started by Fran888, 02-16-2024, 10:48 AM
    3 responses
    49 views
    0 likes
    Last Post Sam2515
    by Sam2515
     
    Started by martin70, 03-24-2023, 04:58 AM
    15 responses
    115 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Working...
    X