PROTECTED SOURCE SCRIPT

Weighted Close Sum

Weighted Close Sum Indicator - Overview

The Weighted Close Sum Indicator is a dynamic and adaptive technical tool designed to analyze price action by incorporating a volatility-adjusted weighted smoothing approach. Unlike traditional moving averages, this indicator adjusts its smoothing length based on market volatility, making it highly responsive to price fluctuations while maintaining accuracy in trend detection.

How It Works

Dynamic Length Adjustment Using ATR:
The indicator calculates the Average True Range (ATR) over a default period of 14 to gauge market volatility.
A dynamic smoothing length is computed based on the user-defined length and a volatility multiplier, allowing the indicator to adapt to changing market conditions.
Formula:
Dynamic Length=Length×(1+ATRClose Price×Multiplier)
Dynamic Length=Length×(1+Close PriceATR​×Multiplier)

Cosine-Weighted Smoothing:
A set of weights is calculated using a cosine function to create a smooth and responsive weighting curve.
These weights are then applied to past closing prices, emphasizing recent data while retaining a natural tapering effect for older data points.

Weighted Close Sum Calculation:
The final value, known as the Cumulative Sum of Moving Averages (CSMA), is computed by multiplying the closing prices with their corresponding weights and summing them up.
This results in a smooth representation of price trends that dynamically adjusts based on market conditions.

How to Use the Indicator

Trend Identification:
Rising values of the Weighted Close Sum indicate an uptrend, while declining values suggest a downtrend.

Volatility Sensitivity:
The adaptive length ensures that the indicator responds faster during high volatility and smooths out during calmer periods, making it suitable for trend-following strategies.

Customizable Parameters:
Length: Controls the base period for calculation. A higher length provides smoother outputs, while a lower value makes the indicator more sensitive.
Volatility Multiplier: Adjusts the sensitivity of the indicator to price fluctuations. A higher multiplier increases responsiveness during volatile periods.

Clause de non-responsabilité