Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Convert ready made strategy to Indicator

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

    Convert ready made strategy to Indicator

    Hi,
    I created strategy for my automation, I need to convert this strategy to be indicator, therefor I could see when I need to enable the strategy by looking bar colour area. Thanks

    #2
    Welcome to the forumsHaryh007,

    Thanks for your post.

    Indicators do not have a Position object, so you essentially would want to track a variable for when the strategy would be long/flat so that you can colorize the chart so it is visible what position the strategy would be in.

    This could be recreated mostly by changing BackBrush based on the same conditions the strategy would call EnterLong() to enter and ExitLong() to exit, but since there is no Position tracking in an indicator, it would not be as easy to show what a position would be based on stop and limit order fills.

    BackBrush - https://ninjatrader.com/support/help...?backbrush.htm

    Alternatively, you could consider colorizing in a strategy that gets applied to the Sim101 account to show what the strategy position would be with X settings. You could use OnExecutionUpdate to track when the strategy Position changes to control when drawing should be made on the chart.

    OnExecutionUpdate - https://ninjatrader.com/support/help...tionupdate.htm

    Position - https://ninjatrader.com/support/help...8/position.htm

    We look forward to assisting.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by SalmaTrader, 07-07-2026, 10:26 PM
    0 responses
    35 views
    0 likes
    Last Post SalmaTrader  
    Started by CarlTrading, 07-05-2026, 01:16 PM
    0 responses
    20 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 06-17-2026, 10:32 AM
    0 responses
    12 views
    0 likes
    Last Post CaptainJack  
    Started by kinfxhk, 06-17-2026, 04:15 AM
    0 responses
    18 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 06-17-2026, 04:06 AM
    0 responses
    20 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Working...
    X