OPEN-SOURCE SCRIPT

Bar Dependent Moving Average

Actualizado
Imagine using an exercising strategy from a gym coach who retired 10 years ago as there dozens of other trainers who constantly try to adapt and find a better approach. You would be missing out.


It's the same with using fixed periods, you just look back.

How about an exercising strategy from a gym coach who is simultaneously trying to adapt himself?

How could you figure out a strategy that adapts with the market as the market is indirectly finding a better approach to take you out?
Relative Moving Averages simply speaking count the total amount of bars and divide it by the period for which you want to use the moving average. Instead of looking at the last X bars, it divides the total amount of bars / X as the moving average period.
It takes all bars into account, the entire chart history essentially turning it into an adaptive moving average, in the example mentioned above into an adaptive exercising strategy.


The Bar Dependent Moving Average Periods are 2,3,5,8 etc., i.e. the entire fibonacci sequence up to 4181.
The white line is the relative fibonacci moving average, which is calculated by adding all Fibonacci Bar Dependent Moving Averages with one another / by the total amount of fibonacci numbers used i.e. 18.
The bar-dependent fibonacci moving average is upon further investigation (on shorter timeframes <30m) a useful support/resistance indicator since the price tends to wick/consolidate or fully break through the fibonoacci bar dependent moving average.



If there are more than 5000 bars of Candlestick data enable the lock in the settings menu to limit the maximum last X bars back to 5000 to make it possible for Tradingview to run the script since Tradingview does not allow it to look more than 5000 bars back.
Notas de prensa
Overlay is true, minor coloring update.
Notas de prensa
Lock of 5000 bypassed by starting counter from highest timeframe and then going lower once 5000 is crossed.
Since this moving average is the same on every timeframe it doesn't matter which timeframe you choose.
Notas de prensa
Fibonacci BDMA's added, relative timeframe function taken out for customization.
Notas de prensa
Few errors fixed. Relative Timeframe Integration isn't fully functional, the Flow-Chart is ready to make it work.
As of now a temporary fix has been offered, which is close to being definitively accurate.
Moving Averages

Script de código abierto

Siguiendo fielmente el espíritu de TradingView, el autor de este script lo ha publicado en código abierto, permitiendo que otros traders puedan entenderlo y verificarlo. ¡Olé por el autor! Puede utilizarlo de forma gratuita, pero tenga en cuenta que la reutilización de este código en la publicación se rige por las Normas internas. Puede añadir este script a sus favoritos y usarlo en un gráfico.

¿Quiere utilizar este script en un gráfico?

Exención de responsabilidad