Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Buying & Selling vs. Reversing Positions

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

    Buying & Selling vs. Reversing Positions

    Hello,

    On the one hand, I've witnessed behavior whereby a new short signal will both close any existing long position and initialize a new short with the default position size (position reversal). I've done this using the "EnterLong" and "EnterShort" methods.

    If, on the other hand, I want to merely "buy" and "sell", without reversing positions (unless a position reversal occurs naturally...i.e. Long 1 --> sell 1 = flat --> sell 1 --> Short 1).

    What methods should I be using so that a new long signal does not completely reverse a short position, and vice versa?

    Kind Regards,
    CG

    #2
    Hello cgeorgan,

    Yes, the default behavior is for entries to reverse positions.

    You can add a check to your entries to verify that you are flat.

    if (Position.MarketPosition == MarketPosition.Flat)
    EnterLong();

    This help guide article can help with setting this in the strategy wizard.
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_RyanM View Post
      Hello cgeorgan,

      Yes, the default behavior is for entries to reverse positions.

      You can add a check to your entries to verify that you are flat.

      if (Position.MarketPosition == MarketPosition.Flat)
      EnterLong();

      This help guide article can help with setting this in the strategy wizard.
      I follow; is there a method to use what you've described here to merely sell part of a long position when a new short signal comes up, rather than sell the entire long and reverse?

      Comment


        #4
        In order to scale out of a position, you must first scale in. The scale out order quantity is then set from the quantity of your uniquely-named entry rules. The reference sample below can help with this:
        Scaling out of a position
        Ryan M.NinjaTrader Customer Service

        Comment


          #5
          Originally posted by NinjaTrader_RyanM View Post
          In order to scale out of a position, you must first scale in. The scale out order quantity is then set from the quantity of your uniquely-named entry rules. The reference sample below can help with this:
          Scaling out of a position
          Yes, I have noticed this methodology and have put it into use...that is, when I enter long positions, each unique entry generates a target exit and a trailing stop.

          However, sometimes I do not know where I want to exit part of my position, or where I thought I wanted to exit has now changed based on a new "sell" signal. Thus, if I was long at 1 with a target of 1.5, but my sell signal comes when price is 1.25, I now want to sell one of those contracts outright.

          I get the feeling you're going to tell me that I need to start looping through entries, matching orderID's, and adjusting target prices.

          I am hoping instead you'll tell me that somehow I can merely submit "buy" and "sell" orders that will do the following:
          -If I get a sell signal and i'm not long, create a new short position with associated target+stop;
          -If I get a sell signal and I'm long, sell one of my long contracts and cancel any associated target+stop orders.

          Comment


            #6
            Yes, using our managed order system will match exit quantities to the entry quantities based on signal name.

            We have introduced an unmanaged approach in our upcoming version 7. This will allow you more freedom, but the increased complexity means that there is more to manage on your own. Below link provides information on an unmanaged approach to strategy order submission.
            Ryan M.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by frankthearm, Today, 09:08 AM
            3 responses
            9 views
            0 likes
            Last Post NinjaTrader_Clayton  
            Started by yertle, Today, 08:38 AM
            5 responses
            15 views
            0 likes
            Last Post NinjaTrader_BrandonH  
            Started by adeelshahzad, Today, 03:54 AM
            3 responses
            16 views
            0 likes
            Last Post NinjaTrader_BrandonH  
            Started by bill2023, Yesterday, 08:51 AM
            6 responses
            27 views
            0 likes
            Last Post NinjaTrader_Erick  
            Started by NinjaTrader_ChelseaB, 01-08-2017, 06:59 PM
            80 responses
            19,667 views
            5 likes
            Last Post NinjaTrader_ChelseaB  
            Working...
            X