Artan
Azalan
έώlem
BIST 30
BIST 50
BIST 100
NASDAQ 100
Hisse Fiyat Fark% Hacim (TL) Dόώόk / Yόksek
13,09 10% 10,90 Mn 13,09 / 13,09
87,45 10% 635,00 Mn 78,70 / 87,45
22,02 9.99% 206,50 Mn 20,02 / 22,02
25,32 9.99% 68,43 Mn 22,70 / 25,32
30,16 9.99% 1,84 Mr 28,14 / 30,16
Hisse Fiyat Fark% Hacim (TL) Dόώόk / Yόksek
1.053,00 -10% 16,61 Mn 1.053,00 / 1.053,00
14,60 -9.99% 983,11 Mn 14,60 / 17,35
13,35 -9.98% 38,96 Mn 13,35 / 13,35
12,48 -9.96% 407,45 Mn 12,48 / 12,79
1,75 -9.79% 302,16 Mn 1,75 / 1,96
Hisse Fiyat Fark% Hacim (TL) Dόώόk / Yόksek
308,25 -1.99% 17,26 Mr 305,25 / 311,50
132,00 8.82% 15,02 Mr 114,00 / 132,00
3,14 -1.88% 12,96 Mr 3,08 / 3,22
284,00 7.58% 12,78 Mr 260,00 / 284,00
420,25 -1.23% 11,48 Mr 418,25 / 431,00
Hisse Fiyat Fark% Hacim (TL) Dόώόk / Yόksek
18,98 1.99% 716,50 Mn 18,36 / 19,08
73,20 -0.68% 8,75 Mr 72,85 / 74,05
420,25 -1.23% 11,48 Mr 418,25 / 431,00
284,00 7.58% 12,78 Mr 260,00 / 284,00
741,50 1.99% 4,00 Mr 720,50 / 743,50
Hisse Fiyat Fark% Hacim (TL) Dόώόk / Yόksek
18,98 1.99% 716,50 Mn 18,36 / 19,08
73,20 -0.68% 8,75 Mr 72,85 / 74,05
95,65 -1.54% 576,94 Mn 94,25 / 96,75
111,90 -0.36% 293,60 Mn 110,80 / 112,70
420,25 -1.23% 11,48 Mr 418,25 / 431,00
Hisse Fiyat Fark% Hacim (TL) Dόώόk / Yόksek
18,98 1.99% 716,50 Mn 18,36 / 19,08
31,38 1.49% 126,31 Mn 30,10 / 31,66
73,20 -0.68% 8,75 Mr 72,85 / 74,05
10,59 3.62% 645,46 Mn 10,12 / 10,70
82,20 -1.14% 450,82 Mn 81,60 / 83,75

Masrafsύz Bankacύlύk + 1.000 TL Nakit! Enpara’dan Ηifte Avantaj

Masrafsύz Bankacύlύk + 1.000 TL Nakit! Enpara’dan Ηifte Avantaj
Sayfa 406/407 έlkέlk ... 306356396404405406407 SonSon
Arama sonucu : 3251 madde; 3,241 - 3,248 arasύ.

