Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Back Testing with Automated Order Entry

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

    Back Testing with Automated Order Entry

    I have ATM Strategies I want to back test over multiple days using Playback. In an effort to NOT have to stop and start 90 times, I would like to automate the ATM entry process if possible. For instance, I would like to automatically place 1 order (using the ATM) everyday at 6pm EST. I would then like to automatically close all remaining orders at 3:30pm the next day. Then, start over again when the Market opens at 6pm. Wash, Rinse & Repeat for 90 days.

    There has to be a way to do this. Any help, suggestions, guidance or cyanide pill would be greatly appreciated!

    Thanks,

    Bob

    #2
    Hello Bob,

    Thanks for your post.

    You could consider implementing a Time filter in your strategy to limit when orders are placed by the strategy.

    A Time Comparison could be used to check if the Time is 3:30PM and you could call AtmStrategyClose() to cancel any working orders and close any open position of a strategy using the default ATM strategy close behavior.

    It would be up to you to program custom logic that repeats the behavior for 90 days in a row. You could do some research on using C# DateTime to repeat a behavior for 90 days.

    See the help guide documentation below for more information.

    Time Filter: https://ninjatrader.com/support/help...ateTimeFilters
    Time Comparison: https://ninjatrader.com/support/help...imeComparisons
    Time: https://ninjatrader.com/support/help...eries_time.htm
    Atm Strategy Close: https://ninjatrader.com/support/help...ategyclose.htm
    Atm Strategy Methods: https://ninjatrader.com/support/help...gy_methods.htm
    Using Atm Strategies in custom NinjaScripts: https://ninjatrader.com/support/help...strategies.htm

    Let me know if I may assist further.
    <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

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, Today, 05:17 AM
    0 responses
    50 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    127 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    69 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    42 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    46 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X