Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

pLOTTING aNOMALY

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

    pLOTTING aNOMALY

    i wrote an indicator that works. In addition to the Signal, I plot 3 lines, an upper, zeroline and lower line according to the following

    Code:
         AddLine(Brushes.Red, .85, "Upper");                
                    AddLine(Brushes.White, 0, NinjaTrader.Custom.Resource.NinjaScriptIndicatorZeroLine);
                    AddLine(Brushes.Lime, -.85, "Lower");    
    
                    AddPlot(Brushes.Cyan, "EBSW");
    When the Indicator plots The white line pl;ots as the upper and the Red plots as the Zeroline. Yet the Indicators-->Properties--> Lines shows the Red as the Upper and White as the Zero and Lime as the Lower as desired. Why do the lines plot incorrectly.

    Thanks

    #2
    Hello dmking,

    I'm not certain that I am understanding.

    AddLine(Brushes.Red, .85, "Upper");

    This is a red line marked Upper. Did you not want this brush to be red?

    AddLine(Brushes.White, 0, NinjaTrader.Custom.Resource.NinjaScriptIndicatorZe roLine);

    This uses a NinjaTrader resource but has a white brush. Are you not wanting this to be white?
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      The colors are fine, but the order is reversed, Chelsea.

      As shown in the snippet,, I expected the Red line to plot in the upper part at " .85", on the chart and the white line to plot at "0", but as you can see in the picture, it's reversed as I explained.

      D
      Attached Files

      Comment


        #4
        Hello D,

        What Values index are you using when setting the values for these?
        Chelsea B.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by cmoran13, 04-16-2026, 01:02 PM
        0 responses
        43 views
        0 likes
        Last Post cmoran13  
        Started by PaulMohn, 04-10-2026, 11:11 AM
        0 responses
        25 views
        0 likes
        Last Post PaulMohn  
        Started by CarlTrading, 03-31-2026, 09:41 PM
        1 response
        163 views
        1 like
        Last Post NinjaTrader_ChelseaB  
        Started by CarlTrading, 04-01-2026, 02:41 AM
        0 responses
        98 views
        1 like
        Last Post CarlTrading  
        Started by CaptainJack, 03-31-2026, 11:44 PM
        0 responses
        158 views
        2 likes
        Last Post CaptainJack  
        Working...
        X