Konu: Tradingview

  1. φrnek..
    PHP Code:
    // © Kinetik Komuta Merkezi [Masterpiece V3 - Ηift TWAP & Vur-Kaη]
    //@version=6
    indicator("KKM Masterpiece V3"shorttitle="KKM Vur-Kaη"overlay=truemax_labels_count=100)

    // ─────────────────────────────────────────────────────────────────
    // 1. GέRDέLER
    // ─────────────────────────────────────────────────────────────────
    group_l1 "1. L1 Kinetik Filtre (@yφrόk@)"
    int atrLen input.int(20"L1 Hafύza (ATR)"group=group_l1)
    float atrMult input.float(3.5"L1 Gόrόltό Duvarύ"step=0.1group=group_l1)
    float mu input.float(0.6"L1 Yakύnsaklύk (μ)"step=0.1group=group_l1)

    group_core "2. Sύfύr Gecikmeli Ηekirdek (ZLEMA)"
    int i_coreLen input.int(55"Ηekirdek Uzunluπu"group=group_core)

    group_trade "3. Vur-Kaη Hedefi"
    float i_tpPct input.float(1.0"Kiώisel Hedef (%)"step=0.1group=group_trade)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATEMATέKSEL MOTOR (MTF Uyumlu, HL2 Kόtle Merkezi)
    // ─────────────────────────────────────────────────────────────────
    f_calc() =>
        
    // A. ZLEMA (Kinetik TP / Momentum Ηekirdeπi)
        
    float ema1 ta.ema(hl2i_coreLen)
        
    float ema2 ta.ema(ema1i_coreLen)
        
    float val_core ema1 + (ema1 ema2)

        
    // B. L1 @yφrόk@ (Kinetik Stop / Dinamik Zύrh)
        
    float threshold ta.atr(atrLen) * atrMult
        
    var float z na
        
    var float v 0.0
        
    if bar_index == 0
            z 
    := hl2
        
    else
            
    float zPrev z[1], float vPrev v[1]
            
    float zPred zPrev vPrev
            float zTemp 
    zPred mu * (hl2 zPred)
            
    float diff zTemp zPrev
            
    if math.abs(diff) > threshold
                v 
    := math.sign(diff) * (math.abs(diff) - threshold)
            else
                
    := 0.0
            z 
    := zPrev v

        
    // C. Saatlik Saf TWAP (Mikro Trambolin)
        
    bool isNewHour ta.change(time("60")) != 0
        
    var float sumPriceH 0.0
        
    var float barCountH 0.0
        
    if isNewHour or bar_index == 0
            sumPriceH 
    := hl2
            barCountH 
    := 1.0
        
    else
            
    sumPriceH += hl2
            barCountH 
    += 1.0
        float val_twap_h 
    sumPriceH barCountH

        
    // D. Gόnlόk Saf TWAP (Makro Kόtle)
        
    bool isNewDay ta.change(time("D")) != 0
        
    var float sumPriceD 0.0
        
    var float barCountD 0.0
        
    if isNewDay or bar_index == 0
            sumPriceD 
    := hl2
            barCountD 
    := 1.0
        
    else
            
    sumPriceD += hl2
            barCountD 
    += 1.0
        float val_twap_d 
    sumPriceD barCountD

        
    // 5 Deπeri Dφndόr
        
    [val_corezval_twap_hval_twap_dhl2]

    // ─────────────────────────────────────────────────────────────────
    // 3. MEVCUT GRAFέK έΗέN HESAPLAMA VE ΗέZέM
    // ─────────────────────────────────────────────────────────────────
    [curCorecurYorukcurTwapHcurTwapDcurPrice] = f_calc()

    plot(curTwapD"Gόnlόk TWAP"color=color.rgb(2551520), linewidth=3style=plot.style_linebr// Turuncu, Makro
    plot(curTwapH"Saatlik TWAP"color=color.rgb(2552040), linewidth=1style=plot.style_linebr// Sarύ, Mikro
    plot(curYoruk"@yφrόk@"color=color.fuchsialinewidth=2style=plot.style_stepline)
    plot(curCore"Ηekirdek"color=color.aqualinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 4. KέNETέK έήLEM MOTORU (VUR-KAΗ)
    // ─────────────────────────────────────────────────────────────────
    // Makro filtre (Gόnlόk TWAP) eklendi! Boπa iηin fiyat gόnlόk TWAP'ύn da όstόnde olmalύ.
    bool trendBull curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool trendBear 
    curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD

    // Bar Renklendirme
    color bCol trendBull #00e676 : trendBear ? #ff1744 : #787b86
    barcolor(bCol)

    var 
    int state 0
    var float entryP na
    var float statTp na // Sabit %1 Hedef

    if trendBull and state != 1
        state 
    := 1
        entryP 
    := close
        statTp 
    := entryP * (+ (i_tpPct 100))
    else if 
    trendBear and state != -1
        state 
    := -1
        entryP 
    := close
        statTp 
    := entryP * (- (i_tpPct 100))

    bool stopOut = (state == and curPrice curYoruk) or (state == -and curPrice curYoruk)
    bool tpOut   = (state == and high >= statTp) or (state == -and low <= statTp)
    if 
    stopOut or tpOut
        state 
    := 0

    // ─────────────────────────────────────────────────────────────────
    // 5. MTF VERέ ΗEKέMέ
    // ─────────────────────────────────────────────────────────────────
    [f1y1th1td1c1] = request.security(syminfo.tickerid"1",  f_calc())
    [
    f3y3th3td3c3] = request.security(syminfo.tickerid"3",  f_calc())
    [
    f5y5th5td5c5] = request.security(syminfo.tickerid"5",  f_calc())
    [
    f15y15th15td15c15] = request.security(syminfo.tickerid"15"f_calc())
    [
    f30y30th30td30c30] = request.security(syminfo.tickerid"30"f_calc())
    [
    f60y60th60td60c60] = request.security(syminfo.tickerid"60"f_calc())

    // ─────────────────────────────────────────────────────────────────
    // 6. KέNETέK MTF & VUR-KAΗ PANOSU (5 Sόtun)
    // ─────────────────────────────────────────────────────────────────
    var table mtfDash table.new(position.top_right512bgcolor=color.new(color.black15), border_color=color.new(color.gray80), border_width=1)

    f_draw_row(table tint rowstring tffloat corefloat yorukfloat twapHfloat twapDfloat ref_c) =>
        
    color rowBg row == color.new(color.black40) : color.new(color.gray90)
        
    color c_c  ref_c >= core #00e676 : #ff1744
        
    color c_y  ref_c >= yoruk #00e676 : #ff1744
        
    color c_th ref_c >= twapH #00e676 : #ff1744
        
    color c_td ref_c >= twapD #00e676 : #ff1744
        
        
    table.cell(t0rowtftext_color=color.whitetext_size=size.smallbgcolor=rowBg)
        
    table.cell(t1rowstr.tostring(math.round(core2)), text_color=c_ctext_size=size.smallbgcolor=rowBg)
        
    table.cell(t2rowstr.tostring(math.round(yoruk2)), text_color=c_ytext_size=size.smallbgcolor=rowBg)
        
    table.cell(t3rowstr.tostring(math.round(twapH2)), text_color=c_thtext_size=size.smallbgcolor=rowBg)
        
    table.cell(t4rowstr.tostring(math.round(twapD2)), text_color=c_tdtext_size=size.smallbgcolor=rowBg)

    if 
    barstate.islast
        
    // άst Baώlύklar
        
    table.cell(mtfDash00"MTF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash10"ΗEKέRDEK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash20"YΦRάK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash30"S-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash40"G-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
        
    // Matris Verileri
        
    f_draw_row(mtfDash1"1m"f1y1th1td1c1)
        
    f_draw_row(mtfDash2"3m"f3y3th3td3c3)
        
    f_draw_row(mtfDash3"5m"f5y5th5td5c5)
        
    f_draw_row(mtfDash4"15m"f15y15th15td15c15)
        
    f_draw_row(mtfDash5"30m"f30y30th30td30c30)
        
    f_draw_row(mtfDash6"1S"f60y60th60td60c60)
        
        
    // ── VUR-KAΗ RADARI ──
        
    table.cell(mtfDash07"── VUR-KAΗ RADARI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash0747)
        
        
    // Sinyal
        
    string sigText state == "ALIM AKTέF" state == -"SATIή AKTέF" "BEKLENέYOR"
        
    color sigCol   state == #00e676 : state == -1 ? #ff1744 : #787b86
        
    table.cell(mtfDash08"SέNYAL"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash18sigTexttext_color=sigColtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash1848)
        
        
    // Kinetik Stop (Yφrόk Kύrύlύmύ)
        
    table.cell(mtfDash09"KέN. STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash19state != str.tostring(math.round(curYoruk2)) : "-"text_color=#ff1744, text_size=size.small, bgcolor=color.new(color.gray, 90))
        
    table.merge_cells(mtfDash1949)

        
    // Kinetik TP (έvme Kaybύ / Ηekirdek)
        
    table.cell(mtfDash010"KέN. TP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash110state != str.tostring(math.round(curCore2)) : "-"text_color=color.aquatext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash110410)
        
        
    // Sabit %1 Hedef
        
    table.cell(mtfDash011"%" str.tostring(i_tpPct) + " HEDEF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash111state != str.tostring(math.round(statTp2)) : "-"text_color=#00e676, text_size=size.small, bgcolor=color.new(color.gray, 90))
        
    table.merge_cells(mtfDash111411
    16.07.2024 - 10.12.2024

  2. φrnek..
    PHP Code:
    // ─────────────────────────────────────────────────────────────────
    // 4. KέNETέK ATEήLEME VE ZLEMA KABUL (ACCEPTANCE) RAF DEVRέ
    // ─────────────────────────────────────────────────────────────────
    // Ateώleme iηin barύn kinetik enerjisini (boyunu) φlηmek adύna minik bir ATR kullanmak fiziπin kuralύdύr.
    float safeAtr math.max(ta.atr(14), syminfo.mintick)
    bool isIgnition = (high low) >= (safeAtr 1.5)

    bool fireBull trendBull and isIgnition and close open
    bool fireBear 
    trendBear and isIgnition and close open

    var int   activeSide   0
    var float activeLevel  na
    var float shelfLevel   na
    var int   startBar     na
    var float accScore     0.0

    // Ηizgi objeleri (Kutu ve etiket yok, saf ηizgiler)
    var line lineEntry na
    var line lineShelf na

    if (fireBull and activeSide != 1)
        
    activeSide  := 1
        activeLevel 
    := close
        shelfLevel  
    := curCore // έptal Rafύ artύk o anki ZLEMA (Ηekirdek) seviyesi!
        
    startBar    := bar_index
        accScore    
    := 0.0
        
        
    // Eski ηizgileri temizle ve yeni zarif kύsa ηizgiler oluώtur
        
    if not na(lineEntry)
            
    line.delete(lineEntry)
            
    line.delete(lineShelf)
            
        
    lineEntry := line.new(bar_indexactiveLevelbar_index 5activeLevelcolor=color.new(#00e676, 0), width=2)
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 5shelfLevelcolor=color.new(#ff1744, 0), width=1, style=line.style_dashed)

    else if (fireBear and activeSide != -1)
        
    activeSide  := -1
        activeLevel 
    := close
        shelfLevel  
    := curCore
        startBar    
    := bar_index
        accScore    
    := 0.0
        
        
    if not na(lineEntry)
            
    line.delete(lineEntry)
            
    line.delete(lineShelf)
            
        
    lineEntry := line.new(bar_indexactiveLevelbar_index 5activeLevelcolor=color.new(#ff1744, 0), width=2)
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 5shelfLevelcolor=color.new(#00e676, 0), width=1, style=line.style_dashed)

    // Kabul (Acceptance) Skoru Hesaplamasύ ve Raf Kontrolό
    if activeSide != 0
        int barsActive 
    bar_index startBar
        
        
    // Ηizgileri kύsa tutmak iηin fiyatla beraber hafifηe saπa uzat (5 bar ilerisi)
        
    line.set_x2(lineEntrybar_index 3)
        
    line.set_x2(lineShelfbar_index 3)
        
        
    // ZLEMA Rafύ Kύrύldύ mύ? (έptal ήartύ)
        
    bool isFailed activeSide == close shelfLevel close shelfLevel
        
        
    // Fiyat giriώin φtesinde kalmaya devam ediyor mu?
        
    bool isBeyond activeSide == close activeLevel close activeLevel
        
        
    if isBeyond
            accScore 
    := math.min(100accScore 20// Her baώarύlύ barda skoru kinetik olarak artύr
            
        
    if isFailed
            activeSide 
    := 0
            accScore   
    := 0.0
            
    // Baώarύsύz olursa ηizgileri soluklaώtύrarak ekranda silik bir iz bύrak
            
    line.set_color(lineEntrycolor.new(color.gray70))
            
    line.set_color(lineShelfcolor.new(color.gray70)) 
    16.07.2024 - 10.12.2024

  3. φrnek..
    PHP Code:
    // © Kinetik Komuta Merkezi [Masterpiece V4 - Kinetik Ateώleme & Matris]
    //@version=6
    indicator("KKM Masterpiece V4"shorttitle="KKM Vur-Kaη"overlay=truemax_labels_count=100)

    // ─────────────────────────────────────────────────────────────────
    // 1. GέRDέLER
    // ─────────────────────────────────────────────────────────────────
    group_l1 "1. L1 Kinetik Filtre (@yφrόk@)"
    int atrLen input.int(20"L1 Hafύza (ATR)"group=group_l1)
    float atrMult input.float(3.5"L1 Gόrόltό Duvarύ"step=0.1group=group_l1)
    float mu input.float(0.6"L1 Yakύnsaklύk (μ)"step=0.1group=group_l1)

    group_core "2. Sύfύr Gecikmeli Ηekirdek (ZLEMA)"
    int i_coreLen input.int(55"Ηekirdek Uzunluπu"group=group_core)

    group_trade "3. Vur-Kaη Hedefi"
    float i_tpPct input.float(1.0"Kiώisel Hedef (%)"step=0.1group=group_trade)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATEMATέKSEL MOTOR (MTF Uyumlu, HL2 Kόtle Merkezi)
    // ─────────────────────────────────────────────────────────────────
    f_calc() =>
        
    // A. ZLEMA (Kinetik TP / Momentum Ηekirdeπi / έptal Rafύ)
        
    float ema1 ta.ema(hl2i_coreLen)
        
    float ema2 ta.ema(ema1i_coreLen)
        
    float val_core ema1 + (ema1 ema2)

        
    // B. L1 @yφrόk@ (Kinetik Stop / Dinamik Zύrh)
        
    float threshold ta.atr(atrLen) * atrMult
        
    var float z na
        
    var float v 0.0
        
    if bar_index == 0
            z 
    := hl2
        
    else
            
    float zPrev z[1], float vPrev v[1]
            
    float zPred zPrev vPrev
            float zTemp 
    zPred mu * (hl2 zPred)
            
    float diff zTemp zPrev
            
    if math.abs(diff) > threshold
                v 
    := math.sign(diff) * (math.abs(diff) - threshold)
            else
                
    := 0.0
            z 
    := zPrev v

        
    // C. Saatlik Saf TWAP (Mikro Trambolin)
        
    bool isNewHour ta.change(time("60")) != 0
        
    var float sumPriceH 0.0
        
    var float barCountH 0.0
        
    if isNewHour or bar_index == 0
            sumPriceH 
    := hl2
            barCountH 
    := 1.0
        
    else
            
    sumPriceH += hl2
            barCountH 
    += 1.0
        float val_twap_h 
    sumPriceH barCountH

        
    // D. Gόnlόk Saf TWAP (Makro Kόtle)
        
    bool isNewDay ta.change(time("D")) != 0
        
    var float sumPriceD 0.0
        
    var float barCountD 0.0
        
    if isNewDay or bar_index == 0
            sumPriceD 
    := hl2
            barCountD 
    := 1.0
        
    else
            
    sumPriceD += hl2
            barCountD 
    += 1.0
        float val_twap_d 
    sumPriceD barCountD

        
    [val_corezval_twap_hval_twap_dhl2]

    // ─────────────────────────────────────────────────────────────────
    // 3. MEVCUT GRAFέK έΗέN HESAPLAMA VE ΗέZέM
    // ─────────────────────────────────────────────────────────────────
    [curCorecurYorukcurTwapHcurTwapDcurPrice] = f_calc()

    plot(curTwapD"Gόnlόk TWAP"color=color.rgb(2551520), linewidth=3style=plot.style_linebr)
    plot(curTwapH"Saatlik TWAP"color=color.rgb(2552040), linewidth=1style=plot.style_linebr)
    plot(curYoruk"@yφrόk@"color=color.fuchsialinewidth=2style=plot.style_stepline)
    plot(curCore"Ηekirdek"color=color.aqualinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 4. KέNETέK ATEήLEME & KABUL DEVRESέ (ZLEMA RAF SέSTEMέ)
    // ─────────────────────────────────────────────────────────────────
    bool trendBull curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool trendBear 
    curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD

    float safeAtr 
    math.max(ta.atr(14), syminfo.mintick)
    bool isIgnition = (high low) >= (safeAtr 1.5)

    bool fireBull trendBull and isIgnition and close open
    bool fireBear 
    trendBear and isIgnition and close open

    var int   activeSide   0
    var float activeLevel  na
    var float shelfLevel   na
    var int   startBar     na
    var float accScore     0.0
    var float statTp       na

    // Zarif Lazer Ηizgiler (Ekranda Gόrόltό Yapmaz)
    var line lineEntry na
    var line lineShelf na

    if (fireBull and activeSide != 1)
        
    activeSide  := 1
        activeLevel 
    := close
        shelfLevel  
    := curCore // έptal rafύ ZLEMA'ya baπlandύ
        
    startBar    := bar_index
        accScore    
    := 0.0
        statTp      
    := close * (+ (i_tpPct 100))
        
        if 
    not na(lineEntry)
            
    line.delete(lineEntry)
            
    line.delete(lineShelf)
            
        
    lineEntry := line.new(bar_indexactiveLevelbar_index 3activeLevelcolor=color.new(#00e676, 0), width=2)
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 3shelfLevelcolor=color.new(#ff1744, 0), width=1, style=line.style_dashed)

    else if (fireBear and activeSide != -1)
        
    activeSide  := -1
        activeLevel 
    := close
        shelfLevel  
    := curCore // έptal rafύ ZLEMA'ya baπlandύ
        
    startBar    := bar_index
        accScore    
    := 0.0
        statTp      
    := close * (- (i_tpPct 100))
        
        if 
    not na(lineEntry)
            
    line.delete(lineEntry)
            
    line.delete(lineShelf)
            
        
    lineEntry := line.new(bar_indexactiveLevelbar_index 3activeLevelcolor=color.new(#ff1744, 0), width=2)
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 3shelfLevelcolor=color.new(#00e676, 0), width=1, style=line.style_dashed)

    // Kabul Gόncellemesi ve Ηύkύώlar
    if activeSide != 0
        line
    .set_x2(lineEntrybar_index 2)
        
    line.set_x2(lineShelfbar_index 2)
        
        
    bool isBeyond activeSide == close activeLevel close activeLevel
        
    if isBeyond
            accScore 
    := math.min(100accScore 20// Fiyat giriώin φtesinde kaldύkηa skor artar
            
        
    bool stopOut   = (activeSide == and curPrice curYoruk) or (activeSide == -and curPrice curYoruk// Yφrόk Kύrύlύmύ
        
    bool shelfFail activeSide == close shelfLevel close shelfLevel // ZLEMA Rafύ Ηφktό
        
    bool tpOut     = (activeSide == and high >= statTp) or (activeSide == -and low <= statTp// %1 Vur-Kaη Hedefi Vuruldu
        
        
    if stopOut or shelfFail or tpOut
            activeSide 
    := 0
            accScore   
    := 0.0
            line
    .set_color(lineEntrycolor.new(color.gray70)) // Ηizgiler silikleώir, gόrόltό yapmaz
            
    line.set_color(lineShelfcolor.new(color.gray70))

    // Bar Renklendirme
    color bCol trendBull #00e676 : trendBear ? #ff1744 : #787b86
    barcolor(bCol)

    // ─────────────────────────────────────────────────────────────────
    // 5. MTF VERέ ΗEKέMέ
    // ─────────────────────────────────────────────────────────────────
    [f1y1th1td1c1] = request.security(syminfo.tickerid"1",  f_calc())
    [
    f3y3th3td3c3] = request.security(syminfo.tickerid"3",  f_calc())
    [
    f5y5th5td5c5] = request.security(syminfo.tickerid"5",  f_calc())
    [
    f15y15th15td15c15] = request.security(syminfo.tickerid"15"f_calc())
    [
    f30y30th30td30c30] = request.security(syminfo.tickerid"30"f_calc())
    [
    f60y60th60td60c60] = request.security(syminfo.tickerid"60"f_calc())

    // ─────────────────────────────────────────────────────────────────
    // 6. KέNETέK MTF & VUR-KAΗ PANOSU (13 Satύr)
    // ─────────────────────────────────────────────────────────────────
    var table mtfDash table.new(position.top_right513bgcolor=color.new(color.black15), border_color=color.new(color.gray80), border_width=1)

    f_draw_row(table tint rowstring tffloat corefloat yorukfloat twapHfloat twapDfloat ref_c) =>
        
    color rowBg row == color.new(color.black40) : color.new(color.gray90)
        
    color c_c  ref_c >= core #00e676 : #ff1744
        
    color c_y  ref_c >= yoruk #00e676 : #ff1744
        
    color c_th ref_c >= twapH #00e676 : #ff1744
        
    color c_td ref_c >= twapD #00e676 : #ff1744
        
        
    table.cell(t0rowtftext_color=color.whitetext_size=size.smallbgcolor=rowBg)
        
    table.cell(t1rowstr.tostring(math.round(core2)), text_color=c_ctext_size=size.smallbgcolor=rowBg)
        
    table.cell(t2rowstr.tostring(math.round(yoruk2)), text_color=c_ytext_size=size.smallbgcolor=rowBg)
        
    table.cell(t3rowstr.tostring(math.round(twapH2)), text_color=c_thtext_size=size.smallbgcolor=rowBg)
        
    table.cell(t4rowstr.tostring(math.round(twapD2)), text_color=c_tdtext_size=size.smallbgcolor=rowBg)

    if 
    barstate.islast
        
    // άst Baώlύklar
        
    table.cell(mtfDash00"MTF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash10"ΗEKέRDEK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash20"YΦRάK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash30"S-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash40"G-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
        
    // Matris Verileri
        
    f_draw_row(mtfDash1"1m"f1y1th1td1c1)
        
    f_draw_row(mtfDash2"3m"f3y3th3td3c3)
        
    f_draw_row(mtfDash3"5m"f5y5th5td5c5)
        
    f_draw_row(mtfDash4"15m"f15y15th15td15c15)
        
    f_draw_row(mtfDash5"30m"f30y30th30td30c30)
        
    f_draw_row(mtfDash6"1S"f60y60th60td60c60)
        
        
    // ── VUR-KAΗ RADARI ──
        
    table.cell(mtfDash07"── VUR-KAΗ RADARI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash0747)
        
        
    // Sinyal
        
    string sigText activeSide == "ALIM AKTέF" activeSide == -"SATIή AKTέF" "BEKLENέYOR"
        
    color sigCol   activeSide == #00e676 : activeSide == -1 ? #ff1744 : #787b86
        
    table.cell(mtfDash08"SέNYAL"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash18sigTexttext_color=sigColtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash1848)
        
        
    // Kabul Skoru (Acc Score)
        
    color scoreCol accScore >= 80 #00e676 : accScore >= 40 ? color.orange : #ff1744
        
    table.cell(mtfDash09"KABUL SKORU"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash19activeSide != str.tostring(accScore) + "/100" "-"text_color=scoreColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash1949)

        
    // Kinetik Stop (Yφrόk Kύrύlύmύ)
        
    table.cell(mtfDash010"KέN. STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash110activeSide != str.tostring(math.round(curYoruk2)) : "-"text_color=#ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash110410)

        
    // Kinetik TP (έptal Rafύ / ZLEMA Ηekirdeπi)
        
    table.cell(mtfDash011"KέN. TP (RAF)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash111activeSide != str.tostring(math.round(shelfLevel2)) : "-"text_color=color.aquatext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash111411)
        
        
    // Sabit %1 Hedef
        
    table.cell(mtfDash012"%" str.tostring(i_tpPct) + " HEDEF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash112activeSide != str.tostring(math.round(statTp2)) : "-"text_color=#00e676, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash112412
    16.07.2024 - 10.12.2024

  4. φrnek..
    PHP Code:
    // © Kinetik Komuta Merkezi [Masterpiece V5 - Nihai Kuantum Radar]
    //@version=6
    indicator("KKM Masterpiece V5"shorttitle="KKM Nihai"overlay=truemax_labels_count=100)

    // ─────────────────────────────────────────────────────────────────
    // 1. GέRDέLER
    // ─────────────────────────────────────────────────────────────────
    group_l1 "1. L1 Kinetik Filtre (@yφrόk@)"
    int atrLen input.int(20"L1 Hafύza (ATR)"group=group_l1)
    float atrMult input.float(3.5"L1 Gόrόltό Duvarύ"step=0.1group=group_l1)
    float mu input.float(0.6"L1 Yakύnsaklύk (μ)"step=0.1group=group_l1)

    group_core "2. Sύfύr Gecikmeli Ηekirdek (ZLEMA)"
    int i_coreLen input.int(55"Ηekirdek Uzunluπu"group=group_core)

    group_trade "3. Vur-Kaη Hedefi"
    float i_tpPct input.float(1.0"Kiώisel Hedef (%)"step=0.1group=group_trade)

    group_stat "4. έstatistiksel Volatilite (Kutup Yύldύzύ)"
    int volLength input.int(500"Volatilite Periyodu"group=group_stat)
    int projBars  input.int(3"έleriye Dφnόk Mum (T)"group=group_stat)
    int barsPerYear input.int(525600"Yύllύk Mum (1dk=525600)"group=group_stat)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATEMATέKSEL MOTOR (MTF Uyumlu, HL2 Kόtle Merkezi)
    // ─────────────────────────────────────────────────────────────────
    f_calc() =>
        
    // A. ZLEMA (Kinetik TP / Momentum Ηekirdeπi)
        
    float ema1 ta.ema(hl2i_coreLen)
        
    float ema2 ta.ema(ema1i_coreLen)
        
    float val_core ema1 + (ema1 ema2)

        
    // B. L1 @yφrόk@ (Kinetik Stop / Dinamik Zύrh)
        
    float threshold ta.atr(atrLen) * atrMult
        
    var float z na
        
    var float v 0.0
        
    if bar_index == 0
            z 
    := hl2
        
    else
            
    float zPrev z[1], float vPrev v[1]
            
    float zPred zPrev vPrev
            float zTemp 
    zPred mu * (hl2 zPred)
            
    float diff zTemp zPrev
            
    if math.abs(diff) > threshold
                v 
    := math.sign(diff) * (math.abs(diff) - threshold)
            else
                
    := 0.0
            z 
    := zPrev v

        
    // C. Saatlik Saf TWAP (Mikro Trambolin)
        
    bool isNewHour ta.change(time("60")) != 0
        
    var float sumPriceH 0.0
        
    var float barCountH 0.0
        
    if isNewHour or bar_index == 0
            sumPriceH 
    := hl2
            barCountH 
    := 1.0
        
    else
            
    sumPriceH += hl2
            barCountH 
    += 1.0
        float val_twap_h 
    sumPriceH barCountH

        
    // D. Gόnlόk Saf TWAP (Makro Kόtle)
        
    bool isNewDay ta.change(time("D")) != 0
        
    var float sumPriceD 0.0
        
    var float barCountD 0.0
        
    if isNewDay or bar_index == 0
            sumPriceD 
    := hl2
            barCountD 
    := 1.0
        
    else
            
    sumPriceD += hl2
            barCountD 
    += 1.0
        float val_twap_d 
    sumPriceD barCountD

        
    [val_corezval_twap_hval_twap_dhl2]

    // ─────────────────────────────────────────────────────────────────
    // 3. MEVCUT GRAFέK έΗέN HESAPLAMA VE ΗέZέM
    // ─────────────────────────────────────────────────────────────────
    [curCorecurYorukcurTwapHcurTwapDcurPrice] = f_calc()

    plot(curTwapD"Gόnlόk TWAP"color=color.rgb(2551520), linewidth=3style=plot.style_linebr)
    plot(curTwapH"Saatlik TWAP"color=color.rgb(2552040), linewidth=1style=plot.style_linebr)
    plot(curYoruk"@yφrόk@"color=color.fuchsialinewidth=2style=plot.style_stepline)
    plot(curCore"Ηekirdek"color=color.aqualinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 4. έSTATέSTέKSEL VOLATέLέTE (KUTUP YILDIZI BEKLENTέSέ)
    // ─────────────────────────────────────────────────────────────────
    float logReturn math.log(close nz(close[1], close))
    float rawVol    ta.stdev(logReturnvolLength)
    float annualVol rawVol math.sqrt(barsPerYear)
    float drift     1.0 annualVol math.sqrt(float(projBars) / float(barsPerYear)) // 1σ έvme
    float expMovePct= (math.exp(drift) - 1) * 100 // Beklenen %'lik hareket

    // ─────────────────────────────────────────────────────────────────
    // 5. KέNETέK ATEήLEME & KABUL DEVRESέ (ZLEMA RAF SέSTEMέ)
    // ─────────────────────────────────────────────────────────────────
    bool trendBull curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool trendBear 
    curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD

    float safeAtr 
    math.max(ta.atr(14), syminfo.mintick)
    bool isIgnition = (high low) >= (safeAtr 1.5)

    bool fireBull trendBull and isIgnition and close open
    bool fireBear 
    trendBear and isIgnition and close open

    var int   activeSide   0
    var float activeLevel  na
    var float shelfLevel   na
    var int   startBar     na
    var float accScore     0.0
    var float statTp       na

    var line lineEntry na
    var line lineShelf na

    if (fireBull and activeSide != 1)
        
    activeSide  := 1
        activeLevel 
    := close
        shelfLevel  
    := curCore
        startBar    
    := bar_index
        accScore    
    := 0.0
        statTp      
    := close * (+ (i_tpPct 100))
        
        if 
    not na(lineEntry)
            
    line.delete(lineEntry)
            
    line.delete(lineShelf)
            
        
    lineEntry := line.new(bar_indexactiveLevelbar_index 3activeLevelcolor=color.new(#00e676, 0), width=2)
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 3shelfLevelcolor=color.new(#ff1744, 0), width=1, style=line.style_dashed)

    else if (fireBear and activeSide != -1)
        
    activeSide  := -1
        activeLevel 
    := close
        shelfLevel  
    := curCore
        startBar    
    := bar_index
        accScore    
    := 0.0
        statTp      
    := close * (- (i_tpPct 100))
        
        if 
    not na(lineEntry)
            
    line.delete(lineEntry)
            
    line.delete(lineShelf)
            
        
    lineEntry := line.new(bar_indexactiveLevelbar_index 3activeLevelcolor=color.new(#ff1744, 0), width=2)
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 3shelfLevelcolor=color.new(#00e676, 0), width=1, style=line.style_dashed)

    if activeSide != 0
        line
    .set_x2(lineEntrybar_index 2)
        
    line.set_x2(lineShelfbar_index 2)
        
        
    bool isBeyond activeSide == close activeLevel close activeLevel
        
    if isBeyond
            accScore 
    := math.min(100accScore 20
            
        
    bool stopOut   = (activeSide == and curPrice curYoruk) or (activeSide == -and curPrice curYoruk)
        
    bool shelfFail activeSide == close shelfLevel close shelfLevel
        bool tpOut     
    = (activeSide == and high >= statTp) or (activeSide == -and low <= statTp)
        
        if 
    stopOut or shelfFail or tpOut
            activeSide 
    := 0
            accScore   
    := 0.0
            line
    .set_color(lineEntrycolor.new(color.gray70)) 
            
    line.set_color(lineShelfcolor.new(color.gray70))

    color bCol trendBull #00e676 : trendBear ? #ff1744 : #787b86
    barcolor(bCol)

    // ─────────────────────────────────────────────────────────────────
    // 6. MTF VERέ ΗEKέMέ
    // ─────────────────────────────────────────────────────────────────
    [f1y1th1td1c1] = request.security(syminfo.tickerid"1",  f_calc())
    [
    f3y3th3td3c3] = request.security(syminfo.tickerid"3",  f_calc())
    [
    f5y5th5td5c5] = request.security(syminfo.tickerid"5",  f_calc())
    [
    f15y15th15td15c15] = request.security(syminfo.tickerid"15"f_calc())
    [
    f30y30th30td30c30] = request.security(syminfo.tickerid"30"f_calc())
    [
    f60y60th60td60c60] = request.security(syminfo.tickerid"60"f_calc())

    // ─────────────────────────────────────────────────────────────────
    // 7. NέHAέ MTF RADARI & VUR-KAΗ PANOSU (15 SATIR)
    // ─────────────────────────────────────────────────────────────────
    var table mtfDash table.new(position.top_right515bgcolor=color.new(color.black15), border_color=color.new(color.gray80), border_width=1)

    f_draw_row(table tint rowstring tffloat corefloat yorukfloat twapHfloat twapDfloat ref_c) =>
        
    color rowBg row == color.new(color.black40) : color.new(color.gray90)
        
    color c_c  ref_c >= core #00e676 : #ff1744
        
    color c_y  ref_c >= yoruk #00e676 : #ff1744
        
    color c_th ref_c >= twapH #00e676 : #ff1744
        
    color c_td ref_c >= twapD #00e676 : #ff1744
        
        
    table.cell(t0rowtftext_color=color.whitetext_size=size.smallbgcolor=rowBg)
        
    table.cell(t1rowstr.tostring(math.round(core2)), text_color=c_ctext_size=size.smallbgcolor=rowBg)
        
    table.cell(t2rowstr.tostring(math.round(yoruk2)), text_color=c_ytext_size=size.smallbgcolor=rowBg)
        
    table.cell(t3rowstr.tostring(math.round(twapH2)), text_color=c_thtext_size=size.smallbgcolor=rowBg)
        
    table.cell(t4rowstr.tostring(math.round(twapD2)), text_color=c_tdtext_size=size.smallbgcolor=rowBg)

    if 
    barstate.islast
        
    // άst Baώlύklar
        
    table.cell(mtfDash00"MTF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash10"ΗEKέRDEK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash20"YΦRάK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash30"S-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash40"G-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
        
    // Matris Verileri
        
    f_draw_row(mtfDash1"1m"f1y1th1td1c1)
        
    f_draw_row(mtfDash2"3m"f3y3th3td3c3)
        
    f_draw_row(mtfDash3"5m"f5y5th5td5c5)
        
    f_draw_row(mtfDash4"15m"f15y15th15td15c15)
        
    f_draw_row(mtfDash5"30m"f30y30th30td30c30)
        
    f_draw_row(mtfDash6"1S"f60y60th60td60c60)
        
        
    // ── VUR-KAΗ RADARI ──
        
    table.cell(mtfDash07"── VUR-KAΗ RADARI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash0747)
        
        
    // Sinyal
        
    string sigText activeSide == "ALIM AKTέF" activeSide == -"SATIή AKTέF" "BEKLENέYOR"
        
    color sigCol   activeSide == #00e676 : activeSide == -1 ? #ff1744 : #787b86
        
    table.cell(mtfDash08"SέNYAL"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash18sigTexttext_color=sigColtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash1848)
        
        
    // Kabul Skoru
        
    color scoreCol accScore >= 80 #00e676 : accScore >= 40 ? color.orange : #ff1744
        
    table.cell(mtfDash09"KABUL SKORU"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash19activeSide != str.tostring(accScore) + "/100" "-"text_color=scoreColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash1949)

        
    // Kinetik Stop
        
    table.cell(mtfDash010"KέN. STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash110activeSide != str.tostring(math.round(curYoruk2)) : "-"text_color=#ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash110410)

        
    // Kinetik TP (Raf)
        
    table.cell(mtfDash011"KέN. TP (RAF)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash111activeSide != str.tostring(math.round(shelfLevel2)) : "-"text_color=color.aquatext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash111411)
        
        
    // Sabit %1 Hedef
        
    table.cell(mtfDash012"%" str.tostring(i_tpPct) + " HEDEF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash112activeSide != str.tostring(math.round(statTp2)) : "-"text_color=#00e676, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash112412)

        
    // έstatistiksel Kutup Yύldύzύ (% έvme Gόcό)
        
    table.cell(mtfDash013"1σ έVME GάCά"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash113"%" str.tostring(expMovePct"#.##"), text_color=color.yellowtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash113413)

        
    // YTD Mόhrό
        
    table.cell(mtfDash014"Yatύrύm tavsiyesi DEΠέLDέR."text_color=color.graytext_size=size.tinybgcolor=color.new(color.black40), text_halign=text.align_center)
        
    table.merge_cells(mtfDash014414
    16.07.2024 - 10.12.2024

  5. φrnek..
    PHP Code:
    // © Kinetik Komuta Merkezi [Masterpiece V5.1 - Kuantum Edition & Kara Kutu]
    //@version=6
    indicator("KKM Masterpiece V5.1"shorttitle="KKM Nihai Zeka"overlay=truemax_labels_count=100)

    // ─────────────────────────────────────────────────────────────────
    // 1. GέRDέLER
    // ─────────────────────────────────────────────────────────────────
    group_l1 "1. L1 Kinetik Filtre (@yφrόk@)"
    int atrLen input.int(20"L1 Hafύza (ATR)"group=group_l1)
    float atrMult input.float(3.5"L1 Gόrόltό Duvarύ"step=0.1group=group_l1)
    float mu input.float(0.6"L1 Yakύnsaklύk (μ)"step=0.1group=group_l1)

    group_core "2. Sύfύr Gecikmeli Ηekirdek (ZLEMA)"
    int i_coreLen input.int(55"Ηekirdek Uzunluπu"group=group_core)

    group_trade "3. Vur-Kaη Hedefi"
    float i_tpPct input.float(1.0"Kiώisel Hedef (%)"step=0.1group=group_trade)

    group_stat "4. έstatistiksel Volatilite (Kutup Yύldύzύ)"
    int volLength input.int(500"Volatilite Periyodu"group=group_stat)
    int projBars  input.int(3"έleriye Dφnόk Mum (T)"group=group_stat)
    int barsPerYear input.int(525600"Yύllύk Mum (1dk=525600)"group=group_stat)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATEMATέKSEL MOTOR (MTF Uyumlu, HL2 Kόtle Merkezi)
    // ─────────────────────────────────────────────────────────────────
    f_calc() =>
        
    // A. ZLEMA (Kinetik TP / Momentum Ηekirdeπi)
        
    float ema1 ta.ema(hl2i_coreLen)
        
    float ema2 ta.ema(ema1i_coreLen)
        
    float val_core ema1 + (ema1 ema2)

        
    // B. L1 @yφrόk@ (Kinetik Stop / Dinamik Zύrh)
        
    float threshold ta.atr(atrLen) * atrMult
        
    var float z na
        
    var float v 0.0
        
    if bar_index == 0
            z 
    := hl2
        
    else
            
    float zPrev z[1], float vPrev v[1]
            
    float zPred zPrev vPrev
            float zTemp 
    zPred mu * (hl2 zPred)
            
    float diff zTemp zPrev
            
    if math.abs(diff) > threshold
                v 
    := math.sign(diff) * (math.abs(diff) - threshold)
            else
                
    := 0.0
            z 
    := zPrev v

        
    // C. Saatlik Saf TWAP
        
    bool isNewHour ta.change(time("60")) != 0
        
    var float sumPriceH 0.0, var float barCountH 0.0
        
    if isNewHour or bar_index == 0
            sumPriceH 
    := hl2barCountH := 1.0
        
    else
            
    sumPriceH += hl2barCountH += 1.0
        float val_twap_h 
    sumPriceH barCountH

        
    // D. Gόnlόk Saf TWAP
        
    bool isNewDay ta.change(time("D")) != 0
        
    var float sumPriceD 0.0, var float barCountD 0.0
        
    if isNewDay or bar_index == 0
            sumPriceD 
    := hl2barCountD := 1.0
        
    else
            
    sumPriceD += hl2barCountD += 1.0
        float val_twap_d 
    sumPriceD barCountD

        
    [val_corezval_twap_hval_twap_dhl2]

    // ─────────────────────────────────────────────────────────────────
    // 3. MEVCUT GRAFέK έΗέN HESAPLAMA VE ΗέZέM
    // ─────────────────────────────────────────────────────────────────
    [curCorecurYorukcurTwapHcurTwapDcurPrice] = f_calc()

    plot(curTwapD"Gόnlόk TWAP"color=color.rgb(2551520), linewidth=3style=plot.style_linebr)
    plot(curTwapH"Saatlik TWAP"color=color.rgb(2552040), linewidth=1style=plot.style_linebr)
    plot(curYoruk"@yφrόk@"color=color.fuchsialinewidth=2style=plot.style_stepline)
    plot(curCore"Ηekirdek"color=color.aqualinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 4. έSTATέSTέKSEL VOLATέLέTE VE NORMALέZASYON (KέNETέK GάΗ)
    // ─────────────────────────────────────────────────────────────────
    float logReturn math.log(close nz(close[1], close))
    float rawVol    ta.stdev(logReturnvolLength)
    float annualVol rawVol math.sqrt(barsPerYear)
    float drift     1.0 annualVol math.sqrt(float(projBars) / float(barsPerYear)) 
    float expMovePct= (math.exp(drift) - 1) * 100 

    float safeAtr 
    math.max(ta.atr(14), syminfo.mintick)

    // Normalizasyon (0-100 Skoru): Momentum (ZLEMA Uzaklύπύ) + Oynaklύk (Volatilite) Kombinasyonu
    float atrDist math.min(math.abs(close curCore) / safeAtr3.0// Fiyat Ηekirdekten ne kadar koptu? (Max 3 ATR)
    float scoreMomentum = (atrDist 3.0) * 100
    float scoreVol      
    math.min(expMovePct i_tpPct1.5) / 1.5 100 // Volatilite hedefe ne kadar uygun?
    float kinPowerScore math.round((scoreMomentum 0.6) + (scoreVol 0.4)) // Aπrύlύklύ Kinetik Gόη

    // ─────────────────────────────────────────────────────────────────
    // 5. KέNETέK ATEήLEME & OTONOM KARA KUTU HAFIZASI
    // ─────────────────────────────────────────────────────────────────
    bool trendBull curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool trendBear 
    curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool isIgnition 
    = (high low) >= (safeAtr 1.5)

    bool fireBull trendBull and isIgnition and close open
    bool fireBear 
    trendBear and isIgnition and close open

    var int   activeSide   0
    var float shelfLevel   na
    var float statTp       na
    var float accScore     0.0

    // Kara Kutu (Ledger) Hafύza Deπiώkenleri
    var float[] history_pnl = array.new_float()
    var 
    int[]   history_dur = array.new_int()
    var 
    float   entryPrice  na
    var int     entryBar    na

    if (fireBull and activeSide != 1)
        
    activeSide := 1shelfLevel := curCorestatTp := close * (+ (i_tpPct 100)), accScore := 0.0
        entryPrice 
    := closeentryBar := bar_index
    else if (fireBear and activeSide != -1)
        
    activeSide := -1shelfLevel := curCorestatTp := close * (- (i_tpPct 100)), accScore := 0.0
        entryPrice 
    := closeentryBar := bar_index

    if activeSide != 0
        bool isBeyond 
    activeSide == close entryPrice close entryPrice
        
    if isBeyond
            accScore 
    := math.min(100accScore 20
            
        
    bool stopOut   = (activeSide == and curPrice curYoruk) or (activeSide == -and curPrice curYoruk)
        
    bool shelfFail activeSide == close shelfLevel close shelfLevel
        bool tpOut     
    = (activeSide == and high >= statTp) or (activeSide == -and low <= statTp)
        
        
    // έήLEM KAPANINCA KARA KUTUYA KAYDET (Hafύza Mimarisi)
        
    if stopOut or shelfFail or tpOut
            float finalPnl 
    activeSide == ? ((close entryPrice) / entryPrice) * 100 : ((entryPrice close) / entryPrice) * 100
            int finalDur   
    bar_index entryBar
            
    array.push(history_pnlfinalPnl)
            array.
    push(history_durfinalDur)
            
            
    // Sadece son 20 iώlemi hafύzada tutarak RAM'i yormayύz
            
    if array.size(history_pnl) > 20
                
    array.shift(history_pnl)
                array.
    shift(history_dur)
                
            
    activeSide := 0accScore := 0.0

    color bCol 
    trendBull #00e676 : trendBear ? #ff1744 : #787b86
    barcolor(bCol)

    // Kara Kutu έstatistik Hesaplamalarύ
    float totalPnl 0.0
    int   winCount 
    0
    int   totalDur 
    0
    int   tradeCount 
    = array.size(history_pnl)

    if 
    tradeCount 0
        
    for 0 to tradeCount 1
            float p 
    = array.get(history_pnli)
            
    totalPnl += p
            
    if 0
                winCount 
    += 1
            totalDur 
    += array.get(history_duri)

    float winRate tradeCount ? (winCount tradeCount) * 100 0.0
    int   avgDur  
    tradeCount math.round(totalDur tradeCount) : 0

    // ─────────────────────────────────────────────────────────────────
    // 6. MTF VERέ ΗEKέMέ
    // ─────────────────────────────────────────────────────────────────
    [f1y1th1td1c1] = request.security(syminfo.tickerid"1",  f_calc())
    [
    f3y3th3td3c3] = request.security(syminfo.tickerid"3",  f_calc())
    [
    f5y5th5td5c5] = request.security(syminfo.tickerid"5",  f_calc())
    [
    f15y15th15td15c15] = request.security(syminfo.tickerid"15"f_calc())
    [
    f30y30th30td30c30] = request.security(syminfo.tickerid"30"f_calc())
    [
    f60y60th60td60c60] = request.security(syminfo.tickerid"60"f_calc())

    // ─────────────────────────────────────────────────────────────────
    // 7. NέHAέ MTF RADARI & OTONOM KARA KUTU PANOSU (18 SATIR)
    // ─────────────────────────────────────────────────────────────────
    var table mtfDash table.new(position.top_right518bgcolor=color.new(color.black15), border_color=color.new(color.gray80), border_width=1)

    f_draw_row(table tint rowstring tffloat corefloat yorukfloat twapHfloat twapDfloat ref_c) =>
        
    color rowBg row == color.new(color.black40) : color.new(color.gray90)
        
    color c_c  ref_c >= core #00e676 : #ff1744
        
    color c_y  ref_c >= yoruk #00e676 : #ff1744
        
    color c_th ref_c >= twapH #00e676 : #ff1744
        
    color c_td ref_c >= twapD #00e676 : #ff1744
        
        
    table.cell(t0rowtftext_color=color.whitetext_size=size.smallbgcolor=rowBg)
        
    table.cell(t1rowstr.tostring(math.round(core2)), text_color=c_ctext_size=size.smallbgcolor=rowBg)
        
    table.cell(t2rowstr.tostring(math.round(yoruk2)), text_color=c_ytext_size=size.smallbgcolor=rowBg)
        
    table.cell(t3rowstr.tostring(math.round(twapH2)), text_color=c_thtext_size=size.smallbgcolor=rowBg)
        
    table.cell(t4rowstr.tostring(math.round(twapD2)), text_color=c_tdtext_size=size.smallbgcolor=rowBg)

    if 
    barstate.islast
        table
    .cell(mtfDash00"MTF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash10"ΗEKέRDEK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash20"YΦRάK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash30"S-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash40"G-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
        
    f_draw_row(mtfDash1"1m"f1y1th1td1c1)
        
    f_draw_row(mtfDash2"3m"f3y3th3td3c3)
        
    f_draw_row(mtfDash3"5m"f5y5th5td5c5)
        
    f_draw_row(mtfDash4"15m"f15y15th15td15c15)
        
    f_draw_row(mtfDash5"30m"f30y30th30td30c30)
        
    f_draw_row(mtfDash6"1S"f60y60th60td60c60)
        
        
    // ── VUR-KAΗ RADARI ──
        
    table.cell(mtfDash07"── VUR-KAΗ RADARI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash0747)
        
        
    string sigText activeSide == "ALIM AKTέF" activeSide == -"SATIή AKTέF" "BEKLENέYOR"
        
    color sigCol   activeSide == #00e676 : activeSide == -1 ? #ff1744 : #787b86
        
    table.cell(mtfDash08"SέNYAL"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash18sigTexttext_color=sigColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash1848)
        
        
    // NORMALέZASYON (KέNETέK GάΗ) EKLENDέ
        
    string kinText activeSide != "%" str.tostring(kinPowerScore) + (kinPowerScore >= 70 " (GάΗLά)" " (ZAYIF)") : "-"
        
    color  kinCol  kinPowerScore >= 70 color.aqua color.orange
        table
    .cell(mtfDash09"KέN. GάΗ (AI)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash19kinTexttext_color=kinColtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash1949)

        
    color scoreCol accScore >= 80 #00e676 : accScore >= 40 ? color.orange : #ff1744
        
    table.cell(mtfDash010"KABUL SKORU"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash110activeSide != str.tostring(accScore) + "/100" "-"text_color=scoreColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash110410)

        
    table.cell(mtfDash011"KέN. STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash111activeSide != str.tostring(math.round(curYoruk2)) : "-"text_color=#ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash111411)

        
    table.cell(mtfDash012"KέN. TP (RAF)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash112activeSide != str.tostring(math.round(shelfLevel2)) : "-"text_color=color.aquatext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash112412)
        
        
    table.cell(mtfDash013"1σ έVME"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash113"%" str.tostring(expMovePct"#.##"), text_color=color.yellowtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash113413)

        
    // ── OTONOM KARA KUTU ──
        
    table.cell(mtfDash014"── OTONOM KARA KUTU ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash014414)

        
    table.cell(mtfDash015"SON " str.tostring(tradeCount) + " έήLEM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash115"%" str.tostring(math.round(winRate1)) + " BAήARI"text_color=winRate >= 50 #00e676 : #ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash115415)

        
    table.cell(mtfDash016"ORTALAMA SάRE"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash116str.tostring(avgDur) + " MUM"text_color=color.silvertext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash116416)
        
        
    table.cell(mtfDash017"NET DURUM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash117, (totalPnl "+" "") + str.tostring(math.round(totalPnl2)) + "% KΒR/ZARAR"text_color=totalPnl >= #00e676 : #ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash117417
    16.07.2024 - 10.12.2024

  6. φrnek..
    PHP Code:
    // © Kinetik Komuta Merkezi [Masterpiece V5.1 - Kuantum Edition & Kara Kutu]
    //@version=6
    indicator("KKM Masterpiece V5.1"shorttitle="KKM Nihai Zeka"overlay=truemax_labels_count=100)

    // ─────────────────────────────────────────────────────────────────
    // 1. GέRDέLER
    // ─────────────────────────────────────────────────────────────────
    group_l1 "1. L1 Kinetik Filtre (@yφrόk@)"
    int atrLen input.int(20"L1 Hafύza (ATR)"group=group_l1)
    float atrMult input.float(3.5"L1 Gόrόltό Duvarύ"step=0.1group=group_l1)
    float mu input.float(0.6"L1 Yakύnsaklύk (μ)"step=0.1group=group_l1)

    group_core "2. Sύfύr Gecikmeli Ηekirdek (ZLEMA)"
    int i_coreLen input.int(55"Ηekirdek Uzunluπu"group=group_core)

    group_trade "3. Vur-Kaη Hedefi"
    float i_tpPct input.float(1.0"Kiώisel Hedef (%)"step=0.1group=group_trade)

    group_stat "4. έstatistiksel Volatilite (Kutup Yύldύzύ)"
    int volLength input.int(500"Volatilite Periyodu"group=group_stat)
    int projBars  input.int(3"έleriye Dφnόk Mum (T)"group=group_stat)
    int barsPerYear input.int(525600"Yύllύk Mum (1dk=525600)"group=group_stat)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATEMATέKSEL MOTOR (MTF Uyumlu, HL2 Kόtle Merkezi)
    // ─────────────────────────────────────────────────────────────────
    f_calc() =>
        
    // A. ZLEMA (Kinetik TP / Momentum Ηekirdeπi)
        
    float ema1 ta.ema(hl2i_coreLen)
        
    float ema2 ta.ema(ema1i_coreLen)
        
    float val_core ema1 + (ema1 ema2)

        
    // B. L1 @yφrόk@ (Kinetik Stop / Dinamik Zύrh)
        
    float threshold ta.atr(atrLen) * atrMult
        
    var float z na
        
    var float v 0.0
        
    if bar_index == 0
            z 
    := hl2
        
    else
            
    float zPrev z[1], float vPrev v[1]
            
    float zPred zPrev vPrev
            float zTemp 
    zPred mu * (hl2 zPred)
            
    float diff zTemp zPrev
            
    if math.abs(diff) > threshold
                v 
    := math.sign(diff) * (math.abs(diff) - threshold)
            else
                
    := 0.0
            z 
    := zPrev v

        
    // C. Saatlik Saf TWAP
        
    bool isNewHour ta.change(time("60")) != 0
        
    var float sumPriceH 0.0, var float barCountH 0.0
        
    if isNewHour or bar_index == 0
            sumPriceH 
    := hl2barCountH := 1.0
        
    else
            
    sumPriceH += hl2barCountH += 1.0
        float val_twap_h 
    sumPriceH barCountH

        
    // D. Gόnlόk Saf TWAP
        
    bool isNewDay ta.change(time("D")) != 0
        
    var float sumPriceD 0.0, var float barCountD 0.0
        
    if isNewDay or bar_index == 0
            sumPriceD 
    := hl2barCountD := 1.0
        
    else
            
    sumPriceD += hl2barCountD += 1.0
        float val_twap_d 
    sumPriceD barCountD

        
    [val_corezval_twap_hval_twap_dhl2]

    // ─────────────────────────────────────────────────────────────────
    // 3. MEVCUT GRAFέK έΗέN HESAPLAMA VE ΗέZέM
    // ─────────────────────────────────────────────────────────────────
    [curCorecurYorukcurTwapHcurTwapDcurPrice] = f_calc()

    plot(curTwapD"Gόnlόk TWAP"color=color.rgb(2551520), linewidth=3style=plot.style_linebr)
    plot(curTwapH"Saatlik TWAP"color=color.rgb(2552040), linewidth=1style=plot.style_linebr)
    plot(curYoruk"@yφrόk@"color=color.fuchsialinewidth=2style=plot.style_stepline)
    plot(curCore"Ηekirdek"color=color.aqualinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 4. έSTATέSTέKSEL VOLATέLέTE VE NORMALέZASYON (KέNETέK GάΗ)
    // ─────────────────────────────────────────────────────────────────
    float logReturn math.log(close nz(close[1], close))
    float rawVol    ta.stdev(logReturnvolLength)
    float annualVol rawVol math.sqrt(barsPerYear)
    float drift     1.0 annualVol math.sqrt(float(projBars) / float(barsPerYear)) 
    float expMovePct= (math.exp(drift) - 1) * 100 

    float safeAtr 
    math.max(ta.atr(14), syminfo.mintick)

    // Normalizasyon (0-100 Skoru): Momentum + Oynaklύk 
    float atrDist math.min(math.abs(close curCore) / safeAtr3.0)
    float scoreMomentum = (atrDist 3.0) * 100
    float scoreVol      
    math.min(expMovePct i_tpPct1.5) / 1.5 100 
    float kinPowerScore 
    math.round((scoreMomentum 0.6) + (scoreVol 0.4)) 

    // ─────────────────────────────────────────────────────────────────
    // 5. KέNETέK ATEήLEME & OTONOM KARA KUTU HAFIZASI
    // ─────────────────────────────────────────────────────────────────
    bool trendBull curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool trendBear 
    curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool isIgnition 
    = (high low) >= (safeAtr 1.5)

    bool fireBull trendBull and isIgnition and close open
    bool fireBear 
    trendBear and isIgnition and close open

    var int   activeSide   0
    var float shelfLevel   na
    var float statTp       na
    var float accScore     0.0

    // Genel Kara Kutu (Ledger) Deπiώkenleri
    var float[] history_pnl = array.new_float()
    var 
    int[]   history_dur = array.new_int()
    var 
    float   entryPrice  na
    var int     entryBar    na

    // SADECE SON έήLEMέ TAKέP EDEN ΦZEL DEΠέήKENLER (Yeni Eklenen Modόl)
    var string lastSigStatus "BEKLENέYOR"
    var float  lastSigPnl    0.0
    var float  lastSigEntry  na
    var float  lastSigTp     na
    var float  lastSigSl     na
    var int    lastSigBar    na

    if (fireBull and activeSide != 1)
        
    activeSide := 1shelfLevel := curCorestatTp := close * (+ (i_tpPct 100)), accScore := 0.0
        entryPrice 
    := closeentryBar := bar_index
        
    // Son Sinyal Gόncellemesi
        
    lastSigStatus := "AKTέF (BOΠA)"
        
    lastSigEntry := closelastSigBar := bar_indexlastSigTp := statTplastSigSl := curYoruk

    else if (fireBear and activeSide != -1)
        
    activeSide := -1shelfLevel := curCorestatTp := close * (- (i_tpPct 100)), accScore := 0.0
        entryPrice 
    := closeentryBar := bar_index
        
    // Son Sinyal Gόncellemesi
        
    lastSigStatus := "AKTέF (AYI)"
        
    lastSigEntry := closelastSigBar := bar_indexlastSigTp := statTplastSigSl := curYoruk

    if activeSide != 0
        
    // έώlem aktifken PnL ve έz Sόren Stop sόrekli gόncellenir
        
    lastSigPnl := activeSide == ? ((close entryPrice) / entryPrice) * 100 : ((entryPrice close) / entryPrice) * 100
        lastSigSl  
    := curYoruk
        
        bool isBeyond 
    activeSide == close entryPrice close entryPrice
        
    if isBeyond
            accScore 
    := math.min(100accScore 20
            
        
    bool stopOut   = (activeSide == and curPrice curYoruk) or (activeSide == -and curPrice curYoruk)
        
    bool shelfFail activeSide == close shelfLevel close shelfLevel
        bool tpOut     
    = (activeSide == and high >= statTp) or (activeSide == -and low <= statTp)
        
        if 
    stopOut or shelfFail or tpOut
            float finalPnl 
    activeSide == ? ((close entryPrice) / entryPrice) * 100 : ((entryPrice close) / entryPrice) * 100
            int finalDur   
    bar_index entryBar
            
    array.push(history_pnlfinalPnl)
            array.
    push(history_durfinalDur)
            
            if array.
    size(history_pnl) > 20
                
    array.shift(history_pnl)
                array.
    shift(history_dur)
                
            
    // Son Sinyalin Kapanύώ Durumu
            
    lastSigStatus := tpOut "KΒR ALINDI (TP)" stopOut "STOP OLDU" "RAF έPTALέ"
            
    lastSigPnl    := finalPnl
            
            activeSide 
    := 0accScore := 0.0

    color bCol 
    trendBull #00e676 : trendBear ? #ff1744 : #787b86
    barcolor(bCol)

    // Kara Kutu έstatistik Hesaplamalarύ
    float totalPnl 0.0
    int   winCount 
    0
    int   totalDur 
    0
    int   tradeCount 
    = array.size(history_pnl)

    if 
    tradeCount 0
        
    for 0 to tradeCount 1
            float p 
    = array.get(history_pnli)
            
    totalPnl += p
            
    if 0
                winCount 
    += 1
            totalDur 
    += array.get(history_duri)

    float winRate tradeCount ? (winCount tradeCount) * 100 0.0
    int   avgDur  
    tradeCount math.round(totalDur tradeCount) : 0

    // ─────────────────────────────────────────────────────────────────
    // 6. MTF VERέ ΗEKέMέ
    // ─────────────────────────────────────────────────────────────────
    [f1y1th1td1c1] = request.security(syminfo.tickerid"1",  f_calc())
    [
    f3y3th3td3c3] = request.security(syminfo.tickerid"3",  f_calc())
    [
    f5y5th5td5c5] = request.security(syminfo.tickerid"5",  f_calc())
    [
    f15y15th15td15c15] = request.security(syminfo.tickerid"15"f_calc())
    [
    f30y30th30td30c30] = request.security(syminfo.tickerid"30"f_calc())
    [
    f60y60th60td60c60] = request.security(syminfo.tickerid"60"f_calc())

    // ─────────────────────────────────────────────────────────────────
    // 7. NέHAέ MTF RADARI & OTONOM KARA KUTU PANOSU (23 SATIR)
    // ─────────────────────────────────────────────────────────────────
    var table mtfDash table.new(position.top_right523bgcolor=color.new(color.black15), border_color=color.new(color.gray80), border_width=1)

    f_draw_row(table tint rowstring tffloat corefloat yorukfloat twapHfloat twapDfloat ref_c) =>
        
    color rowBg row == color.new(color.black40) : color.new(color.gray90)
        
    color c_c  ref_c >= core #00e676 : #ff1744
        
    color c_y  ref_c >= yoruk #00e676 : #ff1744
        
    color c_th ref_c >= twapH #00e676 : #ff1744
        
    color c_td ref_c >= twapD #00e676 : #ff1744
        
        
    table.cell(t0rowtftext_color=color.whitetext_size=size.smallbgcolor=rowBg)
        
    table.cell(t1rowstr.tostring(math.round(core2)), text_color=c_ctext_size=size.smallbgcolor=rowBg)
        
    table.cell(t2rowstr.tostring(math.round(yoruk2)), text_color=c_ytext_size=size.smallbgcolor=rowBg)
        
    table.cell(t3rowstr.tostring(math.round(twapH2)), text_color=c_thtext_size=size.smallbgcolor=rowBg)
        
    table.cell(t4rowstr.tostring(math.round(twapD2)), text_color=c_tdtext_size=size.smallbgcolor=rowBg)

    if 
    barstate.islast
        table
    .cell(mtfDash00"MTF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash10"ΗEKέRDEK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash20"YΦRάK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash30"S-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash40"G-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
        
    f_draw_row(mtfDash1"1m"f1y1th1td1c1)
        
    f_draw_row(mtfDash2"3m"f3y3th3td3c3)
        
    f_draw_row(mtfDash3"5m"f5y5th5td5c5)
        
    f_draw_row(mtfDash4"15m"f15y15th15td15c15)
        
    f_draw_row(mtfDash5"30m"f30y30th30td30c30)
        
    f_draw_row(mtfDash6"1S"f60y60th60td60c60)
        
        
    // ── VUR-KAΗ RADARI ──
        
    table.cell(mtfDash07"── VUR-KAΗ RADARI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash0747)
        
        
    string sigText activeSide == "ALIM AKTέF" activeSide == -"SATIή AKTέF" "BEKLENέYOR"
        
    color sigCol   activeSide == #00e676 : activeSide == -1 ? #ff1744 : #787b86
        
    table.cell(mtfDash08"SέNYAL"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash18sigTexttext_color=sigColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash1848)
        
        
    string kinText activeSide != "%" str.tostring(kinPowerScore) + (kinPowerScore >= 70 " (GάΗLά)" " (ZAYIF)") : "-"
        
    color  kinCol  kinPowerScore >= 70 color.aqua color.orange
        table
    .cell(mtfDash09"KέN. GάΗ (AI)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash19kinTexttext_color=kinColtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash1949)

        
    color scoreCol accScore >= 80 #00e676 : accScore >= 40 ? color.orange : #ff1744
        
    table.cell(mtfDash010"KABUL SKORU"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash110activeSide != str.tostring(accScore) + "/100" "-"text_color=scoreColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash110410)

        
    table.cell(mtfDash011"KέN. STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash111activeSide != str.tostring(math.round(curYoruk2)) : "-"text_color=#ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash111411)

        
    table.cell(mtfDash012"KέN. TP (RAF)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash112activeSide != str.tostring(math.round(shelfLevel2)) : "-"text_color=color.aquatext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash112412)
        
        
    table.cell(mtfDash013"1σ έVME"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash113"%" str.tostring(expMovePct"#.##"), text_color=color.yellowtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash113413)

        
    // ── OTONOM KARA KUTU ──
        
    table.cell(mtfDash014"── OTONOM KARA KUTU ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash014414)

        
    table.cell(mtfDash015"SON " str.tostring(tradeCount) + " έήLEM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash115"%" str.tostring(math.round(winRate1)) + " BAήARI"text_color=winRate >= 50 #00e676 : #ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash115415)

        
    table.cell(mtfDash016"ORTALAMA SάRE"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash116str.tostring(avgDur) + " MUM"text_color=color.silvertext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash116416)
        
        
    table.cell(mtfDash017"NET DURUM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash117, (totalPnl "+" "") + str.tostring(math.round(totalPnl2)) + "% KΒR/ZARAR"text_color=totalPnl >= #00e676 : #ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash117417)

        
    // ── SON έήLEM DETAYI ──
        
    table.cell(mtfDash018"── SON έήLEM DETAYI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash018418)

        
    table.cell(mtfDash019"DURUM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash119lastSigStatustext_color=(lastSigStatus == "AKTέF (BOΠA)" or lastSigStatus == "AKTέF (AYI)") ? color.aqua color.silvertext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash119419)

        
    string entryStr na(lastSigEntry) ? "-" str.tostring(math.round(lastSigEntry2)) + " (" str.tostring(bar_index lastSigBar) + " Mum Φnce)"
        
    table.cell(mtfDash020"GέRέή / ZAMAN"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash120entryStrtext_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash120420)

        
    string tpSlStr na(lastSigEntry) ? "-" "TP: " str.tostring(math.round(lastSigTp2)) + " | SL: " str.tostring(math.round(lastSigSl2))
        
    table.cell(mtfDash021"HEDEF / STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash121tpSlStrtext_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash121421)

        
    string pnlStr na(lastSigEntry) ? "-" : (lastSigPnl "+" "") + str.tostring(lastSigPnl"#.##") + "%"
        
    color pnlC lastSigPnl #00e676 : lastSigPnl < 0 ? #ff1744 : color.silver
        
    table.cell(mtfDash022"GERΗEKLEήME"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash122pnlStrtext_color=pnlCtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash122422
    16.07.2024 - 10.12.2024

  7. φrnek..
    PHP Code:
    // © Kinetik Komuta Merkezi [Masterpiece V5.1 - Kuantum Edition & Kara Kutu]
    //@version=6
    indicator("KKM Masterpiece V5.1"shorttitle="KKM Nihai Zeka"overlay=truemax_labels_count=100)

    // ─────────────────────────────────────────────────────────────────
    // 1. GέRDέLER
    // ─────────────────────────────────────────────────────────────────
    group_l1 "1. L1 Kinetik Filtre (@yφrόk@)"
    int atrLen input.int(20"L1 Hafύza (ATR)"group=group_l1)
    float atrMult input.float(3.5"L1 Gόrόltό Duvarύ"step=0.1group=group_l1)
    float mu input.float(0.6"L1 Yakύnsaklύk (μ)"step=0.1group=group_l1)

    group_core "2. Sύfύr Gecikmeli Ηekirdek (ZLEMA)"
    int i_coreLen input.int(55"Ηekirdek Uzunluπu"group=group_core)

    group_trade "3. Vur-Kaη Hedefi"
    float i_tpPct input.float(1.0"Kiώisel Hedef (%)"step=0.1group=group_trade)

    group_stat "4. έstatistiksel Volatilite (Kutup Yύldύzύ)"
    int volLength input.int(500"Volatilite Periyodu"group=group_stat)
    int projBars  input.int(3"έleriye Dφnόk Mum (T)"group=group_stat)
    int barsPerYear input.int(525600"Yύllύk Mum (1dk=525600)"group=group_stat)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATEMATέKSEL MOTOR (MTF Uyumlu, HL2 Kόtle Merkezi)
    // ─────────────────────────────────────────────────────────────────
    f_calc() =>
        
    // A. ZLEMA (Kinetik TP / Momentum Ηekirdeπi)
        
    float ema1 ta.ema(hl2i_coreLen)
        
    float ema2 ta.ema(ema1i_coreLen)
        
    float val_core ema1 + (ema1 ema2)

        
    // B. L1 @yφrόk@ (Kinetik Stop / Dinamik Zύrh)
        
    float threshold ta.atr(atrLen) * atrMult
        
    var float z na
        
    var float v 0.0
        
    if bar_index == 0
            z 
    := hl2
        
    else
            
    float zPrev z[1], float vPrev v[1]
            
    float zPred zPrev vPrev
            float zTemp 
    zPred mu * (hl2 zPred)
            
    float diff zTemp zPrev
            
    if math.abs(diff) > threshold
                v 
    := math.sign(diff) * (math.abs(diff) - threshold)
            else
                
    := 0.0
            z 
    := zPrev v

        
    // C. Saatlik Saf TWAP
        
    bool isNewHour ta.change(time("60")) != 0
        
    var float sumPriceH 0.0, var float barCountH 0.0
        
    if isNewHour or bar_index == 0
            sumPriceH 
    := hl2barCountH := 1.0
        
    else
            
    sumPriceH += hl2barCountH += 1.0
        float val_twap_h 
    sumPriceH barCountH

        
    // D. Gόnlόk Saf TWAP
        
    bool isNewDay ta.change(time("D")) != 0
        
    var float sumPriceD 0.0, var float barCountD 0.0
        
    if isNewDay or bar_index == 0
            sumPriceD 
    := hl2barCountD := 1.0
        
    else
            
    sumPriceD += hl2barCountD += 1.0
        float val_twap_d 
    sumPriceD barCountD

        
    [val_corezval_twap_hval_twap_dhl2]

    // ─────────────────────────────────────────────────────────────────
    // 3. MEVCUT GRAFέK έΗέN HESAPLAMA VE ΗέZέM
    // ─────────────────────────────────────────────────────────────────
    [curCorecurYorukcurTwapHcurTwapDcurPrice] = f_calc()

    plot(curTwapD"Gόnlόk TWAP"color=color.rgb(2551520), linewidth=3style=plot.style_linebr)
    plot(curTwapH"Saatlik TWAP"color=color.rgb(2552040), linewidth=1style=plot.style_linebr)
    plot(curYoruk"@yφrόk@"color=color.fuchsialinewidth=2style=plot.style_stepline)
    plot(curCore"Ηekirdek"color=color.aqualinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 4. έSTATέSTέKSEL VOLATέLέTE VE NORMALέZASYON (KέNETέK GάΗ)
    // ─────────────────────────────────────────────────────────────────
    float logReturn math.log(close nz(close[1], close))
    float rawVol    ta.stdev(logReturnvolLength)
    float annualVol rawVol math.sqrt(barsPerYear)
    float drift     1.0 annualVol math.sqrt(float(projBars) / float(barsPerYear)) 
    float expMovePct= (math.exp(drift) - 1) * 100 

    float safeAtr 
    math.max(ta.atr(14), syminfo.mintick)

    // Normalizasyon (0-100 Skoru): Momentum + Oynaklύk + TWAP Katύlύmύ
    float atrDist math.min(math.abs(close curCore) / safeAtr3.0)
    float scoreMomentum = (atrDist 3.0) * 100
    float scoreVol      
    math.min(expMovePct i_tpPct1.5) / 1.5 100 

    // Yeni Modόl: Saatlik TWAP'tan Kopuώ (Katύlύm / Tόkeniώ)
    float twapDistAtr math.abs(close curTwapH) / safeAtr
    bool isExhaustion 
    twapDistAtr 2.5 and scoreVol 80 // TWAP'tan ηok kopmuώ ve Oynaklύk zirvede = Tόkeniώ
    float scoreTwap isExhaustion math.min(twapDistAtr 2.01.0) * 100 // Gerginlik artarsa skor dόώer

    float kinPowerScore math.round((scoreMomentum 0.4) + (scoreVol 0.4) + (scoreTwap 0.2)) 

    // ─────────────────────────────────────────────────────────────────
    // 5. KέNETέK ATEήLEME & OTONOM KARA KUTU HAFIZASI
    // ─────────────────────────────────────────────────────────────────
    bool trendBull curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool trendBear 
    curPrice curCore and curPrice curYoruk and curPrice curTwapH and curPrice curTwapD
    bool isIgnition 
    = (high low) >= (safeAtr 1.5)

    bool fireBull trendBull and isIgnition and close open
    bool fireBear 
    trendBear and isIgnition and close open

    var int   activeSide   0
    var float shelfLevel   na
    var float statTp       na
    var float accScore     0.0

    // Genel Kara Kutu (Ledger) Deπiώkenleri
    var float[] history_pnl = array.new_float()
    var 
    int[]   history_dur = array.new_int()
    var 
    float   entryPrice  na
    var int     entryBar    na

    // SON έήLEMέ TAKέP EDEN ΦZEL DEΠέήKENLER
    var string lastSigStatus "BEKLENέYOR"
    var float  lastSigPnl    0.0
    var float  lastSigEntry  na
    var float  lastSigTp     na
    var float  lastSigSl     na
    var int    lastSigBar    na

    if (fireBull and activeSide != 1)
        
    activeSide := 1shelfLevel := curCorestatTp := close * (+ (i_tpPct 100)), accScore := 0.0
        entryPrice 
    := closeentryBar := bar_index
        lastSigStatus 
    := isExhaustion "AKTέF (BOΠA) ⚠️ TάKENέή" "AKTέF (BOΠA)"
        
    lastSigEntry := closelastSigBar := bar_indexlastSigTp := statTplastSigSl := curYoruk

    else if (fireBear and activeSide != -1)
        
    activeSide := -1shelfLevel := curCorestatTp := close * (- (i_tpPct 100)), accScore := 0.0
        entryPrice 
    := closeentryBar := bar_index
        lastSigStatus 
    := isExhaustion "AKTέF (AYI) ⚠️ TάKENέή" "AKTέF (AYI)"
        
    lastSigEntry := closelastSigBar := bar_indexlastSigTp := statTplastSigSl := curYoruk

    if activeSide != 0
        lastSigPnl 
    := activeSide == ? ((close entryPrice) / entryPrice) * 100 : ((entryPrice close) / entryPrice) * 100
        lastSigSl  
    := curYoruk
        
        bool isBeyond 
    activeSide == close entryPrice close entryPrice
        
    if isBeyond
            accScore 
    := math.min(100accScore 20
            
        
    bool stopOut   = (activeSide == and curPrice curYoruk) or (activeSide == -and curPrice curYoruk)
        
    bool shelfFail activeSide == close shelfLevel close shelfLevel
        bool tpOut     
    = (activeSide == and high >= statTp) or (activeSide == -and low <= statTp)
        
        if 
    stopOut or shelfFail or tpOut
            float finalPnl 
    activeSide == ? ((close entryPrice) / entryPrice) * 100 : ((entryPrice close) / entryPrice) * 100
            int finalDur   
    bar_index entryBar
            
    array.push(history_pnlfinalPnl)
            array.
    push(history_durfinalDur)
            
            if array.
    size(history_pnl) > 20
                
    array.shift(history_pnl)
                array.
    shift(history_dur)
                
            
    lastSigStatus := tpOut "KΒR ALINDI (TP)" stopOut "STOP OLDU" "RAF έPTALέ"
            
    lastSigPnl    := finalPnl
            
            activeSide 
    := 0accScore := 0.0

    color bCol 
    trendBull #00e676 : trendBear ? #ff1744 : #787b86
    barcolor(bCol)

    // Kara Kutu έstatistik Hesaplamalarύ
    float totalPnl 0.0
    int   winCount 
    0
    int   totalDur 
    0
    int   tradeCount 
    = array.size(history_pnl)

    if 
    tradeCount 0
        
    for 0 to tradeCount 1
            float p 
    = array.get(history_pnli)
            
    totalPnl += p
            
    if 0
                winCount 
    += 1
            totalDur 
    += array.get(history_duri)

    float winRate tradeCount ? (winCount tradeCount) * 100 0.0
    int   avgDur  
    tradeCount math.round(totalDur tradeCount) : 0

    // ─────────────────────────────────────────────────────────────────
    // 6. MTF VERέ ΗEKέMέ
    // ─────────────────────────────────────────────────────────────────
    [f1y1th1td1c1] = request.security(syminfo.tickerid"1",  f_calc())
    [
    f3y3th3td3c3] = request.security(syminfo.tickerid"3",  f_calc())
    [
    f5y5th5td5c5] = request.security(syminfo.tickerid"5",  f_calc())
    [
    f15y15th15td15c15] = request.security(syminfo.tickerid"15"f_calc())
    [
    f30y30th30td30c30] = request.security(syminfo.tickerid"30"f_calc())
    [
    f60y60th60td60c60] = request.security(syminfo.tickerid"60"f_calc())

    // ─────────────────────────────────────────────────────────────────
    // 7. NέHAέ MTF RADARI & OTONOM KARA KUTU PANOSU (23 SATIR)
    // ─────────────────────────────────────────────────────────────────
    var table mtfDash table.new(position.top_right523bgcolor=color.new(color.black15), border_color=color.new(color.gray80), border_width=1)

    f_draw_row(table tint rowstring tffloat corefloat yorukfloat twapHfloat twapDfloat ref_c) =>
        
    color rowBg row == color.new(color.black40) : color.new(color.gray90)
        
    color c_c  ref_c >= core #00e676 : #ff1744
        
    color c_y  ref_c >= yoruk #00e676 : #ff1744
        
    color c_th ref_c >= twapH #00e676 : #ff1744
        
    color c_td ref_c >= twapD #00e676 : #ff1744
        
        
    table.cell(t0rowtftext_color=color.whitetext_size=size.smallbgcolor=rowBg)
        
    table.cell(t1rowstr.tostring(math.round(core2)), text_color=c_ctext_size=size.smallbgcolor=rowBg)
        
    table.cell(t2rowstr.tostring(math.round(yoruk2)), text_color=c_ytext_size=size.smallbgcolor=rowBg)
        
    table.cell(t3rowstr.tostring(math.round(twapH2)), text_color=c_thtext_size=size.smallbgcolor=rowBg)
        
    table.cell(t4rowstr.tostring(math.round(twapD2)), text_color=c_tdtext_size=size.smallbgcolor=rowBg)

    if 
    barstate.islast
        table
    .cell(mtfDash00"MTF"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash10"ΗEKέRDEK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash20"YΦRάK"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash30"S-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
    table.cell(mtfDash40"G-TWAP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray80))
        
        
    f_draw_row(mtfDash1"1m"f1y1th1td1c1)
        
    f_draw_row(mtfDash2"3m"f3y3th3td3c3)
        
    f_draw_row(mtfDash3"5m"f5y5th5td5c5)
        
    f_draw_row(mtfDash4"15m"f15y15th15td15c15)
        
    f_draw_row(mtfDash5"30m"f30y30th30td30c30)
        
    f_draw_row(mtfDash6"1S"f60y60th60td60c60)
        
        
    table.cell(mtfDash07"── VUR-KAΗ RADARI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash0747)
        
        
    string sigText activeSide == "ALIM AKTέF" activeSide == -"SATIή AKTέF" "BEKLENέYOR"
        
    color sigCol   activeSide == #00e676 : activeSide == -1 ? #ff1744 : #787b86
        
    table.cell(mtfDash08"SέNYAL"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash18sigTexttext_color=sigColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash1848)
        
        
    string kinText activeSide != "%" str.tostring(kinPowerScore) + (kinPowerScore >= 70 " (GάΗLά)" " (ZAYIF)") : "-"
        
    color  kinCol  kinPowerScore >= 70 color.aqua color.orange
        table
    .cell(mtfDash09"KέN. GάΗ (AI)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash19kinTexttext_color=kinColtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash1949)

        
    color scoreCol accScore >= 80 #00e676 : accScore >= 40 ? color.orange : #ff1744
        
    table.cell(mtfDash010"KABUL SKORU"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash110activeSide != str.tostring(accScore) + "/100" "-"text_color=scoreColtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash110410)

        
    table.cell(mtfDash011"KέN. STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash111activeSide != str.tostring(math.round(curYoruk2)) : "-"text_color=#ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash111411)

        
    table.cell(mtfDash012"KέN. TP (RAF)"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash112activeSide != str.tostring(math.round(shelfLevel2)) : "-"text_color=color.aquatext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash112412)
        
        
    table.cell(mtfDash013"1σ έVME"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash113"%" str.tostring(expMovePct"#.##"), text_color=color.yellowtext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash113413)

        
    table.cell(mtfDash014"── OTONOM KARA KUTU ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash014414)

        
    table.cell(mtfDash015"SON " str.tostring(tradeCount) + " έήLEM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash115"%" str.tostring(math.round(winRate1)) + " BAήARI"text_color=winRate >= 50 #00e676 : #ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash115415)

        
    table.cell(mtfDash016"ORTALAMA SάRE"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash116str.tostring(avgDur) + " MUM"text_color=color.silvertext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash116416)
        
        
    table.cell(mtfDash017"NET DURUM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash117, (totalPnl "+" "") + str.tostring(math.round(totalPnl2)) + "% KΒR/ZARAR"text_color=totalPnl >= #00e676 : #ff1744, text_size=size.small, bgcolor=color.new(color.black, 40))
        
    table.merge_cells(mtfDash117417)

        
    table.cell(mtfDash018"── SON έήLEM DETAYI ──"text_color=color.graytext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash018418)

        
    // TάKENέή UYARISI RENKLENDέRMESέ
        
    bool isDanger str.contains(lastSigStatus"TάKENέή")
        
    table.cell(mtfDash019"DURUM"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash119lastSigStatustext_color=isDanger color.orange : (str.contains(lastSigStatus"AKTέF") ? color.aqua color.silver), text_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash119419)

        
    string entryStr na(lastSigEntry) ? "-" str.tostring(math.round(lastSigEntry2)) + " (" str.tostring(bar_index lastSigBar) + " Mum Φnce)"
        
    table.cell(mtfDash020"GέRέή / ZAMAN"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash120entryStrtext_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash120420)

        
    string tpSlStr na(lastSigEntry) ? "-" "TP: " str.tostring(math.round(lastSigTp2)) + " | SL: " str.tostring(math.round(lastSigSl2))
        
    table.cell(mtfDash021"HEDEF / STOP"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.cell(mtfDash121tpSlStrtext_color=color.whitetext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(mtfDash121421)

        
    string pnlStr na(lastSigEntry) ? "-" : (lastSigPnl "+" "") + str.tostring(lastSigPnl"#.##") + "%"
        
    color pnlC lastSigPnl #00e676 : lastSigPnl < 0 ? #ff1744 : color.silver
        
    table.cell(mtfDash022"GERΗEKLEήME"text_color=color.whitetext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.cell(mtfDash122pnlStrtext_color=pnlCtext_size=size.smallbgcolor=color.new(color.gray90))
        
    table.merge_cells(mtfDash122422
    16.07.2024 - 10.12.2024

  8. φrnek..
    PHP Code:
    // © Kinetik Komuta Merkezi [Masterpiece V6 - Striker Edition]
    //@version=6
    indicator("KKM V6 Striker"shorttitle="KKM V6"overlay=truemax_labels_count=50max_lines_count=50)

    // ─────────────────────────────────────────────────────────────────
    // 1. GέRDέLER (Sadeleώtirilmiώ Striker Paneli)
    // ─────────────────────────────────────────────────────────────────
    group_l1 "1. Kinetik Motor"
    int i_coreLen input.int(55"Ηekirdek (ZLEMA) Uzunluπu"group=group_l1)
    int atrLen input.int(20"L1 Hafύza (ATR)"group=group_l1)
    float atrMult input.float(3.5"L1 Gόrόltό Duvarύ"step=0.1group=group_l1)
    float mu input.float(0.6"L1 Yakύnsaklύk (μ)"step=0.1group=group_l1)

    group_trade "2. Operasyon Hedefi"
    float i_tpPct input.float(1.0"Vur-Kaη Hedefi (%)"step=0.1group=group_trade)

    // ─────────────────────────────────────────────────────────────────
    // 2. TEMEL MATEMATέK & GάNCEL ZAMAN DέLέMέ
    // ─────────────────────────────────────────────────────────────────
    f_calc() =>
        
    // ZLEMA
        
    float ema1 ta.ema(hl2i_coreLen)
        
    float ema2 ta.ema(ema1i_coreLen)
        
    float val_core ema1 + (ema1 ema2)

        
    // L1 @yφrόk@
        
    float threshold ta.atr(atrLen) * atrMult
        
    var float z na
        
    var float v 0.0
        
    if bar_index == 0
            z 
    := hl2
        
    else
            
    float zPrev z[1], float vPrev v[1]
            
    float zPred zPrev vPrev
            float zTemp 
    zPred mu * (hl2 zPred)
            
    float diff zTemp zPrev
            
    if math.abs(diff) > threshold
                v 
    := math.sign(diff) * (math.abs(diff) - threshold)
            else
                
    := 0.0
            z 
    := zPrev v

        
    // Saatlik Saf TWAP
        
    bool isNewHour ta.change(time("60")) != 0
        
    var float sumPriceH 0.0, var float barCountH 0.0
        
    if isNewHour or bar_index == 0
            sumPriceH 
    := hl2barCountH := 1.0
        
    else
            
    sumPriceH += hl2barCountH += 1.0
        float val_twap_h 
    sumPriceH barCountH

        
    [val_corezval_twap_hhl2]

    [
    curCorecurYorukcurTwapHcurPrice] = f_calc()

    // ─────────────────────────────────────────────────────────────────
    // 3. SESSέZ MTF MAKRO ΗEKέRDEK (1, 3, 5, 15, 60 Ortalamasύ)
    // ─────────────────────────────────────────────────────────────────
    f_zlema() =>
        
    e1 ta.ema(hl2i_coreLen)
        
    e2 ta.ema(e1i_coreLen)
        
    e1 + (e1 e2)

    [
    z1]  = request.security(syminfo.tickerid"1",  [f_zlema()])
    [
    z3]  = request.security(syminfo.tickerid"3",  [f_zlema()])
    [
    z5]  = request.security(syminfo.tickerid"5",  [f_zlema()])
    [
    z15] = request.security(syminfo.tickerid"15", [f_zlema()])
    [
    z60] = request.security(syminfo.tickerid"60", [f_zlema()])

    float mtfCore = (nz(z1curCore) + nz(z3curCore) + nz(z5curCore) + nz(z15curCore) + nz(z60curCore)) / 5.0
    bool isMacroBull 
    curPrice mtfCore

    // ─────────────────────────────────────────────────────────────────
    // 4. ΗέZέMLER (Sadeleώtirilmiώ)
    // ─────────────────────────────────────────────────────────────────
    plot(mtfCore"MTF Makro Ηekirdek"color=color.new(color.silver20), linewidth=3)
    plot(curTwapH"S-TWAP"color=color.rgb(2552040), linewidth=1style=plot.style_linebr)
    plot(curYoruk"@yφrόk@"color=color.fuchsialinewidth=2style=plot.style_stepline)
    plot(curCore"Ηekirdek"color=color.aqualinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 5. KέNETέK ATEήLEME & ETέKETLέ RAF SέSTEMέ
    // ─────────────────────────────────────────────────────────────────
    float safeAtr math.max(ta.atr(14), syminfo.mintick)
    bool isIgnition = (high low) >= (safeAtr 1.5)

    bool trendBull curPrice curCore and curPrice curYoruk and curPrice curTwapH 
    bool trendBear 
    curPrice curCore and curPrice curYoruk and curPrice curTwapH 

    bool fireBull 
    trendBull and isIgnition and close open
    bool fireBear 
    trendBear and isIgnition and close open

    var int   activeSide   0
    var float entryPrice   na
    var float shelfLevel   na
    var float statTp       na

    // Gφrsel Obje Deπiώkenleri
    var line  lineEntry na, var label lblEntry na
    var line  lineShelf na, var label lblShelf na
    var line  lineTp    na, var label lblTp    na

    if (fireBull and activeSide != 1)
        
    activeSide := 1entryPrice := closeshelfLevel := curCorestatTp := close * (+ (i_tpPct 100))
        
        if 
    not na(lineEntry)
            
    line.delete(lineEntry), label.delete(lblEntry)
            
    line.delete(lineShelf), label.delete(lblShelf)
            
    line.delete(lineTp),    label.delete(lblTp)
            
        
    lineEntry := line.new(bar_indexentryPricebar_index 6entryPricecolor=color.new(#00e676, 0), width=2)
        
    lblEntry  := label.new(bar_index 6entryPrice"GέRέή: " str.tostring(math.round(entryPrice2)), color=color.new(#00e676, 80), textcolor=color.white, style=label.style_label_left, size=size.small)
        
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 6shelfLevelcolor=color.new(#ff1744, 0), width=1, style=line.style_dashed)
        
    lblShelf  := label.new(bar_index 6shelfLevel"έPTAL (Raf): " str.tostring(math.round(shelfLevel2)), color=color.new(#ff1744, 80), textcolor=color.white, style=label.style_label_left, size=size.small)
        
        
    lineTp    := line.new(bar_indexstatTpbar_index 6statTpcolor=color.new(#00bcd4, 0), width=2, style=line.style_dotted)
        
    lblTp     := label.new(bar_index 6statTp"HEDEF: " str.tostring(math.round(statTp2)), color=color.new(#00bcd4, 80), textcolor=color.white, style=label.style_label_left, size=size.small)

    else if (fireBear and activeSide != -1)
        
    activeSide := -1entryPrice := closeshelfLevel := curCorestatTp := close * (- (i_tpPct 100))
        
        if 
    not na(lineEntry)
            
    line.delete(lineEntry), label.delete(lblEntry)
            
    line.delete(lineShelf), label.delete(lblShelf)
            
    line.delete(lineTp),    label.delete(lblTp)
            
        
    lineEntry := line.new(bar_indexentryPricebar_index 6entryPricecolor=color.new(#ff1744, 0), width=2)
        
    lblEntry  := label.new(bar_index 6entryPrice"GέRέή: " str.tostring(math.round(entryPrice2)), color=color.new(#ff1744, 80), textcolor=color.white, style=label.style_label_left, size=size.small)
        
        
    lineShelf := line.new(bar_indexshelfLevelbar_index 6shelfLevelcolor=color.new(#00e676, 0), width=1, style=line.style_dashed)
        
    lblShelf  := label.new(bar_index 6shelfLevel"έPTAL (Raf): " str.tostring(math.round(shelfLevel2)), color=color.new(#00e676, 80), textcolor=color.white, style=label.style_label_left, size=size.small)
        
        
    lineTp    := line.new(bar_indexstatTpbar_index 6statTpcolor=color.new(#00bcd4, 0), width=2, style=line.style_dotted)
        
    lblTp     := label.new(bar_index 6statTp"HEDEF: " str.tostring(math.round(statTp2)), color=color.new(#00bcd4, 80), textcolor=color.white, style=label.style_label_left, size=size.small)

    // Ηizgilerin ve Etiketlerin Fiyatla Birlikte Kaydύrύlmasύ
    if activeSide != 0
        line
    .set_x2(lineEntrybar_index 6), label.set_x(lblEntrybar_index 6)
        
    line.set_x2(lineShelfbar_index 6), label.set_x(lblShelfbar_index 6)
        
    line.set_x2(lineTpbar_index 6),    label.set_x(lblTpbar_index 6)
        
        
    bool stopOut   = (activeSide == and curPrice curYoruk) or (activeSide == -and curPrice curYoruk)
        
    bool shelfFail activeSide == close shelfLevel close shelfLevel
        bool tpOut     
    = (activeSide == and high >= statTp) or (activeSide == -and low <= statTp)
        
        if 
    stopOut or shelfFail or tpOut
            activeSide 
    := 0
            color grayCol 
    color.new(color.gray60)
            
    line.set_color(lineEntrygrayCol), label.set_color(lblEntrygrayCol)
            
    line.set_color(lineShelfgrayCol), label.set_color(lblShelfgrayCol)
            
    line.set_color(lineTpgrayCol),    label.set_color(lblTpgrayCol)

    color bCol trendBull #00e676 : trendBear ? #ff1744 : #787b86
    barcolor(bCol)

    // ─────────────────────────────────────────────────────────────────
    // 6. MέNέ PUSULA (HUD)
    // ─────────────────────────────────────────────────────────────────
    var table miniHud table.new(position.bottom_right24bgcolor=color.new(color.black40), border_color=color.new(color.gray80), border_width=1)

    if 
    barstate.islast
        table
    .cell(miniHud00"KKM STRIKER"text_color=color.graytext_size=size.smallbgcolor=color.new(color.black40))
        
    table.merge_cells(miniHud0010)
        
        
    string macroText isMacroBull "BOΠA RάZGARI" "AYI BASKISI"
        
    color  macroCol  isMacroBull #00e676 : #ff1744
        
    table.cell(miniHud01"MAKRO (MTF)"text_color=color.whitetext_size=size.small)
        
    table.cell(miniHud11macroTexttext_color=macroColtext_size=size.small)
        
        
    string statText activeSide == "AKTέF (AL)" activeSide == -"AKTέF (SAT)" "TETέKTE"
        
    color  statCol  activeSide == #00e676 : activeSide == -1 ? #ff1744 : color.silver
        
    table.cell(miniHud02"DURUM"text_color=color.whitetext_size=size.small)
        
    table.cell(miniHud12statTexttext_color=statColtext_size=size.small)
        
        
    string outText activeSide != ? (str.tostring(math.round(curYoruk2))) : "-"
        
    table.cell(miniHud03"KέN. STOP"text_color=color.whitetext_size=size.small)
        
    table.cell(miniHud13outTexttext_color=#ff1744, text_size=size.small) 
    16.07.2024 - 10.12.2024

Sayfa 406/407 έlkέlk ... 306356396404405406407 SonSon

Yer έmleri

Yer έmleri

Gφnderi Kurallarύ

  • Yeni konu aηamazsύnύz
  • Konulara cevap yazamazsύnύz
  • Yazύlara ek gφnderemezsiniz
  • Yazύlarύnύzύ deπiώtiremezsiniz
  •