支持中心 帮助文档 联系我们
📱 微信: 18391752892 | 💬 QQ: 3313198376 | ✈️ Telegram | 📧 fishfx123@gmail.com
EURUSD 1.0856 +0.12% GBPUSD 1.2678 +0.08% USDJPY 149.23 -0.15% XAUUSD 2034.56 +0.34% EURUSD 1.0856 +0.12% GBPUSD 1.2678 +0.08% USDJPY 149.23 -0.15% XAUUSD 2034.56 +0.34%

KennedyAdaptiveBaseline

👤 作者: Ryan Paul Kennedy

5.0 分

¥0.00

📌 版本: v2.0
📥 下载: 0
⭐ 评分: 5.0

📝 产品详情

KennedyAdaptiveBaseline

作者Ryan Paul Kennedy
版本v2.0
更新2025-05-23T22:43:52
激活数0

KAB: A Better Baseline.

KAB is an adaptive trend filter designed to track directional movement while actively suppressing abnormal volatility and noise. It behaves like a dynamic moving baseline that automatically adjusts responsiveness to changing market conditions.

Unlike fixed moving averages, KAB continuously modifies its internal smoothing rate based on volatility and directional efficiency. The result is a line that tightens during strong trends and stabilizes during unstable or chaotic price behaviour.

Core Concept

By scaling its gain using the relationship between short- and long-term volatility, KAB adapts to changing market conditions.

Optional Efficiency Ratio gating reduces adaptation during low-directionality periods, while the volatility-lock mechanism provides protection against extreme volatility expansions that can destabilize adaptive filters.

Mechanism

KAB is computed as an exponential moving average with a variable gain rather than a fixed smoothing constant. The adaptive gain is derived from a volatility ratio constructed from True Range smoothing.

Specifically, a short-term EMA of True Range is compared to a longer EMA of that same series:

EMA(TR, short) / EMA(EMA(TR, short), long)

This differs from a conventional ATR(short)/ATR(long) comparison. Instead of comparing two independent volatility estimates, the method compares the current short-term volatility estimate to a smoothed baseline of itself.

In practice this behaves less like a measure of raw volatility level and more like a measure of volatility expansion or contraction relative to its recent state.

Visual States

The indicator uses three colour states:

  • Green – baseline rising
  • Red – baseline falling
  • Lock colour – volatility lock active

These states allow KAB to be used directly as a trend filter or signal engine.

Trading with KAB

    This tool is intended for system integration, not for standalone signal generation. It acts as a baseline filter, ideal for:

    • Trend-following bias confirmation
    • Gating during uncertainty
    • Anchoring mean-reversion logic
    • Volatility-informed position sizing

      That said, though it's not the intended use, KAB can be used as a standalone trading system.

      Using simple long-only, binary entry-exit, 1% exposure backtests, KAB generated the following results on BTC's entire history:

      • 153 trades
      • 26.14% win rate
      • 1.16% average trade return
      • 407.60% compounded return
      • 3.40 profit factor
      • 6.97% max drawdown

      (inclusive of 0.25% fee per trade and 1.5x ATR stops)

      More information on this in KAB documentation on my GitHub.

      Parameters

      There are various parameter groups which can appear confusing to some users. The reason for this is because KAB contains several independent mechanisms. For transparency, I decided to expose them all.

      However, KAB is shipped with default parameters and a recommendation to stay within a modest range of these values. These are not redundant knobs, but exposed internals, set to allow KAB to operate as intended.

      Further, these are not arbitrary. Backtests repeatedly indicated that the most promising configuration (most promising return + drawdown) is the current KAB defaults.

      If you still wish to experiment with KAB's parameters, the full guide is in KAB documentation on my GitHub.

      Preferred Markets

      Backtests indicate more promising performance on markets with clean, directional trend regimes (e.g. BTC or Gold) and large volatility expansion during trends (e.g. ETFs like TQQQ or UPRO). KAB can handle markets with higher volatility and, thus, more instability (e.g. XRP or SPY).

      However, low/flat volatility or heavily mean-reverting assets (e.g. most FX pairs, short bond ETFs) will rarely generate the volatility-ratio expansion KAB needs, thus leading to far worse performance.

        Python+PineScript versions available on Github too:

        Please leave a review.

        License

        MIT License – free for all use cases with attribution.

        安全须知

        本产品仅通过 MQL5.com 官方渠道获取。其他渠道版本可能缺少完整功能和技术支持。

        EA 配置

        交易品种XAUUSD
        时间框架H1 (推荐)
        推荐经纪商IC Markets, IC Trading
        最低存款$300 / 0.01手

        📸 截图预览