Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Delayed entry

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

    Delayed entry

    This forum is now getting so large that it is very difficult to find any specific thing. Not a criticism but a fact.

    My coding ability is limited to the Wiz and a bit of fiddling but nothing serious! I have a problem to which there may not be an answer but any help would be appreciated.

    I have a situation where 2 events must take place before an entry can be made. The trigger is when Indicator 1 crosses the 0 line. Entry cannot be made until (and if) Indictor 2 crosses Indicator 3. This may not occur for one or two subsequent bars or may not occur within a max number of bars in which case the action is cancelled. Can such a deferred condition be programmed?

    Alternatively, entry is when Indicator 2 crosses Indicator 3 conditional on Indicator 1 having crossed 0 line within the last 2 bars?

    TIA
    Karl

    #2
    Hi Karl, yes the forum is always growing strongly - for your question though we have a fine reference sample available dealing with user variables / boolen flags in the wizard : http://www.ninjatrader.com/support/f...ad.php?t=15417

    This concept would let you create your conditions seeked, as the flags would stay with the value you set for them unless you reset them when entering your desired trade.
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Delayed Entry

      Thanks Bertrand - regardless of the size of the forum, the responses to queries are always prompt and I can assure you, appreciated. I shall go to the suggested link right away - thank you.
      K

      Comment


        #4
        You're welcome Karl, thanks for the kind words.
        BertrandNinjaTrader Customer Service

        Comment


          #5
          Delayed Entry

          Bertrand
          When we nominate a period of say 3 bars for an action to take place does it mean the action must take place at the close of the 3rd bar or at any time during the formation of the 3 bars? Sorry being a bit vague here but I am trying to apply a generic concept to a specific set of conditions.
          Thanks
          K

          Comment


            #6
            Karl, that would be hard to answer generically, for example for a CrossAbove / CrossBelow rule the lookPeriod would mean the crossover happens anywhere in the last 3 bars.

            If you compare a value to a exact numbers of bars for example in the past, the condition has less tolerance of course.
            BertrandNinjaTrader Customer Service

            Comment


              #7
              Delayed Entry

              Bertrand, in my line of code, can I assume that the condition is true if the EMA(8) crossed the EMA(20) at any point in time during the formation of the last 3 bars? (I use a Renko chart so time is not considered). If so, then I may have the answer to my problem.

              CrossAbove(EMA(Typical,8),EMA(Typical,20), 3)

              Regards
              Karl

              Comment


                #8
                That's correct Karl and it's just bars, so time not a component on your Renko charts. Have a good weekend.
                BertrandNinjaTrader Customer Service

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by trilliantrader, Today, 03:01 PM
                0 responses
                2 views
                0 likes
                Last Post trilliantrader  
                Started by pechtri, 06-22-2023, 02:31 AM
                9 responses
                122 views
                0 likes
                Last Post NinjaTrader_ChelseaB  
                Started by frankthearm, 04-18-2024, 09:08 AM
                16 responses
                67 views
                0 likes
                Last Post NinjaTrader_Clayton  
                Started by habeebft, Today, 01:18 PM
                1 response
                7 views
                0 likes
                Last Post NinjaTrader_ChelseaB  
                Started by benmarkal, Today, 12:52 PM
                2 responses
                19 views
                0 likes
                Last Post benmarkal  
                Working...
                X