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 plot values

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

    indicator plot values

    Hello i am working on an indicator X which will expose some values so that the indicator can then be called from a strategy or other indicator
    To be able to access these values in strategy builder the plots need to be defined. Is it correct that the plot series returned from indicator X can only be defined as
    series<double> type - ie if i want to return some boolean or enum based values as Plots (to be accessible in strategy builder) i presume i need to convert/translate those to integer/decimal values ie for the boolean 1 or 0 and enums 1 2 3 4 etc - knowing which is which. Will strategy builder or otherwise and plots ever support returning values for bars that are not just series<double> ?
    I presume the same applies to market analyser columns and conditions based on the indicator X as well.

    The ninjascript editor i thought in past had more provision to automate generating code ie say i want to do a moving average of data exported from indicator X? Seems the code stub 'could' be generated in strategy builder - and cut paste ? any reason why ninjascript indicator editor doesnt provide the same building process ? was this not how it was in NT7?

    thanks

    #2
    Hello explorer101,

    This would be limitations of the Strategy Builder and the New Indicator Wizard.

    The New Indicator Wizard plots are only doubles (in the Values). For the strategy builder specifically to call an indicator series it must be a plot.

    The custom series can be bools, doubles, strings, or datetimes, but these are not public.

    If you wanted these to be public the script would need to be unlocked, and these series would need to be changed to public and have the [XmlIgnore()] attribute applied.

    Then the strategy would also need to be unlocked to call these public series in the indicator (as only plots can be used in the Strategy Builder)

    So while what you want to achieve is possible, it would have to be coded by hand.


    Are you referring to the Insert Code Snippet?
    https://ninjatrader.com/support/help...heMouseOrF2Key
    Last edited by NinjaTrader_ChelseaB; 10-17-2019, 07:15 AM.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hello thanks for reply.

      When you say above 'if you wanted these to be public the script .....' are you referring to Indicator X code (which the user would not see as would be imported as addon assembly) ?

      I understand in the code for the strategy or indicator calling and making reference to indicator X that i/user would need to unlock code to access other values.
      So those custom series in indicator X would be made public and be aligned with the bars index of chart bars?
      So if i specifically wanted to return a bool series i would make it custom and public with XMLIgnore() and the user would then access this in the code.

      I believe i follow what you are saying in that only Plots can be accessed in the strategy builder.

      Regarding the current version of the indicator editor 'wizard' my question was are there plans to combine and include the condition builder component that is part of the strategy builder into the indicator builder. In its current form it is quite basic and rudimentary defining inputs and plots but no access to reference other indicators.

      thanks

      Comment


        #4
        Hello explorer101,

        Yes, in the indicator that is creating the series you want to call from an external script.

        A custom series added on the Additional Data page of the Indicator Wizard (or the Strategy Builder) adds the new Series<T> as a private series so it is not accessible from outside of the class.

        This would need to be changed to public to be called from outside of the class (like the way inputs work).

        Yes, series have 1 bar slot for every bar of the primary series.

        Yes, this would need the [XmlIgnore()] attribute applied to prevent errors when saving the workspace or a template (.xml files).

        Yes, this would allow the indicator to be called from another script and provide a bool series, or string series, etc.

        You are able to reference other indicators from the Strategy Builder.

        Custom series in an indicator that are not plots cannot be accessed from the Strategy Builder.

        There are no plans at this time to change the Strategy Builder to work with custom series.
        The strategy builder is limited in functionality to simple comparisons. For any math, counting, or custom logic (such as using a bool series or string series) would require the strategy to be unlocked and coded by hand.
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          thanks chelsea for the clarifications on the series.
          Not sure if you misunderstood my last question - it was more related to the current Indicator wizard in the ninjascript editor being expanded to include the condition builder piece that exists in the strategy builder? make sense?
          thanks

          Comment


            #6
            Hello explorer101,

            I will submit a feature request on your behalf for an Indicator Builder (in addition to the Indicator Wizard).

            Once I have a tracking ID for this request I will post in this thread for future reference.
            Chelsea B.NinjaTrader Customer Service

            Comment


              #7
              thanks for response - im surprised this is not there already as thought it would be a re-useable component from the strategy builder.
              As i mentioned at start - users can use the strategy builder to get code segments based on the conditional logic piece in the conditional builder open the code and cut paste.
              This is not specifically needed by me but potentially other users who are less familiar with coding and want the conditional piece in the indicator wizard

              Comment


                #8
                Hello, did they come back with any tracking ID on this ?

                Comment


                  #9
                  Hello explorer101,

                  Thank you for your reply.

                  I'm responding on behalf of Chelsea, who is out of the office today.

                  We have added a vote for you to a current feature request to create Strategy Builder style interfaces for more objects, such as Indicators. This request is being tracked under the number SFT-1557.

                  As with all feature requests, interest is tracked before implementation is considered, so we cannot offer an ETA or promise of fulfillment. If implemented, it will be noted in the Release Notes page of the Help Guide.

                  Release Notes — https://ninjatrader.com/support/help...ease_notes.htm

                  Please let us know if we may be of further assistance to you.
                  Kate W.NinjaTrader Customer Service

                  Comment


                    #10

                    Please add my vote for SFT-1557, Thanks.

                    "..feature request to create Strategy Builder style interfaces for more objects, such as Indicators. This request is being tracked under the number SFT-1557."


                    Comment


                      #11
                      Welcome to the forums sleven!

                      This thread is a bit old and was not captured immediately by our ticketing system, so we apologize for a delayed response.

                      We have tracked your vote, and thanks for sharing your interest!
                      JimNinjaTrader Customer Service

                      Comment

                      Latest Posts

                      Collapse

                      Topics Statistics Last Post
                      Started by aa731, Today, 02:54 AM
                      0 responses
                      4 views
                      0 likes
                      Last Post aa731
                      by aa731
                       
                      Started by thanajo, 05-04-2021, 02:11 AM
                      3 responses
                      469 views
                      0 likes
                      Last Post tradingnasdaqprueba  
                      Started by Christopher_R, Today, 12:29 AM
                      0 responses
                      10 views
                      0 likes
                      Last Post Christopher_R  
                      Started by sidlercom80, 10-28-2023, 08:49 AM
                      166 responses
                      2,237 views
                      0 likes
                      Last Post sidlercom80  
                      Started by thread, Yesterday, 11:58 PM
                      0 responses
                      4 views
                      0 likes
                      Last Post thread
                      by thread
                       
                      Working...
                      X