OPEN-SOURCE SCRIPT
已更新 Gaussian Channel Strategy – GC + Kijun + VAPI Gate

Gaussian Channel Strategy – Description
This strategy combines multiple technical tools into a rules-based trading system designed for crypto and other volatile markets. The main components are:
- **Gaussian Channel (GC):** Acts as the core trend filter. When price is above the Gaussian filter, conditions favor longs; when below, shorts are favored. The channel bands (high/low) also provide visual guidance of volatility and dynamic support/resistance.
- **Kijun-Sen (Ichimoku baseline, period 120):** Serves as a secondary trend filter. Long trades are only considered if price is above the Kijun-Sen, shorts only if price is below.
- **VAPI (Volume Accumulation Percentage Indicator):** Adds a volume confirmation layer. Long setups require positive accumulation, while short setups require negative accumulation. This helps to filter out low-volume and false signals.
- **Risk Management (ATR):** Stop-losses are set at 3× the ATR distance from entry, dynamically adjusting to volatility. Position sizing is calculated as a percentage of account equity at risk per trade.
- **Take Profit & Trailing Exit:** Positions are split into two legs. Leg A (30% of size) takes fixed profit at 0.75× the stop-loss distance (RR 0.75). Leg B (70% of size) uses a trailing stop that follows price with an ATR-based buffer, aiming to capture extended moves.
- **Trade Management:** Long and short entries are triggered only when all three conditions (GC, Kijun, VAPI) align. Exits are handled automatically through fixed TP, SL, and trailing stops.
Overall, the strategy seeks to balance safety and trend-following by combining a smooth Gaussian filter with trend/volume confirmation and adaptive risk management.
This strategy combines multiple technical tools into a rules-based trading system designed for crypto and other volatile markets. The main components are:
- **Gaussian Channel (GC):** Acts as the core trend filter. When price is above the Gaussian filter, conditions favor longs; when below, shorts are favored. The channel bands (high/low) also provide visual guidance of volatility and dynamic support/resistance.
- **Kijun-Sen (Ichimoku baseline, period 120):** Serves as a secondary trend filter. Long trades are only considered if price is above the Kijun-Sen, shorts only if price is below.
- **VAPI (Volume Accumulation Percentage Indicator):** Adds a volume confirmation layer. Long setups require positive accumulation, while short setups require negative accumulation. This helps to filter out low-volume and false signals.
- **Risk Management (ATR):** Stop-losses are set at 3× the ATR distance from entry, dynamically adjusting to volatility. Position sizing is calculated as a percentage of account equity at risk per trade.
- **Take Profit & Trailing Exit:** Positions are split into two legs. Leg A (30% of size) takes fixed profit at 0.75× the stop-loss distance (RR 0.75). Leg B (70% of size) uses a trailing stop that follows price with an ATR-based buffer, aiming to capture extended moves.
- **Trade Management:** Long and short entries are triggered only when all three conditions (GC, Kijun, VAPI) align. Exits are handled automatically through fixed TP, SL, and trailing stops.
Overall, the strategy seeks to balance safety and trend-following by combining a smooth Gaussian filter with trend/volume confirmation and adaptive risk management.
發行說明
Summary of New ChangesThe updated Gaussian Channel Strategy introduces several important enhancements:
1. Default Inputs Aligned to Optimized Settings
• Gaussian Poles = 4, Sampling Period = 144, ATR Length = 11
• SL = 4.5 × ATR, TP RR = 3.5, Risk = 3% of Equity
• Kijun-Sen = 130, VAPI Length = 10, Allocation 75% Fixed TP / 25% Trailing
2. Extra Percentage-Based Take Profit
• A new exit condition closes both long and short trades if price moves a fixed percentage from the entry price.
• Adjustable separately for longs and shorts (e.g., +10% above entry for longs, –10% below entry for shorts).
• This runs in parallel with existing RR-based TP, ATR-based stop-loss, and trailing stop.
3. Clearer Chart Signals
• Entry signals are marked separately for longs and shorts.
• Different shapes and colors are used for exits:
• Green circle = RR Take Profit
• Blue diamond = Extra % Take Profit
• Orange triangle = Trailing Stop
• Red X = Stop Loss
• This makes it easy to identify which condition closed a position when reviewing historical trades.
4. Bug Fixes and Stability
• Corrected Gaussian Channel filter calculation (removed invalid tuple indexing).
• Improved plotting so that channels and fills remain anchored when scrolling or zooming.
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
開源腳本
本著TradingView的真正精神,此腳本的創建者將其開源,以便交易者可以查看和驗證其功能。向作者致敬!雖然您可以免費使用它,但請記住,重新發佈程式碼必須遵守我們的網站規則。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。