Calendar Icon - Evolve Algo
February 11, 2024
Clock Icon - Evolve Algo
6
 min read

STD N-Pole Gaussian Filter

Overview on how to use, trade and calculate the STD N-pole Gaussian Filter

STD N-Pole Gaussian Filter

STD N-Pole Gaussian Filter

Notes:

These indicators and concepts are specifically designed for TradingView.com

Overview

The N-Pole Gaussian Filter is a mathematical tool that helps to smooth out fluctuations in a dataset, such as stock prices. It does this by taking a weighted average of the data points, where the weights are based on a bell-shaped curve called a Gaussian distribution. The "N-Pole" part refers to the number of poles, or times the filter is applied to the data. The more poles you use, the smoother the resulting curve will be. In trading indicators, the N-Pole Gaussian Filter can be used to reduce noise and make it easier to identify trends in the data. In this specific implementation of the N-Pole Gaussian Filter, the filter is combined with a standard deviation filter to further remove noise from the price data. The standard deviation filter sets a threshold based on the standard deviation of the price data, and any data points that fall outside of this threshold are replaced with the previous data point. This helps to smooth out sudden spikes in the price data.

How to Trade

For Evolve Algo we use this filter as a trend and a signal overlay. When the line turns green that equates to a bullish trend as well as it printing a yellow L sybol. Conversly a red line with the purple S equates to a bearish trend. However there are many other ways to use this filter as described below. One common trading strategy using the N-Pole Gaussian Filter is to use it as a trend following indicator. Traders can look for the price to be above the filter line as a bullish signal and below the filter line as a bearish signal. When the price crosses above or below the filter line, it can indicate a potential trend reversal. Another way to use the N-Pole Gaussian Filter is to use it as a trigger for entry or exit signals. Traders can look for the filter line to cross above or below a moving average or other trend indicator as a confirmation of a trend change. For example, if the filter line crosses above a 50-day moving average, it can be seen as a bullish signal, and if it crosses below the moving average, it can be seen as a bearish signal.

STD N-pole Gaussian Filter

How to Calculate

The N-Pole Gaussian filter is calculated by convolving a time series data with a Gaussian filter kernel. The Gaussian filter kernel is a mathematical formula that describes a bell-shaped curve. The kernel is centered at zero and has a standard deviation parameter that determines the width of the curve.

The number of poles in the filter determines the number of times the kernel is convolved with the time series data. Each convolution smooths the data by reducing the impact of high-frequency noise and preserving the lower-frequency trends. The result of the convolutions is a filtered time series that highlights the underlying trends while reducing the noise.

The formula for the N-Pole Gaussian Filter is:

y(t) = (b0 * x(t) + b1 * x(t-1) + b2 * x(t-2) + ... + bn * x(t-n)) / a0

where:

  • y(t) is the output signal at time t
  • x(t) is the input signal at time t
  • n is the number of poles in the filter
  • b0, b1, b2, ..., bn are the filter coefficients for the feedforward path
  • a0, a1, a2, ..., an are the filter coefficients for the feedback path

The calculation involves first determining the filter coefficients for both the feedforward and feedback paths. This can be done using a recursive algorithm called the Gaussian elimination method.

Once the coefficients are determined, the filter can be applied to the input signal x(t) by computing the weighted sum of the past n samples of the input signal, and dividing by the feedback coefficient a0. This produces the output signal y(t) at time t.

Latest articles

Browse all