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

CrossAbove()

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

    CrossAbove()

    Hi,

    CrossAbove(EMA(10), EMA(20), 1)

    Checks for a cross above condition over the specified bar look back period.

    But I want to check Cross above for the current bar. Not for the look back period.

    Thanks

    #2
    Hi Sameer,

    Thank you for posting.

    Unfortunately, you would not be able to use the CrossBelow and CrossAbove to check the current bar. You will need to have a minimum of 1 or greater in order to work.


    Please let me know if I can be of further assistance.
    Last edited by NinjaTrader_CalH; 06-06-2013, 02:50 PM.
    Cal H.NinjaTrader Customer Service

    Comment


      #3
      Thank u very much.....but i checked this syntax it is not working in Strategy Analyzer for historical testing. Please verify

      Just I read this thread........

      Originally Posted by NinjaTrader_Matthew
      CrossAbove or CrossBelow will need to occur in the last 1 bar or greater. There is no way to check for a cross above/below 0 bars ago.

      For the simulator, are you running that strategy on Calculate On Bar Close set to True or False? In real-time, if you want the strategy to enter the position at the point these two values cross, you would need to run on COBC = false. When set to true, the strategy will not take action until that condition is true and the next bar has closed.

      More information on this property can be found below:

      http://www.ninjatrader.com/support/h...onbarclose.htm
      Last edited by Sameer; 06-06-2013, 02:29 PM.

      Comment


        #4
        Hi Sameer,

        Thanks for the update.

        Apologies.

        This is correct when trying to use the CrossAbove and CrossBelow. You will need to have a minimum of 1.

        Please let us know if we can be of further assistance.
        Cal H.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Taddypole, 04-26-2024, 02:47 PM
        1 response
        12 views
        0 likes
        Last Post NinjaTrader_Eduardo  
        Started by futtrader, 04-21-2024, 01:50 AM
        6 responses
        58 views
        0 likes
        Last Post futtrader  
        Started by sgordet, Today, 11:48 AM
        0 responses
        4 views
        0 likes
        Last Post sgordet
        by sgordet
         
        Started by Trader146, Today, 11:41 AM
        0 responses
        5 views
        0 likes
        Last Post Trader146  
        Started by jpapa, 04-23-2024, 07:22 AM
        2 responses
        22 views
        0 likes
        Last Post rene69851  
        Working...
        X