OPEN-SOURCE SCRIPT
TPG Trend + MACD

User Guide for "TPG Trend + MACD"
Author: TrungChuThanh
🔎 Main Functions
The TPG Trend + MACD indicator is a combined tool that integrates:
TPG Trend Histogram (spread between fast and slow EMA)
MACD Line & Signal for confirming trend momentum
Buy/Sell signals displayed directly on the indicator panel
⚙️ Components and Meaning
1️⃣ TPG Trend Histogram
Calculated from the difference between Fast EMA (9) and Slow EMA (26).
Light gray bars = bullish trend (spread > 0)
Dark gray bars = bearish trend (spread < 0)
Signal triggers:
B1 (green label): Crossover above 0 → Buy signal
S1 (red label): Crossunder below 0 → Sell signal
2️⃣ MACD Line & Signal
Consists of:
MACD Line = EMA(12) – EMA(26)
Signal Line = EMA(9) of the MACD Line
Confirmation signals:
B2 (blue triangle): MACD crosses above Signal → Buy confirmation
S2 (orange triangle): MACD crosses below Signal → Sell confirmation
MACD Line: Blue
Signal Line: Orange
📌 How to Use
Determine the main trend using the TPG Histogram
→ When the histogram crosses above zero → Consider Buy
→ When it crosses below zero → Consider Sell
Use MACD to confirm trend direction or optimize entry timing
✅ Prefer signals when both TPG and MACD align (e.g., B1 + B2 or S1 + S2)
⚠️ Avoid using the indicator alone; combine with support/resistance, RSI, volume, or other tools for higher accuracy
🛠️ Adjustable Parameters
Fast/Slow EMA for TPG Trend
Fast/Slow/Signal for MACD
Toggle to show/hide TPG and MACD elements in the panel
⚠️ Notes
This is a technical analysis tool, not investment advice
Always apply risk management, set clear stop-loss, and confirm signals across multiple timeframes
Author: TrungChuThanh
🔎 Main Functions
The TPG Trend + MACD indicator is a combined tool that integrates:
TPG Trend Histogram (spread between fast and slow EMA)
MACD Line & Signal for confirming trend momentum
Buy/Sell signals displayed directly on the indicator panel
⚙️ Components and Meaning
1️⃣ TPG Trend Histogram
Calculated from the difference between Fast EMA (9) and Slow EMA (26).
Light gray bars = bullish trend (spread > 0)
Dark gray bars = bearish trend (spread < 0)
Signal triggers:
B1 (green label): Crossover above 0 → Buy signal
S1 (red label): Crossunder below 0 → Sell signal
2️⃣ MACD Line & Signal
Consists of:
MACD Line = EMA(12) – EMA(26)
Signal Line = EMA(9) of the MACD Line
Confirmation signals:
B2 (blue triangle): MACD crosses above Signal → Buy confirmation
S2 (orange triangle): MACD crosses below Signal → Sell confirmation
MACD Line: Blue
Signal Line: Orange
📌 How to Use
Determine the main trend using the TPG Histogram
→ When the histogram crosses above zero → Consider Buy
→ When it crosses below zero → Consider Sell
Use MACD to confirm trend direction or optimize entry timing
✅ Prefer signals when both TPG and MACD align (e.g., B1 + B2 or S1 + S2)
⚠️ Avoid using the indicator alone; combine with support/resistance, RSI, volume, or other tools for higher accuracy
🛠️ Adjustable Parameters
Fast/Slow EMA for TPG Trend
Fast/Slow/Signal for MACD
Toggle to show/hide TPG and MACD elements in the panel
⚠️ Notes
This is a technical analysis tool, not investment advice
Always apply risk management, set clear stop-loss, and confirm signals across multiple timeframes
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。