• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Not plotting right color.

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

    Not plotting right color.

    Hi,
    I have converted the attached indicator over from NT7 to NT8. It is only plotting in the color Gold, but should be also plotting in the other colors.
    I cannot see what the problem is, would you please take a look and advise me on what the issue
    Attached Files

    #2
    Hello KennyK,

    The plot that is gold is Values[3].
    ​​​​​​AddPlot(new Stroke(Brushes.Gold, 2), PlotStyle.Bar, "ColorLine");

    Are the other plot values being set?

    If Values[3] is not set do you see the other plots? (Meaning are they behind the gold plot?)

    If you print the value for the other plots what are the values of these? (i.e. Values[0], Values[1], Values[2])
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea,
      I wrote the script in the OnBarUpdate() section as follows: Print (Values[3]); I tried it with 0,1,2 as well but nothing appeared in the output window.
      What am I doing wrong?
      Ken.

      Comment


        #4
        Hi Chelsea,
        Got it working, I worked out that the gold "colorline" should have been a plotted line not a bar histogram. See attached screen shot.
        Thanks for your help. Would still like to know why I couldn't see anything in the output window? As per previous question.
        Ken.
        Attached Files

        Comment


          #5
          Hello KennyK,

          A barsAgo number would also need to selected with the plot selection.

          Values[plot index][barsAgo index]
          https://ninjatrader.com/support/help...-us/values.htm

          Print(Values[3][0]);
          Last edited by NinjaTrader_ChelseaB; 03-27-2019, 09:02 AM.
          Chelsea B.NinjaTrader Customer Service

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by futurenick, Today, 06:26 AM
          1 response
          7 views
          0 likes
          Last Post nkhoi
          by nkhoi
           
          Started by NinjaCustomer, Today, 12:29 PM
          0 responses
          1 view
          0 likes
          Last Post NinjaCustomer  
          Started by Steve L, Today, 11:32 AM
          0 responses
          2 views
          0 likes
          Last Post Steve L
          by Steve L
           
          Started by prabbala, Today, 10:41 AM
          0 responses
          1 view
          0 likes
          Last Post prabbala  
          Started by bebbus, Today, 10:36 AM
          0 responses
          3 views
          0 likes
          Last Post bebbus
          by bebbus
           
          Working...
          X