OPEN-SOURCE SCRIPT
Hot_Cold_50W_200W_EMA

A MACD-style oscillator built from trend distance instead of raw EMAs. Instead of comparing two moving averages directly, it compares how far price has stretched from each one — surfacing whether short-term momentum is running ahead of or falling behind the long-term trend.
• Line 1 (orange) — % distance from the 200-week EMA (long-term trend)
• Line 2 (blue) — % distance from the 50-week EMA (short-term trend)
• Histogram — the gap between the two lines, shaded like a classic MACD histogram (full color when the gap is widening, faded when it's contracting)
A zero-line cross in the histogram marks a regime shift: short-term trend either breaking away from or collapsing back toward the long-term trend. Built-in alerts fire on both crossover directions.
Like its companion script (200W EMA Heat), all math runs on weekly bars via request.security() regardless of chart timeframe, with an "Avoid Repaint" toggle (on by default) to keep historical values stable.
Not financial advice — a momentum/regime tool meant to complement, not replace, your own analysis.
• Line 1 (orange) — % distance from the 200-week EMA (long-term trend)
• Line 2 (blue) — % distance from the 50-week EMA (short-term trend)
• Histogram — the gap between the two lines, shaded like a classic MACD histogram (full color when the gap is widening, faded when it's contracting)
A zero-line cross in the histogram marks a regime shift: short-term trend either breaking away from or collapsing back toward the long-term trend. Built-in alerts fire on both crossover directions.
Like its companion script (200W EMA Heat), all math runs on weekly bars via request.security() regardless of chart timeframe, with an "Avoid Repaint" toggle (on by default) to keep historical values stable.
Not financial advice — a momentum/regime tool meant to complement, not replace, your own analysis.
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuyla, bu komut dosyasının mimarı, yatırımcıların işlevselliğini inceleyip doğrulayabilmesi için onu açık kaynaklı hale getirdi. Yazarı tebrik ederiz! Ücretsiz olarak kullanabilseniz de, kodu yeniden yayınlamanın Topluluk Kurallarımıza tabi olduğunu unutmayın.
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, alım satım veya diğer türden tavsiye veya öneriler anlamına gelmez ve teşkil etmez. Kullanım Koşulları bölümünde daha fazlasını okuyun.
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuyla, bu komut dosyasının mimarı, yatırımcıların işlevselliğini inceleyip doğrulayabilmesi için onu açık kaynaklı hale getirdi. Yazarı tebrik ederiz! Ücretsiz olarak kullanabilseniz de, kodu yeniden yayınlamanın Topluluk Kurallarımıza tabi olduğunu unutmayın.
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, alım satım veya diğer türden tavsiye veya öneriler anlamına gelmez ve teşkil etmez. Kullanım Koşulları bölümünde daha fazlasını okuyun.