OPEN-SOURCE SCRIPT
GoldAlgo DXY

GoldAlgo DXY puts the US Dollar Index in a panel under your Gold (XAUUSD) chart and translates it into one simple question: is the dollar a headwind or a tailwind for gold right now?
WHY THE DOLLAR
Gold is priced in dollars, so most of the time it trades inverse to the Dollar Index: a rising DXY pressures gold down, a falling DXY supports it. Watching the two side by side is one of the oldest edges in gold trading — this tool does it for you and reads the relationship out loud.
HOW IT WORKS
1. The dollar in a panel. DXY is plotted as candles (or a line) on your chart's own timeframe, with a trend EMA (default 50) over it.
2. The bias tint. The panel background shades softly red while the dollar trends above its EMA (headwind for gold) and softly green while it trends below (tailwind), so the bias is readable at a glance without studying the candles.
3. The correlation check. A rolling correlation between gold and DXY is tracked over a configurable lookback. On gold it normally sits deep negative; when it drifts toward zero the panel flags the relationship as broken — on those days, trust the dollar less.
ON-CHART DASHBOARD
A live panel shows the DXY price, today's percentage change, the dollar trend, the current gold/DXY correlation with a broken-relationship flag, and the resulting gold bias in plain words: headwind or tailwind.
ALERTS
Alert conditions for the dollar turning up (crossing above its EMA) and turning down (crossing below), so you catch the shifts in the gold backdrop from your phone.
SETTINGS
Dollar Index symbol, candles or line, trend EMA length, correlation lookback, bias tint on/off, and full color customization.
IMPORTANT
GoldAlgo DXY works only on Gold (XAUUSD). On any other symbol it displays a notice instead of drawings. This is an educational analysis tool: correlation is a tendency, not a rule — it does not predict the market and it is not financial advice. Always use proper risk management and never risk capital you cannot afford to lose.
WHY THE DOLLAR
Gold is priced in dollars, so most of the time it trades inverse to the Dollar Index: a rising DXY pressures gold down, a falling DXY supports it. Watching the two side by side is one of the oldest edges in gold trading — this tool does it for you and reads the relationship out loud.
HOW IT WORKS
1. The dollar in a panel. DXY is plotted as candles (or a line) on your chart's own timeframe, with a trend EMA (default 50) over it.
2. The bias tint. The panel background shades softly red while the dollar trends above its EMA (headwind for gold) and softly green while it trends below (tailwind), so the bias is readable at a glance without studying the candles.
3. The correlation check. A rolling correlation between gold and DXY is tracked over a configurable lookback. On gold it normally sits deep negative; when it drifts toward zero the panel flags the relationship as broken — on those days, trust the dollar less.
ON-CHART DASHBOARD
A live panel shows the DXY price, today's percentage change, the dollar trend, the current gold/DXY correlation with a broken-relationship flag, and the resulting gold bias in plain words: headwind or tailwind.
ALERTS
Alert conditions for the dollar turning up (crossing above its EMA) and turning down (crossing below), so you catch the shifts in the gold backdrop from your phone.
SETTINGS
Dollar Index symbol, candles or line, trend EMA length, correlation lookback, bias tint on/off, and full color customization.
IMPORTANT
GoldAlgo DXY works only on Gold (XAUUSD). On any other symbol it displays a notice instead of drawings. This is an educational analysis tool: correlation is a tendency, not a rule — it does not predict the market and it is not financial advice. Always use proper risk management and never risk capital you cannot afford to lose.
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.
Open-source Skript
Ganz im Sinne von TradingView hat dieser Autor sein/ihr Script als Open-Source veröffentlicht. Auf diese Weise können nun auch andere Trader das Script rezensieren und die Funktionalität überprüfen. Vielen Dank an den Autor! Sie können das Script kostenlos verwenden, aber eine Wiederveröffentlichung des Codes unterliegt unseren Hausregeln.
Haftungsausschluss
Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.