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

Indicator as input series for strategy not working

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

    Indicator as input series for strategy not working

    Hey,
    I found divergence engine indicator in a discord group and tried to build it in a strategy, It uses input series to select indicator (oscillator's) to show divergences . but when i used in strategy script its not showing indicator as input series in "data series". i had no issues in standalone indicator. After goin through forum, found out i should use it in "state. Configure" instead data loaded but I don't know how to do it . Tried this
    Code:
     [NinjaScriptProperty, Display(Name = "External Indicator", GroupName = "EXT INDICATOE", Order = 17)]
            [PropertyEditor("NinjaTrader.Gui.Tools.InputEditor")]
            public Indicator indi
            { get; set; }​
    its showing in parameters, But giving object don't have instance error and its not calling oscillator .
    Please Help




    Attached Files

    #2
    Hello ceeb69,

    Selecting an indicator from a drop-down would not instantiate an instance of that indicator. You would need to call the indicator method to instantiate an instance of the indicator.

    If you are trying to switch between indicators in the logic, we would recommend using an enum for this.

    Below is a link to the help guide reference sample which demonstrates.

    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by burtoninlondon, Today, 12:38 AM
    0 responses
    9 views
    0 likes
    Last Post burtoninlondon  
    Started by AaronKoRn, Yesterday, 09:49 PM
    0 responses
    14 views
    0 likes
    Last Post AaronKoRn  
    Started by carnitron, Yesterday, 08:42 PM
    0 responses
    11 views
    0 likes
    Last Post carnitron  
    Started by strategist007, Yesterday, 07:51 PM
    0 responses
    13 views
    0 likes
    Last Post strategist007  
    Started by StockTrader88, 03-06-2021, 08:58 AM
    44 responses
    3,983 views
    3 likes
    Last Post jhudas88  
    Working...
    X