Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Paint Bar

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

    Paint Bar

    i have 2 indicators that paint bars when conditions are met.

    trying to have indicator #1 look to see if indicator #2 has been triggered within the last 5 bars before painting bar.

    #2
    more info

    indicator #1 has the following once conditions are met
    Code:
    [SIZE=2][FONT=Courier New]Purple_Short.Set([/FONT][/SIZE][FONT=Courier New][SIZE=2][COLOR=#800080].75[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2]); [/SIZE][/FONT]
    trying to add indicator #1 to indicator #2
    Code:
    && Purple_Short.[FONT=Courier New][SIZE=2][COLOR=#008000][COLOR=black]MAX(High,5)[0]== .75[/COLOR][/COLOR][/SIZE][/FONT]
    trying to see if indicator #1 has been triggered within the last 5 bars.

    if indicator #1 has been triggered within the last 5 bars...and of course all the conditions on indicator #2 have been met...then a bar will be painted

    i know how to paint bars and add plots, but can't seem to combine these two

    Comment


      #3
      && MAX(Purple_Short,5)[0]== .75

      was hoping this would work, but seems to be missing something..it does compile, but wont paint any bars

      Comment


        #4
        Hello,

        I am sorry, you will need to debug it. I do not know why this is happening.
        DenNinjaTrader Customer Service

        Comment


          #5
          this may work

          this seems to work. it's the complete title or name of indicator as opposed to just the "Set" deal
          Code:
          [SIZE=2][FONT=Courier New][FONT=Courier New][SIZE=2]&& MAX(Bar_Purple_Long_and_Short_Bool_Test_v1([/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]30[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]30[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]30[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]2.618[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]18[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]2[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]63500[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]125500[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2]).Purple_Short,[/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]5[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2])[[/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]0[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2]]== [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080].75
          [/COLOR][/SIZE][/FONT][FONT=Courier New][/FONT][/FONT][/SIZE]

          Comment


            #6
            I have found that it is always best to use a dataSeries for this. It makes life a lot easier.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            558 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            324 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            101 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            545 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            547 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X