Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy Programming with User-Adjustable ATM

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

    Strategy Programming with User-Adjustable ATM

    Hi everyone,

    I’m working on building a strategy in NinjaTrader and I’m looking for some guidance on how to structure it properly.

    What I’d like to achieve is this:
    • When a certain condition is met the strategy should open a new position. (I assume with EnterLongLimit() / EnterShortLimit() )
    • Once the trade is open, I want it to trigger an ATM strategy.
    • The ATM parameters (like profit target and stop loss will be set upfront) but the user will be able to adjust it directly from the chart, just like a normal ATM trade.

    I’m aware of the difference between NinjaScript strategies and ATM strategies, and I know that mixing them can be tricky. But I’m hoping there’s a way to initiate an ATM strategy from NinjaScript that still allows flexibility for the user to tweak the settings via the UI.

    Any examples, tips, or direction would be hugely appreciated. I’ve looked into AtmStrategyCreate() but I’m not sure how to keep the setup dynamic and interactive.

    Thanks in advance!

    #2
    Hello MattDavid,

    Thank you for your post.

    Through ATM Strategy Methods, your NinjaScript Strategy generates trade signals for an ATM Strategy, which would trigger an ATM Strategy/template.
    Because NinjaScript Strategies are only handling the entry/close signals, ATM Strategy methods like AtmStrategyCreate() can already accomplish what you have described.

    ATM parameters would depend on the template you have selected.
    ATM Strategies themselves are managed separately and appear on the Chart Trader. So they can be adjusted just like any other ATM Strategy.
    AtmStrategyCreate() will use the template you specify, so if you wish to adjust this template dynamically, you will need to save any changes you've made to a template with the same template name.

    ATM methods must be coded from within the NinjaScript Editor:Additionally, you may reference the SampleAtmStrategy script that is included in the platform.
    Testing this out on a chart will show you how you can manually adjust the ATM strategy from the UI on the chart, just like any other ATM strategy.

    Please let us know if we may be of any further assistance.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Mindset, 04-21-2026, 06:46 AM
    0 responses
    86 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by M4ndoo, 04-20-2026, 05:21 PM
    0 responses
    125 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by M4ndoo, 04-19-2026, 05:54 PM
    0 responses
    64 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by cmoran13, 04-16-2026, 01:02 PM
    0 responses
    117 views
    0 likes
    Last Post cmoran13  
    Started by PaulMohn, 04-10-2026, 11:11 AM
    0 responses
    67 views
    0 likes
    Last Post PaulMohn  
    Working...
    X