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

Where is enum IndicatorMethod defined

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

    Where is enum IndicatorMethod defined

    I am modifying the indicator D3Spotter, and trying to add to it's indicator pull down list.
    It uses the enum IndicatorMethod to define a list of indicators to pick from like so,

    #region Variables
    private IndicatorMethod method;
    #endregion

    protected override void Initialize()
    switch (Method)
    {
    case IndicatorMethod.RSI:
    InitRSI(); //This Method adds Plots & Lines(not shown)
    Indicator = RSI(Period, 1);
    break;

    case IndicatorMethod.MACD:
    InitMACD(); //This Method adds Plots & Lines(not shown)
    Indicator = MACD(Fast, Slow, Smooth);
    break;
    }

    #region Properties
    [Category("Parameters"), Description("Indicator Method")]
    public IndicatorMethod Method
    { get {return method; }
    set {method = value; }
    }
    #endregion

    No method within D3Spotter defines IndicatorMethod, so I'm guessing that IndicatorMethod is a undocumented enum of Ninja.
    If it is undocument, where can I find the method that defines it

    Thanks
    Attached Files

    #2
    Unfortunately we would not be familiar with the exact custom code used, this is not a NT default enum, likely it's defined below the Properties region - for a general sample on using enums, please see this - http://www.ninjatrader-support2.com/...ead.php?t=3420
    BertrandNinjaTrader Customer Service

    Comment


      #3
      D3Spotter initialize....

      Zac, all I can say at the moment is... I tried that in V2. I have abanodoned that approach due to the various initializes needed, the indicator panel and the various lines/plots that gets drawn over and over. Look around for D3SpotterV2 which has all that in it. The enum is actually local to D3SpotterV2, here is the code that I was using..Ive attached it.

      not sure if this helps...
      Feel free to e-mail me directly
      [email protected]

      -David
      Attached Files

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Felix Reichert, 04-26-2024, 02:12 PM
      5 responses
      39 views
      0 likes
      Last Post NinjaTrader_BrandonH  
      Started by cmtjoancolmenero, 04-29-2024, 03:40 PM
      15 responses
      45 views
      0 likes
      Last Post NinjaTrader_Jesse  
      Started by ETFVoyageur, Yesterday, 06:05 PM
      6 responses
      37 views
      0 likes
      Last Post ETFVoyageur  
      Started by rbeckmann05, Today, 02:35 PM
      1 response
      6 views
      0 likes
      Last Post NinjaTrader_BrandonH  
      Started by Torontobluejays, Yesterday, 08:43 AM
      6 responses
      34 views
      0 likes
      Last Post rc5781
      by rc5781
       
      Working...
      X