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

Calling TSSuperTrend

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

    Calling TSSuperTrend

    Hello Support,

    I am adding TSSuperTrend for my indicator Exit Strategies in the following manner:

    if (TSSuperTrend(3,TradingStudies.NinjaScript.Utility .MovingAverageType.HMA,1.99,8,TradingStudies.Ninja Script.Utility.SuperTrendMode.ATR).DownTrend.Conta insValue(0) && !ExitLongDone)
    ExitLongProcess();
    else
    if
    TSSuperTrend(3,TradingStudies.NinjaScript.Utility. MovingAverageType.HMA,1.99,8,TradingStudies.NinjaS cript.Utility.SuperTrendMode.ATR).UpTrend.Contains Value(0) && !ExitShortDone)
    ExitShortProcess();

    Adding this, when the indicator is called, Window Task Manager reported a quickly ascending memory usage, till about 1.6 GB when it ninja get exception and need to shutdown.

    I have used similar construct to add other indicators as exit strategies without any issue, normally just adding a few MB to memory usage.
    Is there anything wrong with TSSuperTrend?
    If one construct strategy using the Wizard and add the TSSuperTrend, it would also results in "out of memory" when executed.

    Would appreciate your help on this issue.

    Thanks.

    Regards.
    Edward K

    #2
    Edward, could you please clarify: when does the memory usage spike? Is it when you add the TSSuperTrend indicator to a chart? Or when adding it to a strategy (during a backtest?)?
    AustinNinjaTrader Customer Service

    Comment


      #3
      Calling TSSuperTrend

      Hello Austin,

      Adding TSSuperTrend on a chart does not cause the issue.
      But adding my indicator (that calls TSSuperTrend) on a chart cause the issue.
      Running strategy that call my indicator that call TSS cause the issue.
      Months ago I have used Strategy wizard to use TSSuperTrend resulting in crash, but not confirmed if it is due to the same issue.
      If my indicator uses the same construct but call other indicator, it has no such issue.

      Thanks.

      Edward K.

      Comment


        #4
        Edward, since TSSuperTrend is a 3rd party indicator, I would recommend contacting the author of it for assistance. It sounds like there could be some underlying problems in the code.
        AustinNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by GwFutures1988, Today, 02:48 PM
        1 response
        5 views
        0 likes
        Last Post NinjaTrader_Clayton  
        Started by ScottWalsh, 04-16-2024, 04:29 PM
        6 responses
        32 views
        0 likes
        Last Post ScottWalsh  
        Started by frankthearm, Today, 09:08 AM
        10 responses
        36 views
        0 likes
        Last Post frankthearm  
        Started by mmenigma, Today, 02:22 PM
        1 response
        4 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by NRITV, Today, 01:15 PM
        2 responses
        10 views
        0 likes
        Last Post NRITV
        by NRITV
         
        Working...
        X