OPEN-SOURCE SCRIPT
Updated

Buy and Sell Signals (Altius Consulting)

218
Generates Buy and Sell signals based on MACD and RSI.

- Plots MACD, Signal & Histogram (optional pane).
- Buy Label (toggle): Bullish MACD crossover + RSI < threshold (no convergence requirement).
- Sell Label: Bearish MACD crossover (MACD crosses below Signal) prints a SELL tag.
- Alert: Provided for convergence-based buy condition (add your own for simple crossover if desired).
Release Notes
1. Convergence Buy: 3-bar contraction of |MACD-Signal| with MACD below Signal, then bullish crossover (+ optional RSI filter).
2. Simple Buy (toggle): Bullish crossover + RSI filter only.
3. Sell: Bearish crossover.
4. Convergence shading + status table (optional).
5. Alert: Only convergence buy.
Release Notes
Fixing some bugs

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.