Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

many entries on the same bar

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

    many entries on the same bar

    hello i have some problems with the ninja player, i am playing my strategy in the CL with unirenko bars i have the brand playback activated. but sometimes it makes me many entries in the same bar when it should only make one. and my performans is triggered producing me many entries i would like to know how i can solve that. i attach some screenshots.

    the problem usually happens at 16:30 but also at 00:00, but I do not create new bar goes crazy buying or selling,
    Attached Files

    #2
    Hello JesusSanchez,

    Many entries per bar is generally caused by using OnEachTick or OnPriceChange calculation mode and the entry condition remaining true. You could add logic to make sure only one entry can happen per bar. Generally the BarsSinceEntry could be used for that purpose:



    if ((BarsSinceEntryExecution() > 0 || BarsSinceEntryExecution() == -1))

    This method reports -1 if no entry was found, otherwise it counts up from the entry bar. You could use 0 and -1 as the values to make sure it is not on the same identical bar.

    I look forward to being of further assistance.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    47 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    22 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    33 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    50 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    42 views
    0 likes
    Last Post CarlTrading  
    Working...
    X