OPEN-SOURCE SCRIPT

Mutanabby_AI | Ultimate Algo | Remastered+

8 376
Overview


The Mutanabby_AI Ultimate Algo Remastered+ represents a sophisticated trend-following system that combines Supertrend analysis with multiple moving average confirmations. This comprehensive indicator is designed specifically for identifying high-probability trend continuation and reversal opportunities across various market conditions.

Core Algorithm Components


**Supertrend Foundation**: The primary signal generation relies on a customizable Supertrend indicator with adjustable sensitivity (1-20 range). This adaptive trend-following tool uses Average True Range calculations to establish dynamic support and resistance levels that respond to market volatility.

**SMA Confirmation Matrix**: Multiple Simple Moving Averages (SMA 4, 5, 9, 13) provide layered confirmation for signal strength. The algorithm distinguishes between regular signals and "Strong" signals based on SMA 4 vs SMA 5 relationship, offering traders different conviction levels for position sizing.

**Trend Ribbon Visualization**: SMA 21 and SMA 34 create a visual trend ribbon that changes color based on their relationship. Green ribbon indicates bullish momentum while red signals bearish conditions, providing immediate visual trend context.

**RSI-Based Candle Coloring**: Advanced 61-tier RSI system colors candles with gradient precision from deep red (RSI ≤20) through purple transitions to bright green (RSI ≥79). This visual enhancement helps traders instantly assess momentum strength and overbought/oversold conditions.

Signal Generation Logic


**Buy Signal Criteria**:
- Price crosses above Supertrend line
- Close price must be above SMA 9 (trend confirmation)
- Signal strength determined by SMA 4 vs SMA 5 relationship
- "Strong Buy" when SMA 4 ≥ SMA 5
- Regular "Buy" when SMA 4 < SMA 5

**Sell Signal Criteria**:
- Price crosses below Supertrend line
- Close price must be below SMA 9 (trend confirmation)
- Signal strength based on SMA relationship
- "Strong Sell" when SMA 4 ≤ SMA 5
- Regular "Sell" when SMA 4 > SMA 5

Advanced Risk Management System


**Automated TP/SL Calculation**: The indicator automatically calculates stop loss and take profit levels using ATR-based measurements. Risk percentage and ATR length are fully customizable, allowing traders to adapt to different market conditions and personal risk tolerance.

**Multiple Take Profit Targets**:
- 1:1 Risk-Reward ratio for conservative profit taking
- 2:1 Risk-Reward for balanced trade management
- 3:1 Risk-Reward for maximum profit potential

**Visual Risk Display**: All risk management levels appear as both labels and optional trend lines on the chart. Customizable line styles (solid, dashed, dotted) and positioning ensure clear visualization without chart clutter.

**Dynamic Level Updates**: Risk levels automatically recalculate with each new signal, maintaining current market relevance throughout position lifecycles.

Visual Enhancement Features


**Customizable Display Options**: Toggle trend ribbon, TP/SL levels, and risk lines independently. Decimal precision adjustments (1-8 decimal places) accommodate different instrument price formats and personal preferences.

**Professional Label System**: Clean, informative labels show entry points, stop losses, and take profit targets with precise price levels. Labels automatically position themselves for optimal chart readability.

**Color-Coded Momentum**: The gradient RSI candle coloring system provides instant visual feedback on momentum strength, helping traders assess market energy and potential reversal zones.

Implementation Strategy


**Timeframe Optimization**: The algorithm performs effectively across multiple timeframes, with higher timeframes (4H, Daily) providing more reliable signals for swing trading. Lower timeframes work well for day trading with appropriate risk adjustments.

**Sensitivity Adjustment**: Lower sensitivity values (1-5) generate fewer but higher-quality signals, ideal for conservative approaches. Higher sensitivity (15-20) increases signal frequency for active trading styles.

**Risk Management Integration**: Use the automated risk calculations as baseline parameters, adjusting risk percentage based on account size and market conditions. The 1:1, 2:1, 3:1 targets enable systematic profit-taking strategies.

Market Application


**Trend Following Excellence**: Primary strength lies in capturing significant trend movements through the Supertrend foundation with SMA confirmation. The dual-layer approach reduces false signals common in single-indicator systems.

**Momentum Assessment**: RSI-based candle coloring provides immediate momentum context, helping traders assess signal strength and potential continuation probability.

**Range Detection**: The trend ribbon helps identify ranging conditions when SMA 21 and SMA 34 converge, alerting traders to potential breakout opportunities.

Performance Optimization


**Signal Quality**: The requirement for both Supertrend crossover AND SMA 9 confirmation significantly improves signal reliability compared to basic trend-following approaches.

**Visual Clarity**: The comprehensive visual system enables rapid market assessment without complex calculations, ideal for traders managing multiple instruments.

**Adaptability**: Extensive customization options allow fine-tuning for specific markets, trading styles, and risk preferences while maintaining the core algorithm integrity.

## Non-Repainting Design

**Educational Note**: This indicator uses standard TradingView functions (Supertrend, SMA, RSI) with normal behavior patterns. Real-time updates on current candles are expected and standard across all technical indicators. Historical signals on closed candles remain fixed and unchanged, ensuring reliable backtesting and analysis.

**Signal Confirmation**: Final signals are confirmed only when candles close, following standard technical analysis principles. The algorithm provides clear distinction between developing signals and confirmed entries.

Technical Specifications


**Supertrend Parameters**: Default sensitivity of 4 with ATR length of 11 provides balanced signal generation. Sensitivity range from 1-20 allows adaptation to different market volatilities and trading preferences.

**Moving Average Configuration**: SMA periods of 8, 9, and 13 create multi-layered trend confirmation, while SMA 21 and 34 form the visual trend ribbon for broader market context.

**Risk Management**: ATR-based calculations with customizable risk percentage ensure dynamic adaptation to market volatility while maintaining consistent risk exposure principles.

Recommended Settings


**Conservative Approach**: Sensitivity 4-5, RSI length 14, higher timeframes (4H, Daily) for swing trading with maximum signal reliability.

**Active Trading**: Sensitivity 6-8, RSI length 8-10, intermediate timeframes (1H) for balanced signal frequency and quality.

**Scalping Setup**: Sensitivity 10-15, RSI length 5-8, lower timeframes (15-30min) with enhanced risk management protocols.

## Conclusion

The Mutanabby_AI Ultimate Algo Remastered+ combines proven trend-following principles with modern visual enhancements and comprehensive risk management. The algorithm's strength lies in its multi-layered confirmation approach and automated risk calculations, providing both novice and experienced traders with clear signals and systematic trade management.

Success with this system requires understanding the relationship between signal strength indicators and adapting sensitivity settings to match current market conditions. The comprehensive visual feedback system enables rapid decision-making while the automated risk management ensures consistent trade parameters.

Practice with different sensitivity settings and timeframes to optimize performance for your specific trading style and risk tolerance. The algorithm's systematic approach provides an excellent framework for disciplined trend-following strategies across various market environments.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.