v20 = 0.0 ma20 = ta.sma(close,20) if crossover(close,ma) v20 := 100
- When ma20 crossover occurs, we want to store 100 in a variable.
- The ma20 crossover event occurs frequently.
- What should I do to save when the 3rd event from the most recent occurs?
What have you tried? Pinescript Coding Execution What did you expect to happen? Store 100 in a variable What are the actual results? can't save