I am having problem with setting up alerts on an indicator with buy, sell, short, cover lables.
The condition for the signals is a when in trend. But at the moment I get a new alert for every candle my script is in trend. And obviously I only want it on the first bar in trend.
How can I set up my alert() or alertcondition() so it only will trigger once?