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 burtoninlondon, Today, 12:38 AM
    0 responses
    10 views
    0 likes
    Last Post burtoninlondon  
    Started by AaronKoRn, Yesterday, 09:49 PM
    0 responses
    14 views
    0 likes
    Last Post AaronKoRn  
    Started by carnitron, Yesterday, 08:42 PM
    0 responses
    11 views
    0 likes
    Last Post carnitron  
    Started by strategist007, Yesterday, 07:51 PM
    0 responses
    14 views
    0 likes
    Last Post strategist007  
    Started by StockTrader88, 03-06-2021, 08:58 AM
    44 responses
    3,983 views
    3 likes
    Last Post jhudas88  
    Working...
    X