Note: I definitely wouldn't recommend using it to enter trades unless you're an experienced counter-trend trader :)
Go to http://www.zenandtheartoftrading.com for articles on forex trading, trading psychology, trading resources, Pine Script lessons and more!
// Check to see if a signal has been generated within our lookback period
for i = 1 to 10
rsiOB := false
rsiOS := false