wbburgin

Discrete Fourier Transform Overlay [wbburgin]

The discrete Fourier transform (DFT) overlay uses a discrete Fourier transform algorithm to identify trend direction. This is a simpler interpretation that only uses the magnitude of the first frequency component obtained from the DFT algorithm, but can be useful for visualization purposes. I haven't seen many Fourier scripts on TradingView that actually have the magnitude plotted on the chart (some have lines, for instance, but that makes it difficult to look into the past or to see previous lines).

About the Discrete Fourier Transform
The DFT is a mathematical transformation that decomposes a time-domain signal into its constituent frequency components. By applying the DFT to OHLC data, we can interpret the periodicities and trends present in the market. I've designed the overlay so that you can choose your source for the Fourier transform, as well as the length.

Settings and Configuration
The "Fourier Period" is the transform length of the DFT algorithm. This input indicates the number of data points considered for the DFT calculation. For example, if this input is set to 20, the DFT will be performed on the most recent 20 data points of the input series. The transform length affects the resolution and accuracy of the frequency analysis. A shorter transform length may provide a broader frequency range but with less detail, while a longer transform length can provide finer frequency resolution but may be computationally more intensive (I recommend using under 100 - anything above that might take too much time to load on the platform).

The "Fourier X Series" is the source you want the Fourier transform to be applied to. I have it set in default to the close.

"Kernel Smoothing" is the bar-start of the rational quadratic kernel used to smooth the frequency component. Think of it just like a normal moving average if you are unfamiliar with the concept, it functions similarly to the "length" value of a moving average.

PM me to test any of my strategies free for 7 days.

Invite-only indicators: www.patreon.com/wbburgin/membership
Test my strategies on CryptoRobotics: cryptorobotics.co/?trade=f23b09
开源脚本

本着真正的TradingView精神,该脚本的作者将其开源发布,以便交易者可以理解和验证它。为作者喝彩!您可以免费使用它,但在出版物中重复使用此代码受网站规则的约束。 您可以收藏它以在图表上使用。

免责声明

这些信息和出版物并不意味着也不构成TradingView提供或认可的金融、投资、交易或其它类型的建议或背书。请在使用条款阅读更多信息。

想在图表上使用此脚本?