This script fires off real-time RSI Divergence alerts.
To best use the RSI Divergence indicators, adjust the following settings accordingly. • RSI Bullish Divergence Under: 20 – 45 (lower for larger volatility and more bearish markets) • RSI Bearish Divergence Above: 55 – 80 (higher for larger volatility and more bullish markets)
Key Notes: 1. Set "Once Per Bar" instead of "Once Per Bar Close" alert. The strategy already uses prior bar close (instead of current bar close) for calculation. This ensures that the signals will stay as they are after fired off, even when the current bar price is still changing. 2. It's OKAY to see the "alert may trigger differently than expected" warning. Reason why you are seeing this warning is because we used a function called valuewhen() in our strategy. This function does not look at the entire history of data and has several limitations. For instance, on a 30min resolution, at the end of 2018, the function will be able to find past occurrences of BTC exceeding 16k. However, the function won't be able to find such occurrences at the end of 2019. Since our strategy is only concerned with very recent events, these limitations will not impact our results or cause repainting. You can find out more about this in the TradingView Wiki.