Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Plot arrow adjustment

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

    Plot arrow adjustment

    the code in the pic works fine...
    i'm just trying to "fine tune" it to include an arrow when the current price can go 3 ticks below the sma 89.

    it doesn't have to be "exactly 3 ticks"...just not more than 10 ticks

    thank you

    if ((Diff[0]>DiffAvg[0] && Diff[1]<DiffAvg[1])
    && (High[0] >= SMA(89)[0])
    && (High[0] >= KeltnerChannel(1.5, 22).Lower[0] + -2 * TickSize)
    //&& (SMA(89)[0] - EMA(22)[0]< -3 )
    && (Diff[1] <= 0.175)
    && (Stochastics(5, 3, 3).K[1] <= stokl || Stochastics(5, 3, 3).K[2] <= stokl
    || Stochastics(5, 3, 3).K[0] <= stokl)

    )
    DrawArrowUp(Time[0].ToString(), 0, Low[1] - 0.25* TickSize, Color.Blue);



    World's leading screen capture + recorder from Snagit + Screencast by Techsmith. Capture, edit and share professional-quality content seamlessly.

    #2
    Then you would need to modify this line: High[0] >= SMA(89)[0]

    From what I understand on what you are trying to do you just want it to be more flexible in its drawing. Up to 10 ticks below SMA(89) you still want it to draw so just relax that condition to this: High[0] >= (SMA(89)[0] - 10 * TickSize)
    Josh P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    571 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    331 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
    549 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    549 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X