Exclude rollover period via OnBarUpdate

I need to disable ATR indicator for the rollover period of 4:30pm - 5:30pm New York. chat bot directed me to onbarupdate but didn’t offer command language to accomplish the task

Are you using a custom strategy that uses the ATR indicator? Are you plotting the ATR plots yourself? If so, you just need to create an if statement like to either not do anything between those time periods, OR outside of those time periods plot the ATR indicator?

I’m using a custom strategy that uses the ATR to place and adjust orders for addon positions once an initial entry is placed. When the strategy is enabled the ATR plots those changes at the close of every 30 minute bar. It usually blows up at rollover which for me in the US midwest is 4pm central time. This happens at nearly every rollover where I have a trade on in NZD/CAD. i’m no expert at anything (jack of some trades, master of none) but it seems to me that the larger spread at rollover cause a malfunction which closes everything including my open position often resulting in a loss. my thought was to instruct ATR to do nothing for the bars before/after rollover. there might be other solutions, maybe just accept the bid/ask at rollover which could result in a revere adjustment 30 minutes later but I don’t care about that. i’ve been looking at NT’s online info hoping to figure it out. gives me a headache.

So can you access and change the code of the custom strategy? If so, you should be able to edit the code to either only plot during certain times, or add that set time to catch the strategy and simply do nothing during that time. It depends on how the code was programmed and what other things happen during rollover. Are you only trying to prevent the ATR to plot during rollover? Is there anything else that happens during the rollover that you may still need to happen?