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

The problem with the drawing of the indicator

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

    The problem with the drawing of the indicator

    Good day, please help solve the problem. I wrote an indicator that displays the histogram when certain conditions are met. For drawing, I substituted values "i" in the formula with time variables, which were obtained using a loop

    for (var i = 0; i < N; i++)

    the result was this picture


    but I need the indicator to be drawn in the future, where there is no price, like this



    Could you give me advice on how to make the indicator draw in the area where the price has not yet formed

    Thanks in advance

    #2
    Hello Kovalev,

    Thanks for the post.

    You will need to use the displacement property for this:



    Please let me know if I can assist further.
    Chris L.NinjaTrader Customer Service

    Comment


      #3
      Hello, NinjaTrader_ChrisL, did I understand correctly that this function looks the same in ninjatrader 7?

      Comment


        #4
        Hello Kovalev,

        Thanks for the reply. My apologies, I did not see that we are in the NinjaTrader 7 forum section!

        This thread describes how you can plot in the future for NinjaTrader 7:



        You can either pass negative values to the Values[][] index or use the displacement property.

        https://ninjatrader.com/support/help...splacement.htm - Displacement

        Please let me know if I can assist further.
        Chris L.NinjaTrader Customer Service

        Comment


          #5
          NinjaTrader_ChrisL, thank you for your help, it has become much better, but I would like to make the indicator draw a picture completely, when a signal appears, now it draws parts when each new bar appears.


          But I thought something like this


          help please

          Comment


            #6
            Hello Kovalev,

            Thanks for the reply.

            It looks like a displacement is not applied. Positive displacement values will plot into the future. Could you provide some code snippets for me to review?

            I look forward to your reply.
            Chris L.NinjaTrader Customer Service

            Comment


              #7
              NinjaTrader_ChrisL, I'm sorry, i rebooted the terminal and it worked. NinjaTrader_ChrisL, thank you very much for your help!

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by judysamnt7, 03-13-2023, 09:11 AM
              4 responses
              57 views
              0 likes
              Last Post DynamicTest  
              Started by ScottWalsh, Today, 06:52 PM
              4 responses
              36 views
              0 likes
              Last Post ScottWalsh  
              Started by olisav57, Today, 07:39 PM
              0 responses
              7 views
              0 likes
              Last Post olisav57  
              Started by trilliantrader, Today, 03:01 PM
              2 responses
              19 views
              0 likes
              Last Post helpwanted  
              Started by cre8able, Today, 07:24 PM
              0 responses
              9 views
              0 likes
              Last Post cre8able  
              Working...
              X