Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Using AdoptAccountPosition

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

    Using AdoptAccountPosition

    I created a multi-Instrument strategy and I don't need ninjatrader do any historical processing on a strategy. I just need it adopt the current account positions and continue.


    I set
    IsAdoptAccountPositionAware = true;
    StartBehavior = StartBehavior.AdoptAccountPosition;

    I use a simulator account. Every time I restart the strategy all positions reset to zero. What can I do to prevent this?
    Last edited by ManTrader; 07-09-2019, 01:25 PM.

    #2
    Hello ManTrader,

    Thank you for your post.

    To clarify, the behavior is that you have a manually placed order, and despite being set to IsAdoptAccountPositionAware = true and StartBehavior = StartBehavior.AdoptAccountPosition, all orders are being closed instead of adopted as the strategy position, is that correct?

    Could you explain further how you are checking for the account position when the strategy is enabled? If you have a reduced version of your strategy (you can remove all code not necessary to reproduce the behavior) that would be very helpful.

    Thanks in advance; I look forward to assisting you further.

    Comment


      #3
      Sorry, I was testing with Playback account! Simulate account is working correctly. You can remove this issue.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by NullPointStrategies, Yesterday, 05:17 AM
      0 responses
      62 views
      0 likes
      Last Post NullPointStrategies  
      Started by argusthome, 03-08-2026, 10:06 AM
      0 responses
      134 views
      0 likes
      Last Post argusthome  
      Started by NabilKhattabi, 03-06-2026, 11:18 AM
      0 responses
      75 views
      0 likes
      Last Post NabilKhattabi  
      Started by Deep42, 03-06-2026, 12:28 AM
      0 responses
      45 views
      0 likes
      Last Post Deep42
      by Deep42
       
      Started by TheRealMorford, 03-05-2026, 06:15 PM
      0 responses
      50 views
      0 likes
      Last Post TheRealMorford  
      Working...
      X