OPEN-SOURCE SCRIPT
Wavelet Alligator – Separate Entry/Exit Experts & Wavelets-V2

Wavelet Alligator – Strategy Explanation & How to Use
1. Concept Overview
The Wavelet Alligator strategy combines:
- Wavelet transforms (Daubechies, Haar, Symlet, Mexican Hat, Morlet)
- Fractional calculus kernels: Caputo-Fabrizio (CF) and Atangana-Baleanu (AB)
- Three-layer “alligator-like” wavelet smoothing (soft → medium → strong)
- Expert-based entry/exit routing (RAW, CF, AB, or Majority vote)
- Independent wavelets for ENTRY and EXIT
- Main trend defined by AB wavelet ordering
This creates a multi-structure, multi-kernel trend engine capable of capturing extended moves with high signal quality.
2. Wavelet Alligator Structure
Each source (RAW, CF, AB) is transformed into three wavelet layers:
Soft = fastest reaction
Medium = mid smoothing
Strong = trend backbone
Wavelets:
- Daubechies: stable trend
- Haar: fast impulse detection
- Symlet: balanced
- Mexican Hat: curvature and reversal detection
- Morlet: cyclic, oscillatory
3. Entry Logic
Long entry occurs when:
- AB wavelet shows bullish structure (soft > medium > strong, medium rising)
- Selected entry expert approves (RAW / CF / AB / Majority)
- Wavelet condition: soft > strong AND medium crosses above strong
4. Exit Logic
Exit is independent from entry:
- Controlled by chosen exit expert
- Wavelet reversal condition: soft < strong AND medium crosses below strong
- Forced exit when AB trend turns neutral or bearish
5. Background Color (Regime)
- Green: bullish AB regime
- Red: bearish AB regime
- Gray: neutral/transition
6. How to Use
Step 1 – Choose entry wavelet
Daubechies: stable trend
Haar: breakout scalping
Mexican Hat: early reversals
Symlet: balanced
Morlet: cyclic markets
Step 2 – Choose exit wavelet
Mexican Hat: best precision
Daubechies: smooth exits
Haar: aggressive exits
Step 3 – Select entry/exit experts
CF only – fast fractional trend
AB only – stable long-memory trend
RAW only – pure price structure
Majority – safest, noise-filtered
Step 4 – Run the strategy
Entries occur only during AB bullish trend.
Exits occur on wavelet reversal or AB trend failure.
7. Why This Strategy Works
It fuses:
- Fractional calculus (memory)
- Wavelets (shape/curvature)
- Alligator ordering (trend hierarchy)
Result: high-quality entries, strong trend holding, noise-resistant signals.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội Quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội Quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.