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

Strategy Wizard Example - Condition cancels?

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

    Strategy Wizard Example - Condition cancels?

    Is it possible and do you have an example on using Strategy Wizard to code a condition where (as an example):

    SMA 5 crosses above SMA 21 and no previous SMA 5 crosses have occured during the last 5 bars?

    Best Regards,
    Larry

    #2
    Hi Larry,

    Welcome to the NinjaTrader forums!

    I'm not aware of a sample that offers this. Specifying the crossover is straightforward, and you would have to check the individual values bar by bar to exclude crossovers for the previous days. Attached screenshot show this, checking the last couple days that the value the SMA 5 is below the value of SMA 21.

    Attached Files
    Ryan M.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Board game geek, Today, 01:34 AM
    0 responses
    4 views
    0 likes
    Last Post Board game geek  
    Started by morrnel, 05-12-2024, 06:07 PM
    3 responses
    38 views
    0 likes
    Last Post wzgy0920  
    Started by FishTrade, Yesterday, 11:11 PM
    0 responses
    7 views
    0 likes
    Last Post FishTrade  
    Started by Austiner87, Yesterday, 03:42 PM
    1 response
    21 views
    0 likes
    Last Post NinjaTrader_Manfred  
    Started by cshox, Yesterday, 11:11 AM
    2 responses
    16 views
    0 likes
    Last Post cshox
    by cshox
     
    Working...
    X