INVITE-ONLY SCRIPT

DTC v1.4

254
The Dynamic Trading Companion (DTC v1.3) is a comprehensive Pine Script indicator designed for TradingView to assist traders in analyzing market trends, identifying key price levels, and planning trade setups across multiple timeframes. This indicator integrates Central Pivot Range (CPR), Support and Resistance (S/R) levels, Exponential Moving Averages (EMAs), Average True Range (ATR) filtering, and a Multi-Timeframe (MTF) Dashboard to provide a robust analytical toolset. It generates buy and sell signals, visualizes potential Take Profit (TP) and Stop Loss (SL) levels, and offers a customizable dashboard for quick trend assessment.
Access: This script is published as Public with Invite-Only visibility, meaning it is listed in TradingView’s public library but accessible only to users who receive an invitation from the author. This ensures controlled distribution while maintaining transparency for approved users.
Purpose
DTC v1.3 is designed to support traders in making informed decisions by combining multiple technical analysis tools. It is suitable for various trading styles (e.g., day trading, swing trading) and markets (stocks, forex, crypto, etc.) on any TradingView-supported timeframe. The indicator emphasizes trend identification, key price level analysis, and risk management, with a focus on multi-timeframe alignment for stronger trade setups.
Key Features
1. Central Pivot Range (CPR): Plots daily Pivot, Bottom Central (BC), and Top Central (TC) levels based on the previous day’s high, low, and close prices to identify dynamic support/resistance zones.
2. Support and Resistance Levels: Displays daily S1, S2, S3 (support) and R1, R2, R3 (resistance) levels to highlight key price zones for potential reversals or breakouts.
3. EMA-Based Trend Detection: Uses six customizable EMAs (default periods: 30, 35, 40, 45, 50, 60) to detect bullish or bearish trends based on their alignment.
4. Buy/Sell Signals: Generates visual signals when all EMAs align in a bullish (ascending) or bearish (descending) order, with an optional ATR filter to confirm high-volatility conditions.
5. Take Profit and Stop Loss Visualization: Plots up to four TP levels and one SL level based on a 6-bar lookback period, aiding in risk-reward planning.
6. Multi-Timeframe Dashboard: A table summarizing trend status (Bullish, Bearish, or Neutral) for five user-defined timeframes (default: 15m, 30m, 1h, 4h, 1D) and the current chart timeframe, along with ATR filter status.
7. ATR Filter: Optionally filters signals based on ATR to ensure trades occur in high-volatility environments, reducing false signals.
8. Alerts: Configurable alerts for buy and sell signals, triggered once per bar close, with ticker-specific messages.
Technical Calculations
• CPR Calculation:
• Pivot = (High + Low + Close) / 3
• Bottom Central (BC) = (High + Low) / 2
• Top Central (TC) = (Pivot - BC) + Pivot
• Calculated using daily data and plotted as crosses (when enabled).
• Support/Resistance Calculation:
• S1 = (Pivot × 2) - High
• S2 = Pivot - (High - Low)
• S3 = Low - 2 × (High - Pivot)
• R1 = (Pivot × 2) - Low
• R2 = Pivot + (High - Low)
• R3 = High + 2 × (Pivot - Low)
• Fetched from the previous day’s data using request.security with lookahead enabled.
• EMA Calculation:
• Six EMAs (default periods: 30, 35, 40, 45, 50, 60) are calculated using the close price.
• Bullish condition: EMA7 > EMA8 > EMA9 > EMA10 > EMA11 > EMA12.
• Bearish condition: EMA7 < EMA8 < EMA9 < EMA10 < EMA11 < EMA12.
• EMAs are color-coded (lime for bullish, red for bearish, gray for neutral) with a silver fill (60% transparency) between the fastest and slowest EMAs.
• ATR Filter:
• ATR = 14-period Average True Range (configurable).
• Threshold = 50-period SMA of ATR × Multiplier (default: 0.5).
• Signals require ATR > Threshold when the filter is enabled.
• TP/SL Calculation:
• Buy Signals:
• SL = Lowest low of the past 6 bars.
• Risk = Entry price (close) - SL.
• TP1 = Entry + Risk, TP2 = Entry + 2×Risk, TP3 = Entry + 3×Risk, TP4 = Entry + 4×Risk.
• Sell Signals:
• SL = Highest high of the past 6 bars.
• Risk = SL - Entry price (close).
• TP1 = Entry - Risk, TP2 = Entry - 2×Risk, TP3 = Entry - 3×Risk, TP4 = Entry - 4×Risk.
• Plotted as dashed (TP) and dotted (SL) lines with price labels.
• MTF Dashboard:
• Trend status is calculated for each timeframe using EMA alignment logic via request.security.
• Displayed in a 2-column, 10-row table with color-coded backgrounds (green for bullish, red for bearish, gray for neutral).
Input Parameters
• CPR Settings:
• Show CPR Levels (bool, default: false): Toggles Pivot, BC, and TC display.
• Show S/R Levels (bool, default: false): Toggles S1, S2, S3, R1, R2, R3 display.
• EMA Settings:
• Slow EMA 1–6 Lengths (int, default: 30, 35, 40, 45, 50, 60): Configurable EMA periods.
• ATR Settings:
• Enable ATR Filter (bool, default: true): Enables/disables ATR-based signal filtering.
• ATR Length (int, default: 14): Period for ATR calculation.
• ATR Multiplier (float, default: 0.5, step: 0.1): Multiplier for ATR threshold.
• Alert Settings:
• Enable Buy/Sell Alerts (bool, default: false): Toggles alerts for signals.
• TP/SL Settings:
• Show Entry/SL/TP Levels (bool, default: true): Toggles entry, SL, and TP visualization.
• Dashboard Settings:
• Show Dashboard (bool, default: true): Toggles MTF dashboard display.
• Timeframe 1–5 (timeframe, default: 15m, 30m, 1h, 4h, 1D): User-selectable timeframes for trend analysis.
Visual Outputs
• CPR Plots: Pivot (blue, solid), BC/TC (blue, semi-transparent) as crosses.
• S/R Plots: S1–S3 (green, varying transparency), R1–R3 (red, varying transparency) as crosses.
• EMA Plots: Six EMAs with dynamic coloring (lime, red, gray) and a silver fill between EMA7 and EMA12.
• Buy/Sell Signals: Green “BUY” label with dotted green line at EMA12; red “SELL” label with dotted red line at EMA7.
• TP/SL Lines and Labels: Blue entry line/label, red dotted SL line/label, green dashed TP1–TP4 lines/labels.
• MTF Dashboard: Top-right table with:
• Title (“DTC Multi TF”) and footer (“DTC v1.3”) in blue/gray.
• Current timeframe trend and ATR status (High Vol, Low Vol, or ATR Off).
• Trends for five timeframes with color-coded backgrounds.
Use Cases
• Trend Following: Use EMA signals and MTF dashboard to confirm trend direction across timeframes.
• Swing Trading: Leverage CPR and S/R levels for identifying reversal or breakout zones.
• Risk Management: Use TP/SL visualizations for planning trades with risk-reward ratios of 1:1 to 1:4.
• Scalping: Apply on lower timeframes (e.g., 15m) with ATR filter for high-volatility trades.
• Multi-Timeframe Analysis: Ensure trend alignment across timeframes using the dashboard for stronger setups.
How to Use (For Invite-Only Users)
1. Request access from the author to use the DTC v1.3 indicator.
2. Once approved, add the indicator to your TradingView chart.
3. Customize inputs:
• Adjust EMA periods for your trading style (shorter for scalping, longer for swing trading).
• Enable/disable CPR, S/R, TP/SL, or dashboard to suit your needs.
• Configure ATR settings for volatility filtering.
• Set dashboard timeframes to match your analysis (e.g., 5m, 15m for intraday; 4h, 1D for swing).
4. Monitor buy/sell signals, CPR/S-R levels, and the MTF dashboard for trade opportunities.
5. Enable alerts for real-time notifications (set to “Once Per Bar Close”).
6. Combine with other analysis tools (e.g., RSI, volume) for comprehensive decision-making.
7. Backtest thoroughly on your chosen market and timeframe to validate performance.
Limitations
• Lagging Signals: EMAs may lag in fast-moving markets, potentially missing rapid reversals.
• Fixed Lookback for TP/SL: The 6-bar lookback for SL may not adapt well to all market conditions.
• ATR Filter: May suppress valid signals in low-volatility markets if enabled.
• Timeframe Sensitivity: Signal accuracy depends on EMA periods and timeframes, requiring optimization.
• Repainting: CPR/S-R levels may repaint in real-time due to daily data updates (standard for pivot calculations).
• Resource Usage: Enabling all features may increase chart load time on lower-end devices.
• Invite-Only Access: Only users with author approval can access the indicator, limiting its availability.
Important Notes
• No Financial Advice: This indicator is for educational and analytical purposes only. It does not guarantee profits or constitute investment advice.
• Backtesting Required: Users should backtest the indicator on their chosen markets and timeframes to assess its effectiveness.
• Invite-Only Access: Access is restricted to invited users, ensuring controlled distribution. Contact the author for access requests.
• Open-Source: The script is open-source under the Mozilla Public License 2.0, allowing modification with proper attribution (for invited users).
• No External Dependencies: The script is self-contained, with no reliance on external libraries.
• Version Note: The dashboard footer currently says “DTC v1.2” but has been updated to “DTC v1.3” in this description for consistency.
Customization Tips
• EMA Periods: Use shorter periods (e.g., 10–35) for intraday trading or longer periods (e.g., 50–200) for positional trading.
• ATR Filter: Adjust the multiplier (e.g., 1.0–1.5) for stricter filtering or disable for more signals.
• Timeframes: Set dashboard timeframes to align with your strategy (e.g., 5m, 15m for scalping; 1D, 1W for long-term).
• Visuals: Disable CPR/S-R or TP/SL to reduce chart clutter if focusing on signals or the dashboard.
Troubleshooting
• No Signals: Verify ATR filter settings (lower multiplier or disable) or check EMA alignment in current market conditions.
• Dashboard Issues: Ensure “Show Dashboard” is enabled and the chart timeframe is supported.
• Repainting: CPR/S-R levels may repaint due to daily data updates, which is expected behavior.
• Alerts Not Triggering: Confirm alerts are enabled and configured correctly in TradingView’s alert settings.
• Access Issues: Contact the author if you encounter difficulties accessing the indicator.
Acknowledgements
Developed independently with no external code dependencies. Any similarities to other indicators are coincidental. Invited users may suggest improvements or modifications under the open-source license.

Penafian

Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.