Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Best practices for NinjaScript testing. re: memory usage

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

    Best practices for NinjaScript testing. re: memory usage

    Not sure if this should be in the ninjascript directory since the underlying purpose involves memory usage of the actual application...

    I am writing a strategy based on prerecorded market data that utilizes a total of four barseries objects. My issue is that whenever I make changes to the strategy, recompile, and F5 in the chart window, my memory usage for NT jumps up another ~300MB. I can make changes up to five times before NT memory usage hits ~1.2GB and then throws "out of memory" errors in the Output window. I need to restart the application every five recompiles.

    My question is; is there a best practices way of testing strategy development wrt memory usage? I thought by closing the chart window that the garbage collector would free up the memory address space, but it doesnt. Should I be disposing my memory objects manually? If so, are there any examples?

    Hope all is well friends.

    #2
    You should always dispose of any objects you use. http://www.ninjatrader-support.com/H...6/Dispose.html


    For performance tips see this: http://www.ninjatrader-support.com/H...rformanceTips1

    Memory optimization is on the list for NT7.
    Josh P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by frankthearm, Today, 09:08 AM
    3 responses
    9 views
    0 likes
    Last Post NinjaTrader_Clayton  
    Started by yertle, Today, 08:38 AM
    5 responses
    15 views
    0 likes
    Last Post NinjaTrader_BrandonH  
    Started by adeelshahzad, Today, 03:54 AM
    3 responses
    16 views
    0 likes
    Last Post NinjaTrader_BrandonH  
    Started by bill2023, Yesterday, 08:51 AM
    6 responses
    27 views
    0 likes
    Last Post NinjaTrader_Erick  
    Started by NinjaTrader_ChelseaB, 01-08-2017, 06:59 PM
    80 responses
    19,667 views
    5 likes
    Last Post NinjaTrader_ChelseaB  
    Working...
    X