0 beğenilme 0 beğenilmeme
1,137 kez görüntülendi

Selamlar,

Tradingview de bulunan "Leledc Exhaustion Bar" indikatörünü matriks prime ya da iq da kullanılabilir hale getirebilir miyiz?

İndikatörün içinde bulunan "show exhaustion level" özelliğine gerek yok. Sadece oklar olsa yeterli.

Tradingview de ki kod kısmını paylaşıyorum.

 

//@version=4
//©InSilico
//Extension/Mod for - https://www.tradingview.com/script/2rZDPyaC-Leledc-Exhaustion-Bar/ 
study(title='Exhaustion levels (InSilico)',shorttitle="LeveLeledc (InSilico)",overlay=true)

//Input
exhaustionSwitch= input(true,title="Show exhaustion Bar point (Arrows)")
levelSwitch= input(true,title="Show exhaustion levels (Lines)")
length= input(40,"Exhaustions swing length")
bars= input(10,"Exhaustion bar count")
thicknesSwitch = input(2, title="Line Thickness(Level thickness)")

//Fun Lele
Lelec(bars, len) =>
    bindex = int(na)
    bindex := nz(bindex[1], 0)
    sindex = int(na)
    sindex := nz(sindex[1], 0)
    return = 0
    bindex := close > close[4] ? bindex + 1 : bindex
    sindex := close < close[4] ? sindex + 1 : sindex
    if bindex > bars and close < open and high >= highest(high, len)
        bindex := 0
        return := -1
        return
    else
        if sindex > bars and close > open and low <= lowest(low, len)
            sindex := 0
            return := 1
            return

//Out C
Lelex = Lelec(bars, length)

//Out Bar 
highlel = Lelex == -1 ? high : na 
lowlel =  Lelex == 1 ? low : na

//Out level
resistance = float(na)
support = float(na)
resistance := close < open and Lelex  ? high : resistance[1]
support := close > open and Lelex  ? low : support[1]

//Color 
rescol=color.new(#ff0000, 1)
highcol = change(resistance) == 0 ? rescol: na
supcol=color.new(#138484, 1)
lowcol = change(support) == 0 ? supcol : na

//Plot Bar
plotshape(exhaustionSwitch ? lowlel : na,title="Up", color=color.new(#00ff00,1), location=location.belowbar, style=shape.triangleup, size=size.normal)
plotshape(exhaustionSwitch ? highlel: na,title="Down", color=color.new(#ff0000, 1), location=location.abovebar, style=shape.triangledown, size=size.normal)

//Plot level
plot(levelSwitch ? resistance :na, title="Reistance Level", style=plot.style_line, color=highcol, linewidth=thicknesSwitch)
plot(levelSwitch ? support :na, title="Support Level", style=plot.style_line, color=lowcol, linewidth=thicknesSwitch)

alertcondition(lowlel, "Up")
alertcondition(highlel, "Down")

 

İndikatör Pozisyonları ve Değerleri kategorisinde (12 puan) tarafından | 1,137 kez görüntülendi

1 cevap

0 beğenilme 0 beğenilmeme
Merhaba Koray Bey,

 

Buy signal için

bars := 10;       
length := 40;     
UpCount := If(C > Ref(C, -4), PREV + 1, PREV);
DnCount := If(C < Ref(C, -4), PREV + 1, PREV);
BuySignal := (UpCount > bars) AND (C < O) AND (H >= HHV(H, length));
SellSignal := (DnCount > bars) AND (C > O) AND (L <= LLV(L, length));
UpBar := If(BuySignal, L, 0);
DownBar := If(SellSignal, H, 0);
resistance := If(SellSignal, H, Ref(resistance, -1));
support := If(BuySignal, L, Ref(support, -1));
Plot1 := resistance;
Plot2 := support;
BuySignal

 

Sell signal için

bars := 10;       
length := 40;     
UpCount := If(C > Ref(C, -4), PREV + 1, PREV);
DnCount := If(C < Ref(C, -4), PREV + 1, PREV);
BuySignal := (UpCount > bars) AND (C < O) AND (H >= HHV(H, length));
SellSignal := (DnCount > bars) AND (C > O) AND (L <= LLV(L, length));
UpBar := If(BuySignal, L, 0);
DownBar := If(SellSignal, H, 0);
resistance := If(SellSignal, H, Ref(resistance, -1));
support := If(BuySignal, L, Ref(support, -1));
Plot1 := resistance;
Plot2 := support;
SellSignal

 

Şeklinde matriks prime tarafı için deneyebilirsiniz.

Bilgilerinize.
(8,090 puan) tarafından
Hoş geldiniz, Matriks Destek Platformu sizlere sorularınızın hızlıca cevaplanması için bir ortam sağlar. Sorduğunuz ve cevapladığınız soruların ve yorumlarınızın aldığı oylar üzerinden puan kazanırsınız. Puan sistemine bağlı kampanyamızla ücretsiz kullanım avantajlarından faydalanabilirsiniz.



9,957 soru
9,928 cevap
5,342 yorum
65,500 kullanıcı
Codi