OPEN-SOURCE SCRIPT
Bullish Bearish Signal with EMA Color + Labels

This script generates clear BUY and SELL signals based on a combination of trend direction, momentum, and confirmation from multiple indicators. It is intended to help traders identify strong bullish or bearish conditions using commonly trusted tools: EMA 200, MACD, and RSI.
🔍 How it works:
The strategy combines three key elements:
EMA 200 Trend Filter
Identifies the long-term trend:
Price above EMA200 → Bullish trend bias
Price below EMA200 → Bearish trend bias
The EMA line is color-coded:
🔵 Blue for bullish
🔴 Red for bearish
⚪ Gray for neutral/unclear
MACD Crossover
Detects shifts in market momentum:
Bullish: MACD line crosses above signal line
Bearish: MACD line crosses below signal line
RSI Confirmation
Adds an extra layer of confirmation:
Bullish: RSI is above its signal line
Bearish: RSI is below its signal line
✅ Signal Logic:
BUY Signal appears when:
Price > EMA200
MACD crosses up
RSI > its signal line
SELL Signal appears when:
Price < EMA200
MACD crosses down
RSI < its signal line
Labels will appear on the chart to highlight these events.
🔔 Alerts:
The script includes alerts for both Buy and Sell conditions, so you can be notified in real-time when they occur.
📈 How to Use:
Best used in trending markets.
Recommended for higher timeframes (1H and above).
May be combined with other tools such as support/resistance or candlestick analysis.
⚠️ Disclaimer: This script is intended for educational purposes only and does not constitute financial advice or a trading recommendation.
🔍 How it works:
The strategy combines three key elements:
EMA 200 Trend Filter
Identifies the long-term trend:
Price above EMA200 → Bullish trend bias
Price below EMA200 → Bearish trend bias
The EMA line is color-coded:
🔵 Blue for bullish
🔴 Red for bearish
⚪ Gray for neutral/unclear
MACD Crossover
Detects shifts in market momentum:
Bullish: MACD line crosses above signal line
Bearish: MACD line crosses below signal line
RSI Confirmation
Adds an extra layer of confirmation:
Bullish: RSI is above its signal line
Bearish: RSI is below its signal line
✅ Signal Logic:
BUY Signal appears when:
Price > EMA200
MACD crosses up
RSI > its signal line
SELL Signal appears when:
Price < EMA200
MACD crosses down
RSI < its signal line
Labels will appear on the chart to highlight these events.
🔔 Alerts:
The script includes alerts for both Buy and Sell conditions, so you can be notified in real-time when they occur.
📈 How to Use:
Best used in trending markets.
Recommended for higher timeframes (1H and above).
May be combined with other tools such as support/resistance or candlestick analysis.
⚠️ Disclaimer: This script is intended for educational purposes only and does not constitute financial advice or a trading recommendation.
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。