Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Horizontal Divergence line

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

    #61
    Did I do everything here correctly? Do I need to not copy/paste anything? Thank you..

    I thought that was too easy I compiled it had a bunch of errors. I seen a couple of them.
    Attached Files
    Last edited by trdninstyle; 06-02-2020, 02:34 PM.

    Comment


      #62
      Hello trdninstyle,

      Thank you for your reply.

      Not quite.

      You're missing the two lines at the top in the strategy:

      private BLTTriggerLines BLTTriggerLines1;
      private BLTTriggerLines BLTTriggerLines2;

      Also, you can't use AddChartIndicator() in an indicator. Instead, you would need to create plots to match what the indicator plots would be and assign the appropriate values to the plots as in the video I created.

      The other option would be to just remove the AddChartIndicator part entirely and not to plot them from within the indicator itself but to add them to the chart separately and just let the indicator use the values from them to change the background part.

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

      Comment


        #63
        I made some of those changes I need to sit down & watch your video again so I can see how u created plots to match what the indicator plots would be with the appropriate values.
        "you would need to create plots to match what the indicator plots would be and assign the appropriate values to the plots as in the video I created"

        I want the indicator to do it's stuff so I can do mine This look better except for the above last part?
        Attached Files
        Last edited by trdninstyle; 06-02-2020, 04:27 PM.

        Comment


          #64
          Hello trdninstyle,

          Thank you for your reply.

          Getting there! You can remove the setting of the plot brushes for the BLTTriggerLines in State.DataLoaded - those would be used to change the plot colors in a strategy, but when you add plots the user can configure those themselves.

          Here's a link to our help guide that goes over adding plots that may be helpful:



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

          Comment


            #65
            Hello Kate and Chelsea,

            Does this look all correct? On the 2nd pic towards the bottom I at first deleted #endregion then put it back. Do I keep that there or delete it? I started a New Indicator so I can put in the Plots and lines.

            Attached Files

            Comment


              #66
              Hi Kate,

              Hows this now? Do I also delete .. else if (state == State.DataLoaded) ? Do I keep #endregion (2nd pic above) or delete it? I seen your post but right now it's not there... maybe it's my connection? I posted wrong pic hang on

              I never took a picture of it! duh (Cant even spell duh right) lol
              Attached Files
              Last edited by trdninstyle; 06-03-2020, 09:18 AM.

              Comment


                #67
                Hello trdninstyle,

                Thank you for your reply.

                You've deleted where you assigned the indicators to the variables you're using to reference them in State.DataLoaded. The first two lines in that section need to be put back in.

                Also, it looks like you deleted the entire #region Properties, of which #endregion is the end of it. This section is necessary because this is what initializes user inputs and also you'll need it for your plots, so this section should not be deleted.

                If you set up any user inputs and necessary plots in the wizard, this section will be automatically generated for you and should not be removed unless you remove all plots and user inputs.

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

                Comment


                  #68
                  Okay that does make sense. Now how does it look?
                  Attached Files

                  Comment


                    #69
                    Hello trdninstyle,

                    Our role is not necessarily to check your work. We can answer specific questions, but this would involve you breaking down the issue to the problem at hand so we can share our insight for the specific question.

                    Are you stuck on something specific? If so, what specific thing are you trying to accomplish that you are having difficulty with?

                    Our general advise for copying strategy code into an indicator is to make sure that all variables and plots are added in the indicator so when you copy the code over, it will compile. There may be some parts where strategy specific code will need to be removed when it cannot be implemented in an indicator (like AddChartIndicator.)

                    You may find it helpful to start building a simple indicator using the New Indicator Wizard in the NinjaScript Editor as a starting point and then following our AddPlot documentation for how plots are created and assigned values. Once you are more familiar with the structure of indicators, it will make more sense when trying to build an indicator from existing code.

                    AddPlot - https://ninjatrader.com/support/help...8/?addplot.htm

                    Please let us know if you have any questions.
                    JimNinjaTrader Customer Service

                    Comment


                      #70
                      Hello Jim,

                      I apologize I did not know that I was taking advantage of the help support? The support staff as I can tell are top notch they helped me tremendously.

                      Much regards,

                      Bill

                      Comment


                        #71
                        I just want to thank Kate for her professionalism and that my indicator compiled!! Thank you Kate!! )) You are the best.

                        Comment

                        Latest Posts

                        Collapse

                        Topics Statistics Last Post
                        Started by lightsun47, Today, 03:51 PM
                        0 responses
                        4 views
                        0 likes
                        Last Post lightsun47  
                        Started by 00nevest, Today, 02:27 PM
                        1 response
                        8 views
                        0 likes
                        Last Post 00nevest  
                        Started by futtrader, 04-21-2024, 01:50 AM
                        4 responses
                        44 views
                        0 likes
                        Last Post futtrader  
                        Started by Option Whisperer, Today, 09:55 AM
                        1 response
                        13 views
                        0 likes
                        Last Post bltdavid  
                        Started by port119, Today, 02:43 PM
                        0 responses
                        9 views
                        0 likes
                        Last Post port119
                        by port119
                         
                        Working...
                        X