Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Taking short on strategy1 and long on strategy2 for the same ticker

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

    Taking short on strategy1 and long on strategy2 for the same ticker

    Hi experts,

    This is not exactly a coding question but approach to 2 strategies running at the same time for the same ticker.

    Strategy1 took a short and while the trade is still on, Strategy2 saw opportunity to go long. This will of course cause the account to go flat, instead of having 2 separate positions on.

    What's the general approach to this ? eg: Run Strategy1 on 1xES and Strategy2 on 10xMES ?

    Would love to hear some suggestions to this.

    Side question: I am using (Position.MarketPosition == MarketPosition.Flat) and will not place a trade if I am not flat. Can I confirm that this is only for positions opened by each Strategy instance ? i.e. I cannot use this in Strategy1 to check for positions opened by Strategy2.
    Last edited by elirion; 11-28-2023, 03:38 AM.

    #2
    Originally posted by elirion View Post
    What's the general approach to this ? eg: Run Strategy1 on 1xES and Strategy2 on 10xMES ?
    Sure, since that's two different instruments, your suggested example would work fine.

    But, for the same instrument, the general (and best) approach is to use two different accounts.



    Comment


      #3
      Originally posted by elirion View Post
      Side question: I am using (Position.MarketPosition == MarketPosition.Flat) and will not place a trade if I am not flat. Can I confirm that this is only for positions opened by each Strategy instance ? i.e. I cannot use this in Strategy1 to check for positions opened by Strategy2.
      That is correct.

      Each instance of each running strategy is a selfish bastard, and
      knows nothing and shares nothing to other strategies.



      Comment


        #4
        Hello elirion,

        Thanks for your post.

        You could consider running each strategy on a different instrument as you have noted.

        Or, you could consider enabling the strategy on the same instrument but different accounts.

        See this forum thread about running multiple strategies on the same instruments/account combination: https://ninjatrader.com/support/foru...tures-contract

        That is correct as bltdavid noted. Each strategy can only see orders submitted by that specific strategy instance. Strategy 1 can only see orders placed by Strategy 1 and cannot see orders placed by Strategy 2. This means that Position.MarketPosition == MarketPosition.Flat will only check to see if that specific strategy instance is in a flat position.
        <span class="name">Brandon H.</span><span class="title">NinjaTrader Customer Service</span><iframe name="sig" id="sigFrame" src="/support/forum/core/clientscript/Signature/signature.php" frameborder="0" border="0" cellspacing="0" style="border-style: none;width: 100%; height: 120px;"></iframe>

        Comment


          #5
          bltdavid & NinjaTrader_BrandonH

          thank you both of you for the answers

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by somanko, Yesterday, 11:51 AM
          4 responses
          29 views
          0 likes
          Last Post NinjaTrader_Gaby  
          Started by MitolynHead, Today, 07:00 AM
          0 responses
          2 views
          0 likes
          Last Post MitolynHead  
          Started by Stanfillirenfro, 02-07-2025, 06:50 AM
          13 responses
          69 views
          0 likes
          Last Post Stanfillirenfro  
          Started by reynoldsn, 02-11-2025, 09:37 AM
          7 responses
          26 views
          0 likes
          Last Post NinjaTrader_Gaby  
          Started by PH_GMT, Yesterday, 12:40 PM
          5 responses
          28 views
          0 likes
          Last Post NinjaTrader_Gaby  
          Working...
          X