Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Force Chart Refresh on Strategy Start?

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

    Force Chart Refresh on Strategy Start?

    I have a strategy that takes trade signals off of 3rd party indicators. Some of these depend on real time data and have no values for historical data. I leave it up to the user to plot the indicators on the chart if they want to see what the strategy is "seeing", and the strategy creates it's own instances of the indicators for calculations.

    Here's the problem: If the chart has been open and running for some time, there will be data collected in the indicators that the user can see. If the user then starts (or restarts) the strategy, the strategy has no knowledge of that past data, and is starting from scratch. So what the user sees doesn't match what the strategy "sees".

    My two questions:

    1. Is there a way to force the chart and it's indicators to refresh programmatically on strategy start, the equivalent of hitting F5?

    2. Is it bad practice for some reason for me to plot the indicators from within the strategy instead of leaving them as indicators on the chart? If not, then any strategy restart would cause a visual restart of the plotted indicators, forcing them to be in sync, yes?

    #2
    Hi Prospectus,

    1. Unfortunately not.

    2. Correct, just add them from the strategy for display, thus they added in sync on strategy startup.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by charlesugo_1, 05-26-2026, 05:03 PM
    0 responses
    51 views
    0 likes
    Last Post charlesugo_1  
    Started by DannyP96, 05-18-2026, 02:38 PM
    1 response
    142 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 05-11-2026, 05:56 AM
    0 responses
    160 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 05-10-2026, 08:12 PM
    0 responses
    96 views
    0 likes
    Last Post CarlTrading  
    Started by Hwop38, 05-04-2026, 07:02 PM
    0 responses
    275 views
    0 likes
    Last Post Hwop38
    by Hwop38
     
    Working...
    X