So I'm relatively new to all this and I've been combing the threads looking to see if I can find something related with no success, maybe it's what I'm searching for or I've missed it somehow. What I'm trying to come up with is a way to set up a study that would look to see is when a condition is met the first time and the difference in a separate parameter the second time that condition is met. An example let's say is that a condition I have is that I want to plot an arrow, this arrow would be triggered if the 20sma crosses above the 50 sma, but only if the close is greater than the last time that the 20sma crossed the 50 sma based on the timeframe of the chart I am currently on. I don't fully understand the lookback feature which is what I'm guessing I may need to use. I'd be happy to review and learn from any previous post if directed there, thank you in advance.