RicardoSantos

[RS]MTF Donchian Range Wave Sync V1

EXPERIMENTAL: using Donchian channels with diferent lengths to extract multiple time frame's to extract price in range rates. the title may be a tiny bit misleading tho -_-''
update: reversed colors, joined the line zone space to make the waves visually stand out more.
Skript med en öppen källkod

I sann TradingView-anda har författaren publicerat detta skript med öppen källkod så att andra handlare kan förstå och verifiera det. Hatten av för författaren! Du kan använda det gratis men återanvändning av den här koden i en publikation regleras av våra ordningsregler. Du kan ange den som favorit för att använda den i ett diagram.

Frånsägelse av ansvar

Informationen och publikationerna är inte avsedda att vara, och utgör inte heller finansiella, investerings-, handels- eller andra typer av råd eller rekommendationer som tillhandahålls eller stöds av TradingView. Läs mer i Användarvillkoren.

Vill du använda det här skriptet i ett diagram?
study("[RS]MTF Donchian Range Wave Sync V1")
wavesynth(_length)=>
    _hh = highest(_length)
    _ll = lowest(_length)
    _range = _hh - _ll
    _value = hl2 - _ll
    _rate = _value/_range

smooth = input(4)
wave0 = ema(ema(wavesynth(8), smooth), smooth)
wave1 = ema(ema(wavesynth(21), smooth), smooth)
wave2 = ema(ema(wavesynth(55), smooth), smooth)
wave3 = ema(ema(wavesynth(144), smooth), smooth)
wave4 = ema(ema(wavesynth(377), smooth), smooth)
wave5 = ema(ema(wavesynth(987), smooth), smooth)

os_value = 0.25
ob_value = 0.75

hline(0, color=black)
plot(0.0+wave0, style=line, color=wave0 < os_value ? maroon : wave0 > ob_value ? green : gray, linewidth=2)
plot(0.5+wave1, style=line, color=wave1 < os_value ? maroon : wave1 > ob_value ? green : gray, linewidth=2)
plot(1.0+wave2, style=line, color=wave2 < os_value ? maroon : wave2 > ob_value ? green : gray, linewidth=3)
plot(1.5+wave3, style=line, color=wave3 < os_value ? maroon : wave3 > ob_value ? green : gray, linewidth=3)
plot(2.0+wave4, style=line, color=wave4 < os_value ? maroon : wave4 > ob_value ? green : gray, linewidth=4)
plot(2.5+wave5, style=line, color=wave5 < os_value ? maroon : wave5 > ob_value ? green : gray, linewidth=4)
hline(3.5, color=black)