OPEN-SOURCE SCRIPT

Adaptive Trend Classification: Moving Averages [InvestorUnknown]

업데이트됨
Adaptive Trend Classification: Moving Averages

Overview

The Adaptive Trend Classification (ATC) Moving Averages indicator is a robust and adaptable investing tool designed to provide dynamic signals based on various types of moving averages and their lengths. This indicator incorporates multiple layers of adaptability to enhance its effectiveness in various market conditions.

Key Features

Adaptability of Moving Average Types and Lengths: The indicator utilizes different types of moving averages (EMA, HMA, WMA, DEMA, LSMA, KAMA) with customizable lengths to adjust to market conditions.
Dynamic Weighting Based on Performance:] Weights are assigned to each moving average based on the equity they generate, with considerations for a cutout period and decay rate to manage (reduce) the influence of past performances.
Exponential Growth Adjustment:The influence of recent performance is enhanced through an adjustable exponential growth factor, ensuring that more recent data has a greater impact on the signal.
Calibration Mode: Allows users to fine-tune the indicator settings for specific signal periods and backtesting, ensuring optimized performance.
Visualization Options: Multiple customization options for plotting moving averages, color bars, and signal arrows, enhancing the clarity of the visual output.
Alerts: Configurable alert settings to notify users based on specific moving average crossovers or the average signal.

스냅샷

User Inputs

Adaptability Settings
λ (Lambda): Specifies the growth rate for exponential growth calculations.
Decay (%): Determines the rate of depreciation applied to the equity over time.
CutOut Period: Sets the period after which equity calculations start, allowing for a focus on specific time ranges.
Robustness Lengths: Defines the range of robustness for equity calculation with options for Narrow, Medium, or Wide adjustments.
Long/Short Threshold: Sets thresholds for long and short signals.
Calculation Source: The data source used for calculations (e.g., close price).

Moving Averages Settings
Lengths and Weights: Allows customization of lengths and initial weights for each moving average type (EMA, HMA, WMA, DEMA, LSMA, KAMA).

Calibration Mode
Calibration Mode: Enables calibration for fine-tuning inputs.
Calibrate: Specifies which moving average type to calibrate.
Strategy View: Shifts entries and exits by one bar for non-repainting backtesting.

스냅샷

스냅샷

Calculation Logic

Rate of Change (R): Calculates the rate of change in the price.
Set of Moving Averages: Generates multiple moving averages with different lengths for each type.



Exponential Growth Factor: Computes an exponential growth factor based on the current bar index and growth rate.



Equity Calculation: Calculates the equity based on starting equity, signals, and the rate of change, incorporating a natural decay rate.
pine code



Signal Generation: Generates signals based on crossovers and computes a weighted signal from multiple moving averages.

Main Calculations

The indicator calculates different moving averages (EMA, HMA, WMA, DEMA, LSMA, KAMA) and their respective signals, applies exponential growth and decay factors to compute equities, and then derives a final signal by averaging weighted signals from all moving averages.

스냅샷

Visualization and Alerts

The final signal, along with additional visual aids like color bars and arrows, is plotted on the chart. Users can also set up alerts based on specific conditions to receive notifications for potential trading opportunities.

Repainting

The indicator does support intra-bar changes of signal but will not repaint once the bar is closed, if you want to get alerts only for signals after bar close, turn on “Strategy View” while setting up the alert.

Conclusion

The Adaptive Trend Classification: Moving Averages Indicator is a sophisticated tool for investors, offering extensive customization and adaptability to changing market conditions. By integrating multiple moving averages and leveraging dynamic weighting based on performance, it aims to provide reliable and timely investing signals.
릴리즈 노트
Correction of the Short threshold input "title"

educationalMoving AveragesTrend Analysis

오픈 소스 스크립트

진정한 TradingView 정신에 따라, 이 스크립트의 저자는 트레이더들이 이해하고 검증할 수 있도록 오픈 소스로 공개했습니다. 저자에게 박수를 보냅니다! 이 코드는 무료로 사용할 수 있지만, 출판물에서 이 코드를 재사용하는 것은 하우스 룰에 의해 관리됩니다. 님은 즐겨찾기로 이 스크립트를 차트에서 쓸 수 있습니다.

차트에 이 스크립트를 사용하시겠습니까?

면책사항