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

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);



    Free online storage and sharing with Screencast.com. 2 GB of storage and 2 GB of bandwidth per month for free. We won't compress, alter or take ownership of your content.

    #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 cre8able, Today, 01:16 PM
    2 responses
    9 views
    0 likes
    Last Post cre8able  
    Started by chbruno, 04-24-2024, 04:10 PM
    3 responses
    48 views
    0 likes
    Last Post NinjaTrader_Gaby  
    Started by samish18, Today, 01:01 PM
    1 response
    7 views
    0 likes
    Last Post NinjaTrader_LuisH  
    Started by WHICKED, Today, 12:56 PM
    1 response
    9 views
    0 likes
    Last Post NinjaTrader_Gaby  
    Started by WHICKED, Today, 12:45 PM
    1 response
    11 views
    0 likes
    Last Post NinjaTrader_Gaby  
    Working...
    X