PROTECTED SOURCE SCRIPT
Cập nhật X-Gold

This indicator visualizes the relationship between Gold’s global strength and the U.S. Dollar Index (DXY) to help traders identify periods of confluence or divergence between the two assets.
It combines:
# Gold Spread Index (GSI) – the average normalized value of XAU quoted against several major currencies (USD, AUD, CHF, EUR, GBP, and Silver).
This helps measure gold’s strength across global markets, not just against the U.S. dollar.
# Normalized DXY line – a z-scored and smoothed version of the U.S. Dollar Index for visual comparison.
The background highlights confluence zones:
🟢 Bullish Confluence – GSI trending up while DXY trends down
🔴 Bearish Confluence – GSI trending down while DXY trends up
⚫ Neutral / Divergence – both move in the same direction (often signals indecision or ranging conditions)
Key Features:
# Works on any timeframe
# Real-time background color zones for instant trend confluence visualization
# Optional alerts for buy/sell/neutral confluence transitions
# Clean layout in a separate panel for clear comparison
Disclaimer:
This script is for educational and analytical purposes only.
It does not provide financial advice or guarantee any trading outcomes.
Always perform your own analysis before making investment decisions.
It combines:
# Gold Spread Index (GSI) – the average normalized value of XAU quoted against several major currencies (USD, AUD, CHF, EUR, GBP, and Silver).
This helps measure gold’s strength across global markets, not just against the U.S. dollar.
# Normalized DXY line – a z-scored and smoothed version of the U.S. Dollar Index for visual comparison.
The background highlights confluence zones:
🟢 Bullish Confluence – GSI trending up while DXY trends down
🔴 Bearish Confluence – GSI trending down while DXY trends up
⚫ Neutral / Divergence – both move in the same direction (often signals indecision or ranging conditions)
Key Features:
# Works on any timeframe
# Real-time background color zones for instant trend confluence visualization
# Optional alerts for buy/sell/neutral confluence transitions
# Clean layout in a separate panel for clear comparison
Disclaimer:
This script is for educational and analytical purposes only.
It does not provide financial advice or guarantee any trading outcomes.
Always perform your own analysis before making investment decisions.
Phát hành các Ghi chú
add in setting for choosing to update background color only after bar closes.add in adjustable third instrument to be compared with gold strength.
Mã được bảo vệ
Tập lệnh này được đăng dưới dạng mã nguồn đóng. Tuy nhiên, bạn có thể tự do sử dụng tập lệnh mà không có bất kỳ hạn chế nào – tìm hiểu thêm tại đây.
Thông báo miễn trừ trách nhiệm
Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.
Mã được bảo vệ
Tập lệnh này được đăng dưới dạng mã nguồn đóng. Tuy nhiên, bạn có thể tự do sử dụng tập lệnh mà không có bất kỳ hạn chế nào – tìm hiểu thêm tại đây.
Thông báo miễn trừ trách nhiệm
Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.