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

First Trade - Set To Entry Only

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

    First Trade - Set To Entry Only

    Hi,

    When enabling a strategy, how do I set the strategy to only place an entry order for the first signal? For example I'm flat, enable strategy. Next signal comes along and It's executing an entry order and also an exit order ( I had no posistion yet).

    Please note strategy was created using Strategy Builder, so no commands please. Strategy is not set to fill historical orders.

    Thank you.

    #2
    Welcome to the forums here Bob, could you please clarify what you mean by 'Strategy is not set to fill historical orders'?

    Do you mean 'Wait Until Flat' is enabled from Tools > Options > Strategies > NinjaScript?
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Hi,

      To clarify, I do not have the radio button checked for 'Immediatey submit live working historical orders' in the Ninjascript Strategies Options tab.

      Thank you.


      Comment


        #4
        Ok, correct - with this mode you would not see any historical strategy position being managed with exit order, it would only take the next freshly generated entry.
        BertrandNinjaTrader Customer Service

        Comment


          #5
          It's not taken the next generated order though.

          If quantity = 10,000, it places an entry of 10,000 contracts and also a close position of 10,000. That's fine once I'm in a position, but first trade should only be for 10,000, not 20,000.

          It appears the strategy believes I have an open position once I enable it.

          Thanks.
          Last edited by bob77713; 02-20-2013, 10:17 AM.

          Comment


            #6
            You might have a virtual position, but this would not be a real position as in the terms of managed by the strategy. Is this a reversal type of system? Do you perhaps have duplicate Exit calls in your conditions that would not be needed, since the Enter() method would already do the reverse for you if needed?
            BertrandNinjaTrader Customer Service

            Comment


              #7
              I was able to figure it out on my own.

              For the 'Order Handling' of strategy, change the 'Sync Account Position' to True.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by Trader146, Today, 09:17 PM
              0 responses
              5 views
              0 likes
              Last Post Trader146  
              Started by ttrader23, 05-08-2024, 09:04 AM
              9 responses
              43 views
              0 likes
              Last Post ttrader23  
              Started by ZeroKuhl, Yesterday, 04:31 PM
              8 responses
              46 views
              0 likes
              Last Post ZeroKuhl  
              Started by reynoldsn, Today, 07:04 PM
              0 responses
              11 views
              0 likes
              Last Post reynoldsn  
              Started by puapwr, Today, 06:09 PM
              0 responses
              5 views
              0 likes
              Last Post puapwr
              by puapwr
               
              Working...
              X