OPEN-SOURCE SCRIPT
MRB Cycle Oscillator Alpha

**Overview**
The "MRB Cycle Oscillator Alpha" is a highly advanced, multi-dimensional momentum and trend-analysis tool. It is not just another MACD; it upgrades traditional momentum concepts by combining Triple Exponential Smoothing (TES), mathematically derived momentum "Cycle Candles," RSI-confluent Bollinger Bands, and an ADX/DMI-driven background. This provides traders with a unified dashboard for trend direction, momentum strength, and mean-reversion zones without cluttering the main chart.
**What makes it original? (Core Concepts)**
This script brings originality to the Community Scripts by fusing several independent mathematical concepts into a single cohesive oscillator:
1. **TES-MACD (Triple Exponential Smoothing):** Instead of standard EMAs, this indicator calculates the MACD utilizing a custom Triple Exponential Smoothing (TES) algorithm. This significantly reduces market noise and lag compared to a traditional MACD.
2. **Momentum Cycle Candles:** Instead of displaying a raw oscillator line, the script extracts the open, high, low, and close values directly from the TES-MACD's historical delta. It then applies a custom smoothing algorithm to generate "Cycle Candles." This unique transformation visualizes momentum shifts and trend persistence much more clearly than a standard line or histogram.
3. **RSI-Dynamic Bollinger Bands:** Bollinger Bands are applied directly to the oscillator (users can choose to base it on the MACD Line EMA or the Signal Line TES). Furthermore, the outer bands dynamically change color based on the traditional chart's RSI values (e.g., turning green when RSI is overbought, red when oversold). This provides a dual-confirmation for extreme conditions.
4. **ADX/DMI Background Matrix:** The indicator calculates ADX and ±DI in the background. If the ADX crosses a user-defined threshold, the chart background changes color based on the dominant DI (green for uptrends, red for downtrends). This acts as a macro-trend filter.
**How to use it**
* **Trend Confirmation:** Use the background color (driven by ADX/DMI) to filter your trades. Only look for long setups when the background is green, and short setups when red.
* **Momentum Shifts:** Watch the color and body of the Cycle Candles in the oscillator pane. A transition from red to green indicates a shift to bullish momentum.
* **Overextended Zones (Mean Reversion):** When the Cycle Candles pierce the outer Bollinger Bands, AND the bands themselves change color (triggered by RSI extremes), it signals a highly overextended market, warning of a potential reversal or pullback.
**Customization**
Every element is modular. Traders can disable the Cycle Candles view in favor of a standard line, toggle the Bollinger Bands, adjust the RSI thresholds for band coloring, and fine-tune the ADX/DMI periods for background filtering.
The "MRB Cycle Oscillator Alpha" is a highly advanced, multi-dimensional momentum and trend-analysis tool. It is not just another MACD; it upgrades traditional momentum concepts by combining Triple Exponential Smoothing (TES), mathematically derived momentum "Cycle Candles," RSI-confluent Bollinger Bands, and an ADX/DMI-driven background. This provides traders with a unified dashboard for trend direction, momentum strength, and mean-reversion zones without cluttering the main chart.
**What makes it original? (Core Concepts)**
This script brings originality to the Community Scripts by fusing several independent mathematical concepts into a single cohesive oscillator:
1. **TES-MACD (Triple Exponential Smoothing):** Instead of standard EMAs, this indicator calculates the MACD utilizing a custom Triple Exponential Smoothing (TES) algorithm. This significantly reduces market noise and lag compared to a traditional MACD.
2. **Momentum Cycle Candles:** Instead of displaying a raw oscillator line, the script extracts the open, high, low, and close values directly from the TES-MACD's historical delta. It then applies a custom smoothing algorithm to generate "Cycle Candles." This unique transformation visualizes momentum shifts and trend persistence much more clearly than a standard line or histogram.
3. **RSI-Dynamic Bollinger Bands:** Bollinger Bands are applied directly to the oscillator (users can choose to base it on the MACD Line EMA or the Signal Line TES). Furthermore, the outer bands dynamically change color based on the traditional chart's RSI values (e.g., turning green when RSI is overbought, red when oversold). This provides a dual-confirmation for extreme conditions.
4. **ADX/DMI Background Matrix:** The indicator calculates ADX and ±DI in the background. If the ADX crosses a user-defined threshold, the chart background changes color based on the dominant DI (green for uptrends, red for downtrends). This acts as a macro-trend filter.
**How to use it**
* **Trend Confirmation:** Use the background color (driven by ADX/DMI) to filter your trades. Only look for long setups when the background is green, and short setups when red.
* **Momentum Shifts:** Watch the color and body of the Cycle Candles in the oscillator pane. A transition from red to green indicates a shift to bullish momentum.
* **Overextended Zones (Mean Reversion):** When the Cycle Candles pierce the outer Bollinger Bands, AND the bands themselves change color (triggered by RSI extremes), it signals a highly overextended market, warning of a potential reversal or pullback.
**Customization**
Every element is modular. Traders can disable the Cycle Candles view in favor of a standard line, toggle the Bollinger Bands, adjust the RSI thresholds for band coloring, and fine-tune the ADX/DMI periods for background filtering.
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。