OPEN-SOURCE SCRIPT

Lanczos Candles

Aggiornato
This indicator reconstructs price action using Lanczos resampling, incorporating lower timeframe data to create a more detailed representation of market movements. Traditional candle aggregation on higher timeframes tends to lose some price action detail - this indicator attempts to preserve more of that information through mathematical resampling.

The indicator samples price data from a lower timeframe and uses the Lanczos algorithm, a mathematical method commonly used in signal processing and image resampling, to reconstruct the price series at the chart's timeframe. The process helps maintain price movements that might otherwise be smoothed out in regular candle aggregation.

The main settings allow you to select the source timeframe for sampling, adjust the Lanczos filter width to balance smoothness versus detail preservation, and optionally enable Heikin Ashi calculation. The filter width parameter (default: 3) affects how aggressive the smoothing is - higher values produce smoother results while lower values retain more of the original variation.

This approach can be useful for technical analysis when you want to work with higher timeframes while maintaining awareness of significant price movements that occurred within those candles. The optional Heikin Ashi mode can help visualize trends in the resampled data.

The indicator works best when there's a clear ratio between your chart timeframe and the source timeframe (for example, using 1-minute data to build 5-minute candles).
Note di rilascio
Updated to allow you to pick from only processing the current candles data or to blead in the previous candles data to keep a fixed window size (original behavior). Added price tracking and the option to use the real price as your price track.

Description update:

The idea behind this method is to use a form of upscaling to try to take into account all of the ltf data points as a close to maybe reduce aliasing. Also the trackprice should help with adding other indicators to the output source if you want to run them on that signal instead of the real close.
ashiCandlestick analysisdspeducationalheikinheikin-ashiheikinashijapaneseLTFPine utilitiesresampleupscale

Script open-source

In pieno spirito TradingView, l'autore di questo script lo ha pubblicato open-source, in modo che i trader possano comprenderlo e verificarlo. Un saluto all'autore! È possibile utilizzarlo gratuitamente, ma il riutilizzo di questo codice in una pubblicazione è regolato dal nostro Regolamento. Per aggiungerlo al grafico, mettilo tra i preferiti.

Vuoi usare questo script sui tuoi grafici?


Anche su:

Declinazione di responsabilità