This indicator draws signals on the chart when a Bullish MACD Crossover occurs at the same time RSI is "oversold", and also when Bearish MACD Crossover occurs at the same time RSI is "overbought"
Indicators are drawn on the chart in the following scenarios:
1. Bullish signal a. MACD bullish crossover occurs on a single bar b. RSI was below the Oversold threshold (29 by default) within the prior 5 bars
2. Bearish signal a. MACD bearish crossover occurs on a singnle bar b. RSI was above the Overbought threshold (71 by default) within the prior 5 bars
Release Notes
⋅
Removed other distractions off sample chart to give a better idea of the overlay indicators
1. Make a copy of the script.
2. on line 1, change code to " strategy(title="MACD crossover while RSI Oversold/Overbought", overlay=true, shorttitle="MACD Cross + RSI Oversold Overbought") "
3. add this to the end of the script,
strategy.entry("buy", true, when = crossoverBull and wasOversold)
strategy.close("buy", when = crossoverBear and wasOverbought)
GarethSA
⋅
@Bunghole, WOW thanks for the help
Vikkrannt_Shah
⋅
dose it repaints ?
JewellMichelle
⋅
Does this repaint ?
ykose1982
⋅
Can you add alert conditions? Thank you,
AZEEM_MAJEED
⋅
How do i use stochastic instead of rsi on this one
thank you