Artan
Azalan
Ýþlem
BIST 30
BIST 50
BIST 100
NASDAQ 100
Hisse Fiyat Fark% Hacim (TL) Düþük / Yüksek
1,65 10% 50,29 Mn 1,52 / 1,65
63,65 9.84% 1,06 Mn 63,65 / 63,65
2,95 9.67% 197,07 Mn 2,79 / 2,95
25,70 9.36% 56,88 Mn 25,02 / 25,84
8,58 9.16% 36,49 Mn 8,06 / 8,64
Hisse Fiyat Fark% Hacim (TL) Düþük / Yüksek
10,53 -10% 2,04 Mr 10,53 / 11,55
459,00 -10% 22,33 Mn 459,00 / 510,50
504,50 -9.99% 29,26 Mn 504,50 / 561,00
402,25 -9.96% 501,26 Mn 402,25 / 448,00
260,25 -9.95% 1,48 Mr 260,25 / 283,50
Hisse Fiyat Fark% Hacim (TL) Düþük / Yüksek
220,00 5.82% 6,25 Mr 209,00 / 225,00
319,75 -1.16% 3,74 Mr 319,00 / 323,50
394,00 -0.63% 3,25 Mr 391,00 / 404,50
268,75 2.19% 3,09 Mr 266,00 / 272,50
3,01 1.35% 2,80 Mr 2,98 / 3,04
Hisse Fiyat Fark% Hacim (TL) Düþük / Yüksek
18,72 -2.5% 328,11 Mn 18,67 / 19,26
77,95 -1.64% 1,85 Mr 77,70 / 78,75
394,00 -0.63% 3,25 Mr 391,00 / 404,50
220,00 5.82% 6,25 Mr 209,00 / 225,00
749,50 -1.77% 1,13 Mr 747,00 / 761,50
Hisse Fiyat Fark% Hacim (TL) Düþük / Yüksek
18,72 -2.5% 328,11 Mn 18,67 / 19,26
77,95 -1.64% 1,85 Mr 77,70 / 78,75
92,35 -0.05% 180,22 Mn 92,00 / 93,20
115,30 0.09% 190,84 Mn 112,40 / 116,60
394,00 -0.63% 3,25 Mr 391,00 / 404,50
Hisse Fiyat Fark% Hacim (TL) Düþük / Yüksek
18,72 -2.5% 328,11 Mn 18,67 / 19,26
30,86 -1.41% 30,35 Mn 30,64 / 31,30
77,95 -1.64% 1,85 Mr 77,70 / 78,75
10,45 0.58% 73,74 Mn 10,40 / 10,59
80,10 1.39% 200,68 Mn 79,05 / 81,50

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 402/402 ÝlkÝlk ... 302352392400401402
Arama sonucu : 3215 madde; 3,209 - 3,215 arasý.

Konu: Tradingview

  1.  Alýntý Originally Posted by @yörük@ Yazýyý Oku
    3lü sar örneði... https://www.tradingview.com/x/8PDcCYHr/
    PHP Code:
    //@version=6
    indicator("3'lü SAR "overlay=truemax_bars_back=5000)

    // ─────────────────────────────────────────────────────────────────
    // 1. ORÝJÝNAL SAR DEÐERLERÝ (YARI YARIYA ÖLÇEKLÝ)
    // ─────────────────────────────────────────────────────────────────
    // Sarý SAR (Hýzlý - Tetikleyici / Standart Ayar)
    sarSari    ta.sar(0.020.020.20)

    // Mavi SAR (Orta - Dalga Filtresi)
    sarMavi    ta.sar(0.010.010.10)

    // Kýrmýzý SAR (En Yavaþ - Aðýr Zýrh / Ana Trend Göstergesi)
    sarKirmizi ta.sar(0.0050.0050.05)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATRÝKS EKRANI GÖRSELLEÞTÝRMESÝ
    // ─────────────────────────────────────────────────────────────────
    // Resimdeki gibi kalýn, net noktalar (circles)
    plot(sarKirmizi"Kýrmýzý (Ana Trend)"color=color.red,    style=plot.style_circleslinewidth=2)
    plot(sarMavi,    "Mavi (Orta Dalga)",   color=color.blue,   style=plot.style_circleslinewidth=2)
    plot(sarSari,    "Sarý (Tetik)",        color=color.yellowstyle=plot.style_circleslinewidth=2)

    // ─────────────────────────────────────────────────────────────────
    // 3. ÝÞLEM MANTIÐI: 3 KÝLÝT ONAYI
    // ─────────────────────────────────────────────────────────────────
    // Kusursuz Yükseliþ: Fiyatýn, 3 SAR noktasýnýn da üstünde olmasý
    bogaAhenk close sarKirmizi and close sarMavi and close sarSari

    // Kusursuz Düþüþ: Fiyatýn, 3 SAR noktasýnýn da altýnda olmasý
    ayiAhenk  close sarKirmizi and close sarMavi and close sarSari

    // Sinyal tekrarýný önlemek için sadece olayýn koptuðu ÝLK barda tetikle
    alTetik  bogaAhenk and not bogaAhenk[1]
    satTetik ayiAhenk and not ayiAhenk[1]

    // ─────────────────────────────────────────────────────────────────
    // 4. EKRAN MÜHÜRLERÝ 
    // ─────────────────────────────────────────────────────────────────
    // Giriþ Sinyalleri (Elmaslar)
    plotshape(alTetik,  "AL",  shape.diamondlocation.belowbarcolor=color.greensize=size.smalltext="AL"textcolor=color.green)
    plotshape(satTetik"SAT"shape.diamondlocation.abovebarcolor=color.red,   size=size.smalltext="SAT"textcolor=color.red)

    // Erken Çýkýþ / Kar Al (Sarý SAR ihlali)
    // Üçlü onayla girdin, ama trend zayýfladý ve fiyat ilk olarak "Sarýyý" kesti. O an kârý korumak için uyarýr.
    cikisBoga bogaAhenk[1] and close sarSari
    cikisAyi  
    ayiAhenk[1] and close sarSari

    plotshape
    (cikisBoga"Kar Al (Boða)"shape.xcrosslocation.abovebarcolor=color.graysize=size.tiny)
    plotshape(cikisAyi,  "Kar Al (Ayý)",  shape.xcrosslocation.belowbarcolor=color.graysize=size.tiny
    þimdi bu hesaplama örneðini alýp...mtfsini...grafiðe chart yapma....
    görüntü.... https://www.tradingview.com/x/a8dUjypa/

    PHP Code:
    //@version=5
    indicator("Charts [3'lü SAR]"overlay=truemax_boxes_count=500max_lines_count=500max_labels_count=500)

    // ========================================================================= //
    // =============================== INPUTS ================================== //
    // ========================================================================= //

    // --- POSITIONING ---
    grp_pos "POSITIONING"
    i_width   input.int(50,   "Mini Chart Width (Bars)"group=grp_pos)
    i_offset  input.int(6,    "Horizontal Offset",       group=grp_pos)
    i_gapX    input.int(10,   "Horizontal Gap (Bars)",   group=grp_pos)
    i_vScale  input.float(35.0"Overall Height Scale",    group=grp_posstep=0.1)
    i_vBuffer input.float(0.02,"Vertical Buffer (%)",     group=grp_posstep=0.01)

    // --- TIMEFRAMES & CANDLES ---
    grp_tf "CUSTOM TIMEFRAMES & CANDLES"
    tf1  input.timeframe("5",   "Timeframe 1"inline="tf1"group=grp_tf)
    len1 input.int(20"",      inline="tf1",  group=grp_tf)
    tf2  input.timeframe("15",  "Timeframe 2"inline="tf2"group=grp_tf)
    len2 input.int(20"",      inline="tf2",  group=grp_tf)
    tf3  input.timeframe("60",  "Timeframe 3"inline="tf3"group=grp_tf)
    len3 input.int(20"",      inline="tf3",  group=grp_tf)
    tf4  input.timeframe("240""Timeframe 4"inline="tf4"group=grp_tf)
    len4 input.int(20"",      inline="tf4",  group=grp_tf)
    tf5  input.timeframe("D",   "Timeframe 5"inline="tf5"group=grp_tf)
    len5 input.int(15"",      inline="tf5",  group=grp_tf)
    tf6  input.timeframe("W",   "Timeframe 6"inline="tf6"group=grp_tf)
    len6 input.int(10"",      inline="tf6",  group=grp_tf)

    // --- STYLE ---
    grp_style "STYLE"
    c_up     input.color(color.new(color.white0), "Up Color",         group=grp_style)
    c_down   input.color(color.new(color.gray0),  "Down Color",       group=grp_style)
    c_bg     input.color(color.new(#1a1a1a, 80),    "Background Color", group=grp_style)
    c_border input.color(color.new(#1a1a1a, 50),    "Border Color",     group=grp_style)
    c_text   input.color(color.new(color.gray0),  "Text Color",       group=grp_style)

    // ========================================================================= //
    // ============================ DATA FETCHING ============================== //
    // ========================================================================= //
    // (Senin gönderdiðin orijinal, hatasýz HTF_Data yapýsý)

    type HTF_Data
        
    array<floato
        
    array<floath
        
    array<floatl
        
    array<floatc

    f_get_htf_data
    (tflength) =>
        var 
    float[] o_arr = array.new_float(0)
        var 
    float[] h_arr = array.new_float(0)
        var 
    float[] l_arr = array.new_float(0)
        var 
    float[] c_arr = array.new_float(0)
        [
    ohlc] = request.security(syminfo.tickeridtf, [openhighlowclose])
        if 
    ta.change(time(tf)) != 0
            
    array.push(o_arro[1])
            array.
    push(h_arrh[1])
            array.
    push(l_arrl[1])
            array.
    push(c_arrc[1])
            if array.
    size(o_arr) > length
                
    array.shift(o_arr)
                array.
    shift(h_arr)
                array.
    shift(l_arr)
                array.
    shift(c_arr)
        
    HTF_Data.new(o_arrh_arrl_arrc_arr)

    data1 f_get_htf_data(tf1len1)
    data2 f_get_htf_data(tf2len2)
    data3 f_get_htf_data(tf3len3)
    data4 f_get_htf_data(tf4len4)
    data5 f_get_htf_data(tf5len5)
    data6 f_get_htf_data(tf6len6)

    // ========================================================================= //
    // ========================= SAR CALCULATION =============================== //
    // ========================================================================= //
    // Çekilen HTF array'leri üzerinde lokal SAR hesaplamasý yapan motor.

    f_calc_sar(float[] highsfloat[] lowsfloat startfloat incfloat max_af) =>
        
    int n = array.size(highs)
        
    float[] out = array.new_float(nna)
        if 
    1
            int trend 
    1
            float ep 
    = array.get(highs0)
            
    float sar_val = array.get(lows0)
            
    float af start
            
            
    array.set(out0sar_val)
            
            for 
    1 to n 1
                float prev_sar 
    sar_val
                float next_sar 
    prev_sar af * (ep prev_sar)
                
                
    float h_prev = array.get(highs1)
                
    float l_prev = array.get(lows1)
                
    float h_prev2 ? array.get(highs2) : h_prev
                float l_prev2 
    ? array.get(lows2) : l_prev
                
                
    if trend == 1
                    next_sar 
    := math.min(next_sarl_prevl_prev2)
                    
    float current_low = array.get(lowsi)
                    if 
    current_low next_sar
                        trend 
    := -1
                        next_sar 
    := ep
                        ep 
    := current_low
                        af 
    := start
                    
    else
                        
    float current_high = array.get(highsi)
                        if 
    current_high ep
                            ep 
    := current_high
                            af 
    := math.min(max_afaf inc)
                else
                    
    next_sar := math.max(next_sarh_prevh_prev2)
                    
    float current_high = array.get(highsi)
                    if 
    current_high next_sar
                        trend 
    := 1
                        next_sar 
    := ep
                        ep 
    := current_high
                        af 
    := start
                    
    else
                        
    float current_low = array.get(lowsi)
                        if 
    current_low ep
                            ep 
    := current_low
                            af 
    := math.min(max_afaf inc)
                
                array.
    set(outinext_sar)
                
    sar_val := next_sar
        out

    // ========================================================================= //
    // =========================== DRAWING LOGIC =============================== //
    // ========================================================================= //

    var box[]   bg_boxes   = array.new_box()
    var 
    box[]   candle_b   = array.new_box()
    var 
    line[]  candle_w   = array.new_line()
    var 
    line[]  sar_lines  = array.new_line()

    f_cleanup() =>
        for 
    b in bg_boxes
            box
    .delete(b)
        for 
    b in candle_b
            box
    .delete(b)
        for 
    l in candle_w
            line
    .delete(l)
        for 
    l in sar_lines
            line
    .delete(l)
        array.
    clear(bg_boxes)
        array.
    clear(candle_b)
        array.
    clear(candle_w)
        array.
    clear(sar_lines)

    f_format_tf(string tf) =>
        
    float num str.tonumber(tf)
        
    string res tf
        
    if not na(num)
            
    res := num >= 60 str.tostring(int(num 60)) + "h" str.tostring(int(num)) + "m"
        
    res

    f_draw_minichart
    (HTF_Data datastring tf_labelint candlesint level) =>
        
    int n = array.size(data.c)
        if 
    2
            
    // SAR dizilerini oluþtur
            
    float[] sarK f_calc_sar(data.hdata.l0.0050.0050.05// Kýrmýzý (Yavaþ)
            
    float[] sarM f_calc_sar(data.hdata.l0.01,  0.01,  0.10// Mavi (Orta)
            
    float[] sarS f_calc_sar(data.hdata.l0.02,  0.02,  0.20// Sarý (Hýzlý)

            // Kutudan taþmamasý için genel Max/Min bulma
            
    float max_h = array.max(data.h)
            
    float min_l = array.min(data.l)
            
            for 
    0 to n 1
                float k 
    = array.get(sarKi)
                
    float m = array.get(sarMi)
                
    float s = array.get(sarSi)
                if 
    not na(k)
                    
    max_h := math.max(max_hk), min_l := math.min(min_lk)
                if 
    not na(m)
                    
    max_h := math.max(max_hm), min_l := math.min(min_lm)
                if 
    not na(s)
                    
    max_h := math.max(max_hs), min_l := math.min(min_ls)

            
    float hv ta.highest(high300)
            
    float lv ta.lowest(low300)
            
    float cr hv lv == syminfo.mintick 100 hv lv
            float my 
    = (hv lv) / 2
            float er 
    cr i_vScale

            int   col_idx 
    level 2
            int   row_idx 
    int(level 2)
            
    float row_gap er i_vBuffer
            float bh      
    = (er row_gap 2) / 3
            float start_y 
    my er 2
            float top_y   
    start_y row_idx * (bh row_gap)
            
    float bot_y   top_y bh

            int start_x 
    bar_index i_offset col_idx * (i_width i_gapX)
            
    int end_x   start_x i_width

            float itop 
    top_y bh 0.02
            float ibot 
    bot_y bh 0.02
            float ir   
    itop ibot
            float hr   
    max_h min_l == syminfo.mintick max_h min_l

            
    array.push(bg_boxesbox.new(start_xtop_yend_xbot_y,
                 
    border_color=c_borderbgcolor=c_bg,
                 
    text=f_format_tf(tf_label),
                 
    text_color=c_texttext_halign=text.align_center,
                 
    text_valign=text.align_bottomtext_size=size.small))

            
    float bs float(i_width) / candles

            
    for 0 to n 1
                int   idx 
    i
                float _o  
    = array.get(data.oidx)
                
    float _h  = array.get(data.hidx)
                
    float _l  = array.get(data.lidx)
                
    float _c  = array.get(data.cidx)

                
    float so ibot + ((_o min_l) / hr) * ir
                float sh 
    ibot + ((_h min_l) / hr) * ir
                float sl 
    ibot + ((_l min_l) / hr) * ir
                float sc 
    ibot + ((_c min_l) / hr) * ir

                int   xp  
    end_x int(bs)
                
    color col _c >= _o c_up c_down

                
    // Mum çizimi
                
    array.push(candle_wline.new(xpshxpslcolor=col))
                array.
    push(candle_bbox.new(xp 1soxp 1scborder_color=colbgcolor=col))

                
    // SAR çizimi (Küçük yatay kesikler)
                
    float valK = array.get(sarKidx)
                
    float valM = array.get(sarMidx)
                
    float valS = array.get(sarSidx)

                if 
    not na(valK)
                    
    float sy ibot + ((valK min_l) / hr) * ir
                    
    array.push(sar_linesline.new(xp-1syxp+1sycolor=color.redwidth=2))
                
                if 
    not na(valM)
                    
    float sy ibot + ((valM min_l) / hr) * ir
                    
    array.push(sar_linesline.new(xp-1syxp+1sycolor=color.bluewidth=2))
                
                if 
    not na(valS)
                    
    float sy ibot + ((valS min_l) / hr) * ir
                    
    array.push(sar_linesline.new(xp-1syxp+1sycolor=color.yellowwidth=2))

    if 
    barstate.islast
        f_cleanup
    ()
        
    f_draw_minichart(data1tf1len10)
        
    f_draw_minichart(data2tf2len21)
        
    f_draw_minichart(data3tf3len32)
        
    f_draw_minichart(data4tf4len43)
        
    f_draw_minichart(data5tf5len54)
        
    f_draw_minichart(data6tf6len65
    16.07.2024 - 10.12.2024

  2. ýcs bulut oluþturma örneði... https://www.tradingview.com/x/kJVRwPmj/

    PHP Code:
    //@version=6
    indicator("Yörük [Tek ICS Bulutu: 21]"shorttitle="ICS 21"overlay=truemax_lines_count=20max_bars_back=500)

    // ─────────────────────────────────────────────────────────────────
    //  1. SABÝTLER VE GÝRDÝLER
    // ─────────────────────────────────────────────────────────────────
    const float MIN_SIGMA 1e-10   
    const float PI        math.pi 

    color i_fillUp  
    input.color(#26a69a, "Yükseliþ Bulutu")
    color i_fillDn  input.color(#ef5350, "Düþüþ Bulutu")
    color i_fillRng input.color(#888888, "Yatay Bulut")
    int i_fillTr    input.int(85"Bulut Þeffaflýðý"minval 0maxval 100)

    // ─────────────────────────────────────────────────────────────────
    //  2. ÝZOTROPÝK KOORDÝNAT SÝSTEMÝ (ICS) MATEMATÝÐÝ
    // ─────────────────────────────────────────────────────────────────
    f_icsLine(float p1int x1float p2int x2int targetXfloat sig) =>
        
    float out p1
        
    if x1 != x2 and p1 and p2 and sig MIN_SIGMA
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            float yT 
    y1 + (y2 y1) * (targetX x1) / (x2 x1)
            
    out := math.exp(yT sig)
        
    out

    f_icsAngle
    (float p1int x1float p2int x2float sig) =>
        
    float out 0.0
        
    if x1 != x2 and p1 and p2 and sig MIN_SIGMA
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            out 
    := math.atan((y2 y1) / (x2 x1)) * 180.0 PI
        out

    // ─────────────────────────────────────────────────────────────────
    //  3. YANG-ZHANG VOLATÝLÝTE (σ) MANTIÐI
    // ─────────────────────────────────────────────────────────────────
    int i_sigmaLen 20
    float _yzOR 
    math.log(open nz(close[1], open))
    float _yzCO math.log(close open)
    float _yzHO math.log(high open)
    float _yzHC math.log(high close)
    float _yzLO math.log(low  open)
    float _yzLC math.log(low  close)

    float _sqOR ta.variance(_yzORi_sigmaLen)
    float _sqCO ta.variance(_yzCOi_sigmaLen)
    float _sqRS ta.sma(_yzHO _yzHC _yzLO _yzLCi_sigmaLen)

    float _k    0.34 / (1.34 + (i_sigmaLen 1.0) / math.max(i_sigmaLen 1.01.0))
    float _sq   nz(_sqOR) + _k nz(_sqCO) + (1.0 _k) * nz(_sqRS)
    float sigma math.max(math.sqrt(math.max(_sq0.0)), MIN_SIGMA)

    // ─────────────────────────────────────────────────────────────────
    //  4. SADECE 21 PERÝYODU ÝÇÝN GEÇMÝÞ BLOK VERÝLERÝ
    // ─────────────────────────────────────────────────────────────────
    float hh21 ta.highest(high21)
    float ll21 ta.lowest(low21)

    max_bars_back(hh21500)
    max_bars_back(ll21500)

    // ─────────────────────────────────────────────────────────────────
    //  5. TEKLÝ BULUT ÇÝZÝM MOTORU (NESNE YÖNELÝMLÝ YAPI)
    // ─────────────────────────────────────────────────────────────────
    type CloudDrawing
        line upLn
        line loLn
        line upPj
        line loPj
        linefill chFill
        linefill pjFill

    method updateCloud
    (CloudDrawing thisint Pseries float hhSseries float llSfloat sigcolor cUpcolor cDncolor cRngint transp) =>
        
    int groups 5
        float thresh 
    0.5
        int pjOff 
    34 // Ýleri Projeksiyon 34 Mum olarak sabitlendi
        
        
    bool _ok bar_index >= groups P
        
        
    if barstate.islastconfirmedhistory or barstate.islast
            line
    .delete(this.upLn)
            
    line.delete(this.loLn)
            
    line.delete(this.upPj)
            
    line.delete(this.loPj)
            
    linefill.delete(this.chFill)
            
    linefill.delete(this.pjFill)
            
            array<
    float_bGm = array.new<float>()
            array<
    float_bHi = array.new<float>()
            array<
    float_bLo = array.new<float>()
            array<
    int>   _bCx = array.new<int>()
            
            if 
    _ok
                
    for 0 to groups 1
                    int off 
    P
                    float hi 
    hhS[off]
                    
    float lo llS[off]
                    
    _bGm.push((hi and lo 0) ? math.exp((math.log(hi) + math.log(lo)) / 2.0) : na)
                    
    _bHi.push(hi)
                    
    _bLo.push(lo)
                    
    _bCx.push(bar_index off int(2))
                
                
    int _dir 0
                float _ang 
    0.0
                int _seg 
    0
                
                
    if _bGm.size() >= 2
                    float g0 
    _bGm.get(0)
                    
    float g1 _bGm.get(1)
                    if 
    not na(g0) and not na(g1) and g0 != g1
                        int pd 
    g0 g1 : -1
                        _seg 
    := 1
                        
    if groups 2
                            
    for 1 to groups 2
                                float a 
    _bGm.get(i)
                                
    float b _bGm.get(1)
                                if 
    not na(a) and not na(b)
                                    if (
    : (? -0)) == pd
                                        _seg 
    := 1
                                    
    else
                                        break
                                else
                                    break
                        
                        if 
    _bGm.size() > _seg
                            _ang 
    := f_icsAngle(_bGm.get(_seg), _bCx.get(_seg), _bGm.get(0), _bCx.get(0), sig)
                        
                        
    _dir := math.abs(_ang) <= thresh pd
                
                
    if _seg >= and _bHi.size() > _seg
                    float fHH 
    nafloat fLH nafloat fHL nafloat fLL na
                    int   xHH 
    naint   xLH naint   xHL naint   xLL na
                    
                    
    for 0 to _seg
                        float h 
    _bHi.get(i)
                        
    float l _bLo.get(i)
                        
    int   x _bCx.get(i)
                        if 
    na(fHH) or fHH
                            fHH 
    := hxHH := x
                        
    if na(fLH) or fLH
                            fLH 
    := hxLH := x
                        
    if na(fHL) or fHL
                            fHL 
    := lxHL := x
                        
    if na(fLL) or fLL
                            fLL 
    := lxLL := x

                    int sLx 
    _bCx.get(_seg)
                    
    int sRx _bCx.get(0)
                    
    float uY1 nafloat uY2 nafloat lY1 nafloat lY2 na
                    
                    
    if _dir == 1
                        uY1 
    := f_icsLine(fLHxLHfHHxHHsLxsig)
                        
    uY2 := f_icsLine(fLHxLHfHHxHHsRxsig)
                        
    lY1 := f_icsLine(fLLxLLfHLxHLsLxsig)
                        
    lY2 := f_icsLine(fLLxLLfHLxHLsRxsig)
                    else if 
    _dir == -1
                        uY1 
    := f_icsLine(fHHxHHfLHxLHsLxsig)
                        
    uY2 := f_icsLine(fHHxHHfLHxLHsRxsig)
                        
    lY1 := f_icsLine(fHLxHLfLLxLLsLxsig)
                        
    lY2 := f_icsLine(fHLxHLfLLxLLsRxsig)
                    else
                        
    uY1 := nz(fHH), uY2 := nz(fHH)
                        
    lY1 := nz(fLL), lY2 := nz(fLL)

                    
    int ax bar_index
                    float uYa 
    f_icsLine(uY1sLxuY2sRxaxsig)
                    
    float lYa f_icsLine(lY1sLxlY2sRxaxsig)

                    
    this.upLn := line.new(sLxuY1axuYacolor na)
                    
    this.loLn := line.new(sLxlY1axlYacolor na)

                    
    int eX ax pjOff
                    float uYe 
    f_icsLine(uY1sLxuY2sRxeXsig)
                    
    float lYe f_icsLine(lY1sLxlY2sRxeXsig)
                    
                    
    this.upPj := line.new(axuYaeXuYecolor na)
                    
    this.loPj := line.new(axlYaeXlYecolor na)

                    
    color baseColor _dir == cUp _dir == -cDn cRng
                    color fc 
    color.new(baseColortransp)
                    
                    
    this.chFill := linefill.new(this.upLnthis.loLnfc)
                    
    this.pjFill := linefill.new(this.upPjthis.loPjfc)

    // ─────────────────────────────────────────────────────────────────
    //  6. BULUTU BAÞLAT VE GÜNCELLE
    // ─────────────────────────────────────────────────────────────────
    var c21 CloudDrawing.new(nananananana)

    // Sadece tek bulut (21) iþleniyor
    c21.updateCloud(21hh21ll21sigmai_fillUpi_fillDni_fillRngi_fillTr
    16.07.2024 - 10.12.2024

  3. bulutu... yineleme... 3lü trend bulutu... 13-21-34 deðerli kullanýlmýþ örnek...
    https://www.tradingview.com/x/VkrklFje/
    16.07.2024 - 10.12.2024

  4. tek bulutu...mtf... chart gösterim... üzerinde çalýþýlacak...
    yani kutulara deðerleri yazma gibi... https://www.tradingview.com/x/w5hSL4iD/ bu çalýþmasý devam eden hali...

    PHP Code:
    //@version=5
    indicator(" [ICS 21 Bulutu]"overlay=truemax_boxes_count=500max_lines_count=500)

    // ========================================================================= //
    // =============================== GÝRDÝLER ================================ //
    // ========================================================================= //

    grp_pos "PENCERE AYARLARI"
    i_width   input.int(45,    "Grafik Geniþliði"group=grp_pos)
    i_offset  input.int(5,     "Yatay Uzaklýk",    group=grp_pos)
    i_gapX    input.int(10,    "Yatay Boþluk",     group=grp_pos)
    i_vScale  input.float(35.0"Dikey Ölçekleme",  group=grp_posstep=0.1)
    i_vBuffer input.float(0.02"Dikey Tampon (%)"group=grp_posstep=0.01)

    tf1 input.timeframe("5",  "Periyot 1"group="ZAMAN DÝLÝMLERÝ")
    tf2 input.timeframe("15",  "Periyot 2"group="ZAMAN DÝLÝMLERÝ")
    tf3 input.timeframe("60""Periyot 3"group="ZAMAN DÝLÝMLERÝ")
    tf4 input.timeframe("240",   "Periyot 4"group="ZAMAN DÝLÝMLERÝ")

    c_up      input.color(color.new(#00e676, 0), "Yükseliþ Mumu", group="RENKLER")
    c_down    input.color(color.new(#ff1744, 0), "Düþüþ Mumu",    group="RENKLER")
    c_bg      input.color(color.new(#1a1a1a, 85), "Arka Plan",    group="RENKLER")
    c_border  input.color(color.new(#ffffff, 80), "Çerçeve",      group="RENKLER")

    c_fillUp  input.color(color.new(#26a69a, 80), "Yükseliþ Bulutu", group="BULUT RENKLERÝ")
    c_fillDn  input.color(color.new(#ef5350, 80), "Düþüþ Bulutu",    group="BULUT RENKLERÝ")
    c_fillRng input.color(color.new(#888888, 80), "Yatay Bulut",     group="BULUT RENKLERÝ")

    // ========================================================================= //
    // ================== ICS 21 MATEMATÝÐÝ (DÝZÝLERDEN ARINDIRILMIÞ) ========== //
    // ========================================================================= //

    f_yz_sigma(len) =>
        
    float _yzOR math.log(open nz(close[1], open))
        
    float _yzCO math.log(close open)
        
    float _yzHO math.log(high open)
        
    float _yzHC math.log(high close)
        
    float _yzLO math.log(low  open)
        
    float _yzLC math.log(low  close)
        
    float _sqOR ta.variance(_yzORlen)
        
    float _sqCO ta.variance(_yzCOlen)
        
    float _sqRS ta.sma(_yzHO _yzHC _yzLO _yzLClen)
        
    float _k    0.34 / (1.34 + (len 1.0) / math.max(len 1.01.0))
        
    float _sq   nz(_sqOR) + _k nz(_sqCO) + (1.0 _k) * nz(_sqRS)
        
    math.max(math.sqrt(math.max(_sq0.0)), 1e-10)

    f_icsLine(p1x1p2x2targetXsig) =>
        
    float out p1
        
    if x1 != x2 and p1 and p2 and sig 1e-10
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            float yT 
    y1 + (y2 y1) * (targetX x1) / (x2 x1)
            
    out := math.exp(yT sig)
        
    out

    f_icsAngle
    (p1x1p2x2sig) =>
        
    float out 0.0
        
    if x1 != x2 and p1 and p2 and sig 1e-10
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            out 
    := math.atan((y2 y1) / (x2 x1)) * 180.0 math.pi
        out

    // Nativ ICS hesaplayýcýsý (Çökmeyi engellemek için array kullanmaz)
    f_ics_calc() =>
        
    int P 21
        float sig 
    f_yz_sigma(20)
        
        
    float h0 ta.highest(highP), float l0 ta.lowest(lowP)
        
        
    // Yeterli bar yoksa doðrudan fiyatý döndür
        
    if bar_index 5
            
    [h0l00.0]
        else
            
    float h1 h0[P],   float l1 l0[P]
            
    float h2 h0[P*2], float l2 l0[P*2]
            
    float h3 h0[P*3], float l3 l0[P*3]
            
    float h4 h0[P*4], float l4 l0[P*4]

            
    float g0 = (h0 and l0 0) ? math.exp((math.log(h0) + math.log(l0)) / 2.0) : na
            float g1 
    = (h1 and l1 0) ? math.exp((math.log(h1) + math.log(l1)) / 2.0) : na
            float g2 
    = (h2 and l2 0) ? math.exp((math.log(h2) + math.log(l2)) / 2.0) : na
            float g3 
    = (h3 and l3 0) ? math.exp((math.log(h3) + math.log(l3)) / 2.0) : na
            float g4 
    = (h4 and l4 0) ? math.exp((math.log(h4) + math.log(l4)) / 2.0) : na

            int pd 
    g0 g1 : -1
            int seg 
    1
            
    if g0 != g1
                
    if (g1 g2 : (g1 g2 ? -0)) == pd
                    seg 
    := 2
                    
    if (g2 g3 : (g2 g3 ? -0)) == pd
                        seg 
    := 3
                        
    if (g3 g4 : (g3 g4 ? -0)) == pd
                            seg 
    := 4

            int cx0 
    int(-P/2), int cx1 cx0 Pint cx2 cx1 Pint cx3 cx2 Pint cx4 cx3 P

            float fHH 
    h0float fLH h0float fHL l0float fLL l0
            int xHH 
    cx0int xLH cx0int xHL cx0int xLL cx0

            
    if seg >= 1
                
    if h1 fHH
                    fHH 
    := h1xHH := cx1
                
    if h1 fLH
                    fLH 
    := h1xLH := cx1
                
    if l1 fHL
                    fHL 
    := l1xHL := cx1
                
    if l1 fLL
                    fLL 
    := l1xLL := cx1
            
    if seg >= 2
                
    if h2 fHH
                    fHH 
    := h2xHH := cx2
                
    if h2 fLH
                    fLH 
    := h2xLH := cx2
                
    if l2 fHL
                    fHL 
    := l2xHL := cx2
                
    if l2 fLL
                    fLL 
    := l2xLL := cx2
            
    if seg >= 3
                
    if h3 fHH
                    fHH 
    := h3xHH := cx3
                
    if h3 fLH
                    fLH 
    := h3xLH := cx3
                
    if l3 fHL
                    fHL 
    := l3xHL := cx3
                
    if l3 fLL
                    fLL 
    := l3xLL := cx3
            
    if seg >= 4
                
    if h4 fHH
                    fHH 
    := h4xHH := cx4
                
    if h4 fLH
                    fLH 
    := h4xLH := cx4
                
    if l4 fHL
                    fHL 
    := l4xHL := cx4
                
    if l4 fLL
                    fLL 
    := l4xLL := cx4

            int sLx 
    seg == cx1 seg == cx2 seg == cx3 cx4
            int sRx 
    cx0

            float endG 
    seg == g1 seg == g2 seg == g3 g4
            float ang 
    f_icsAngle(endGsLxg0sRxsig)

            
    int dir math.abs(ang) <= 0.5 pd

            float uY1 
    fHHfloat uY2 fHHfloat lY1 fLLfloat lY2 fLL
            
    if dir == 1
                uY1 
    := f_icsLine(fLHxLHfHHxHHsLxsig), uY2 := f_icsLine(fLHxLHfHHxHHsRxsig)
                
    lY1 := f_icsLine(fLLxLLfHLxHLsLxsig), lY2 := f_icsLine(fLLxLLfHLxHLsRxsig)
            else if 
    dir == -1
                uY1 
    := f_icsLine(fHHxHHfLHxLHsLxsig), uY2 := f_icsLine(fHHxHHfLHxLHsRxsig)
                
    lY1 := f_icsLine(fHLxHLfLLxLLsLxsig), lY2 := f_icsLine(fHLxHLfLLxLLsRxsig)

            
    float uYa f_icsLine(uY1sLxuY2sRx0sig)
            
    float lYa f_icsLine(lY1sLxlY2sRx0sig)

            [
    uYalYafloat(dir)]

    // ========================================================================= //
    // =================== HTF (BÜYÜK ZAMAN) VERÝ PAKETLEYÝCÝ ================== //
    // ========================================================================= //

    // 15 mumluk veriyi çökmeyi engelleyecek þekilde sabit statik dizilere paketliyoruz.
    f_veri_paketi() =>
        
    o_arr = array.new_float(15na), h_arr = array.new_float(15na), l_arr = array.new_float(15na), c_arr = array.new_float(15na)
        
    u_arr = array.new_float(15na), dn_arr = array.new_float(15na), dir_arr = array.new_float(15na)
        
        [
    udndir] = f_ics_calc()
        
        for 
    0 to 14
            
    array.set(o_arriopen[i])
            array.
    set(h_arrihigh[i])
            array.
    set(l_arrilow[i])
            array.
    set(c_arriclose[i])
            array.
    set(u_arriu[i])
            array.
    set(dn_arridn[i])
            array.
    set(dir_arridir[i])
            
        [
    o_arrh_arrl_arrc_arru_arrdn_arrdir_arr]

    [
    o1h1l1c1u1dn1dir1] = request.security(syminfo.tickeridtf1f_veri_paketi())
    [
    o2h2l2c2u2dn2dir2] = request.security(syminfo.tickeridtf2f_veri_paketi())
    [
    o3h3l3c3u3dn3dir3] = request.security(syminfo.tickeridtf3f_veri_paketi())
    [
    o4h4l4c4u4dn4dir4] = request.security(syminfo.tickeridtf4f_veri_paketi())

    // ========================================================================= //
    // =========================== ÇÝZÝM MOTORU ================================ //
    // ========================================================================= //

    var box[]  kutu_bg    = array.new_box()
    var 
    box[]  kutu_bulut = array.new_box()
    var 
    box[]  kutu_mum   = array.new_box()
    var 
    line[] cizgi_mum  = array.new_line()

    f_temizle() =>
        for 
    b in kutu_bg
            box
    .delete(b)
        for 
    b in kutu_bulut
            box
    .delete(b)
        for 
    b in kutu_mum
            box
    .delete(b)
        for 
    l in cizgi_mum
            line
    .delete(l)
        array.
    clear(kutu_bg), array.clear(kutu_bulut), array.clear(kutu_mum), array.clear(cizgi_mum)

    f_isim_ver(tf) =>
        
    float num str.tonumber(tf)
        
    string res tf
        
    if not na(num)
            
    res := num >= 60 str.tostring(int(num 60)) + "S" str.tostring(int(num)) + "D"
        
    else
            
    res := tf == "D" "GÜN" tf == "W" "HFT" tf
        res

    f_mini_grafik_ciz
    (o_arrh_arrl_arrc_arru_arrdn_arrdir_arrtf_labellevel) =>
        if array.
    size(c_arr) > and not na(array.get(c_arr0))
            
    float max_h = array.max(h_arr)
            
    float min_l = array.min(l_arr)
            
            
    // Bulut sýnýrlarýný da kutu dýþýna taþmamasý için kontrol ediyoruz
            
    for 0 to 14
                float u_val 
    = array.get(u_arri)
                
    float l_val = array.get(dn_arri)
                if 
    not na(u_val)
                    
    max_h := math.max(max_hu_val), min_l := math.min(min_lu_val)
                if 
    not na(l_val)
                    
    max_h := math.max(max_hl_val), min_l := math.min(min_ll_val)

            
    float hv ta.highest(high300)
            
    float lv ta.lowest(low300)
            
    float cr hv lv == syminfo.mintick 100 hv lv
            float my 
    = (hv lv) / 2
            float er 
    cr i_vScale

            int   col_idx 
    level 2
            int   row_idx 
    int(level 2)
            
    float row_gap er i_vBuffer
            float bh      
    = (er row_gap 2) / 3
            float start_y 
    my er 2
            float top_y   
    start_y row_idx * (bh row_gap)
            
    float bot_y   top_y bh

            int start_x 
    bar_index i_offset col_idx * (i_width i_gapX)
            
    int end_x   start_x i_width

            float itop 
    top_y bh 0.02
            float ibot 
    bot_y bh 0.02
            float ir   
    itop ibot
            float hr   
    max_h min_l == syminfo.mintick max_h min_l
            
            
    // 1. EKRAN ARKA PLANI
            
    box arka_plan box.new(start_xtop_yend_xbot_yborder_color=c_borderbgcolor=c_bg)
            
    box.set_text(arka_planf_isim_ver(tf_label))
            
    box.set_text_color(arka_plancolor.gray)
            
    box.set_text_halign(arka_plantext.align_center)
            
    box.set_text_valign(arka_plantext.align_bottom)
            
    box.set_text_size(arka_plansize.small)
            array.
    push(kutu_bgarka_plan)

            
    float bs float(i_width) / 15
            int box_w 
    math.max(1int(bs 2))

            for 
    0 to 14
                int   idx 
    14 i
                float _o  
    = array.get(o_arridx)
                
    float _h  = array.get(h_arridx)
                
    float _l  = array.get(l_arridx)
                
    float _c  = array.get(c_arridx)
                
                
    float u_val = array.get(u_arridx)
                
    float l_val = array.get(dn_arridx)
                
    float d_val = array.get(dir_arridx)

                
    float so ibot + ((_o min_l) / hr) * ir
                float sh 
    ibot + ((_h min_l) / hr) * ir
                float sl 
    ibot + ((_l min_l) / hr) * ir
                float sc 
    ibot + ((_c min_l) / hr) * ir

                int   xp  
    end_x int(bs)
                
    color col _c >= _o c_up c_down

                
    // 2. BULUT DOLGUSU (Mumlarýn arkasýnda kalmasý için önce çizilir)
                
    if not na(u_val) and not na(l_val)
                    
    float sy_u ibot + ((u_val min_l) / hr) * ir
                    float sy_l 
    ibot + ((l_val min_l) / hr) * ir
                    color cCloud 
    d_val == c_fillUp d_val == -c_fillDn c_fillRng
                    
                    
    // Bulut dolgusu efekti vermek için her bara þeffaf bir kutu çiziyoruz
                    
    array.push(kutu_bulutbox.new(xp box_wsy_uxp box_wsy_lbgcolor=cCloudborder_color=na))

                
    // 3. MUMLAR (Bulutun üstüne çizilir)
                
    array.push(cizgi_mumline.new(xpshxpslcolor=col))
                array.
    push(kutu_mumbox.new(xp 1soxp 1scborder_color=colbgcolor=col))

    if 
    barstate.islast
        f_temizle
    ()
        
    f_mini_grafik_ciz(o1h1l1c1u1dn1dir1tf10)
        
    f_mini_grafik_ciz(o2h2l2c2u2dn2dir2tf21)
        
    f_mini_grafik_ciz(o3h3l3c3u3dn3dir3tf32)
        
    f_mini_grafik_ciz(o4h4l4c4u4dn4dir4tf43
    denemek ve geliþtirmek isteyene...
    16.07.2024 - 10.12.2024

  5. deneme...
    PHP Code:
    //@version=5
    indicator("Little Chart [Tekil ICS 21]"overlay=truemax_boxes_count=5000max_lines_count=500max_labels_count=50)

    // ========================================================================= //
    // =============================== GÝRDÝLER ================================ //
    // ========================================================================= //

    grp_pos "PENCERE VE BOYUT AYARLARI"
    i_bars    input.int(10,    "Gösterilecek Mum Sayýsý"group=grp_posminval=10)
    i_width   input.int(20,   "Pencere Geniþliði (Bar)"group=grp_posminval=20)
    i_offset  input.int(1,    "Yatay Uzaklýk (Saða)",    group=grp_pos)
    i_vScale  input.float(100.0"Dikey Ölçekleme (%)",    group=grp_posstep=1.0)

    grp_style "RENKLER VE GÖRSELLÝK"
    c_up      input.color(color.new(#00e676, 0), "Yükseliþ Mumu", group=grp_style)
    c_down    input.color(color.new(#ff1744, 0), "Düþüþ Mumu",    group=grp_style)
    c_bg      input.color(color.new(#0b0e14, 20), "Arka Plan Kutusu",group=grp_style)
    c_border  input.color(color.new(#ffffff, 80), "Pencere Çerçevesi",group=grp_style)

    c_fillUp  input.color(color.new(#26a69a, 60), "Bulut (Yükseliþ)", group=grp_style)
    c_fillDn  input.color(color.new(#ef5350, 60), "Bulut (Düþüþ)",    group=grp_style)
    c_fillRng input.color(color.new(#888888, 60), "Bulut (Yatay)",     group=grp_style)

    // ========================================================================= //
    // ================== ICS 21 MATEMATÝÐÝ (YERLEÞÝK HESAPLAMA) =============== //
    // ========================================================================= //
    // Dizi (Array) kullanmadan, doðrudan zaman serisi üzerinden çalýþýr. Çökmez.

    f_yz_sigma(len) =>
        
    float _yzOR math.log(open nz(close[1], open))
        
    float _yzCO math.log(close open)
        
    float _yzHO math.log(high open)
        
    float _yzHC math.log(high close)
        
    float _yzLO math.log(low  open)
        
    float _yzLC math.log(low  close)
        
    float _sqOR ta.variance(_yzORlen)
        
    float _sqCO ta.variance(_yzCOlen)
        
    float _sqRS ta.sma(_yzHO _yzHC _yzLO _yzLClen)
        
    float _k    0.34 / (1.34 + (len 1.0) / math.max(len 1.01.0))
        
    float _sq   nz(_sqOR) + _k nz(_sqCO) + (1.0 _k) * nz(_sqRS)
        
    math.max(math.sqrt(math.max(_sq0.0)), 1e-10)

    f_icsLine(p1x1p2x2targetXsig) =>
        
    float out p1
        
    if x1 != x2 and p1 and p2 and sig 1e-10
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            float yT 
    y1 + (y2 y1) * (targetX x1) / (x2 x1)
            
    out := math.exp(yT sig)
        
    out

    f_icsAngle
    (p1x1p2x2sig) =>
        
    float out 0.0
        
    if x1 != x2 and p1 and p2 and sig 1e-10
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            out 
    := math.atan((y2 y1) / (x2 x1)) * 180.0 math.pi
        out

    f_ics_calc
    () =>
        
    int P 21
        float sig 
    f_yz_sigma(20)
        
        
    float h0 ta.highest(highP), float l0 ta.lowest(lowP)
        
        if 
    bar_index 5
            
    [h0l00.0]
        else
            
    float h1 h0[P],   float l1 l0[P]
            
    float h2 h0[P*2], float l2 l0[P*2]
            
    float h3 h0[P*3], float l3 l0[P*3]
            
    float h4 h0[P*4], float l4 l0[P*4]

            
    float g0 = (h0 and l0 0) ? math.exp((math.log(h0) + math.log(l0)) / 2.0) : na
            float g1 
    = (h1 and l1 0) ? math.exp((math.log(h1) + math.log(l1)) / 2.0) : na
            float g2 
    = (h2 and l2 0) ? math.exp((math.log(h2) + math.log(l2)) / 2.0) : na
            float g3 
    = (h3 and l3 0) ? math.exp((math.log(h3) + math.log(l3)) / 2.0) : na
            float g4 
    = (h4 and l4 0) ? math.exp((math.log(h4) + math.log(l4)) / 2.0) : na

            int pd 
    g0 g1 : -1
            int seg 
    1
            
    if g0 != g1
                
    if (g1 g2 : (g1 g2 ? -0)) == pd
                    seg 
    := 2
                    
    if (g2 g3 : (g2 g3 ? -0)) == pd
                        seg 
    := 3
                        
    if (g3 g4 : (g3 g4 ? -0)) == pd
                            seg 
    := 4

            int cx0 
    int(-P/2), int cx1 cx0 Pint cx2 cx1 Pint cx3 cx2 Pint cx4 cx3 P

            float fHH 
    h0float fLH h0float fHL l0float fLL l0
            int xHH 
    cx0int xLH cx0int xHL cx0int xLL cx0

            
    if seg >= 1
                
    if h1 fHH
                    fHH 
    := h1xHH := cx1
                
    if h1 fLH
                    fLH 
    := h1xLH := cx1
                
    if l1 fHL
                    fHL 
    := l1xHL := cx1
                
    if l1 fLL
                    fLL 
    := l1xLL := cx1
            
    if seg >= 2
                
    if h2 fHH
                    fHH 
    := h2xHH := cx2
                
    if h2 fLH
                    fLH 
    := h2xLH := cx2
                
    if l2 fHL
                    fHL 
    := l2xHL := cx2
                
    if l2 fLL
                    fLL 
    := l2xLL := cx2
            
    if seg >= 3
                
    if h3 fHH
                    fHH 
    := h3xHH := cx3
                
    if h3 fLH
                    fLH 
    := h3xLH := cx3
                
    if l3 fHL
                    fHL 
    := l3xHL := cx3
                
    if l3 fLL
                    fLL 
    := l3xLL := cx3
            
    if seg >= 4
                
    if h4 fHH
                    fHH 
    := h4xHH := cx4
                
    if h4 fLH
                    fLH 
    := h4xLH := cx4
                
    if l4 fHL
                    fHL 
    := l4xHL := cx4
                
    if l4 fLL
                    fLL 
    := l4xLL := cx4

            int sLx 
    seg == cx1 seg == cx2 seg == cx3 cx4
            int sRx 
    cx0

            float endG 
    seg == g1 seg == g2 seg == g3 g4
            float ang 
    f_icsAngle(endGsLxg0sRxsig)

            
    int dir math.abs(ang) <= 0.5 pd

            float uY1 
    fHHfloat uY2 fHHfloat lY1 fLLfloat lY2 fLL
            
    if dir == 1
                uY1 
    := f_icsLine(fLHxLHfHHxHHsLxsig), uY2 := f_icsLine(fLHxLHfHHxHHsRxsig)
                
    lY1 := f_icsLine(fLLxLLfHLxHLsLxsig), lY2 := f_icsLine(fLLxLLfHLxHLsRxsig)
            else if 
    dir == -1
                uY1 
    := f_icsLine(fHHxHHfLHxLHsLxsig), uY2 := f_icsLine(fHHxHHfLHxLHsRxsig)
                
    lY1 := f_icsLine(fHLxHLfLLxLLsLxsig), lY2 := f_icsLine(fHLxHLfLLxLLsRxsig)

            
    float uYa f_icsLine(uY1sLxuY2sRx0sig)
            
    float lYa f_icsLine(lY1sLxlY2sRx0sig)

            [
    uYalYafloat(dir)]

    // O anki mumun bulut deðerlerini global olarak alýyoruz
    [uYalYabulut_yon] = f_ics_calc()

    // ========================================================================= //
    // =========================== ÇÝZÝM MOTORU (HÝYERARÞÝ) ==================== //
    // ========================================================================= //

    var box[]   kutu_bg     = array.new_box()
    var 
    line[]  cizgi_merkez= array.new_line()
    var 
    box[]   kutu_bulut  = array.new_box()
    var 
    line[]  cizgi_mum   = array.new_line()
    var 
    box[]   kutu_mum    = array.new_box()
    var 
    label[] etiketler   = array.new_label()

    f_temizle() =>
        for 
    b in kutu_bg
            box
    .delete(b)
        for 
    l in cizgi_merkez
            line
    .delete(l)
        for 
    b in kutu_bulut
            box
    .delete(b)
        for 
    l in cizgi_mum
            line
    .delete(l)
        for 
    b in kutu_mum
            box
    .delete(b)
        for 
    lbl in etiketler
            label
    .delete(lbl)
        array.
    clear(kutu_bg), array.clear(cizgi_merkez), array.clear(kutu_bulut)
        array.
    clear(cizgi_mum), array.clear(kutu_mum), array.clear(etiketler)

    if 
    barstate.islast
        f_temizle
    ()
        
        
    // --- 1. ADIM: EKRANIN GENEL MATEMATÝÐÝ VE SINIRLARI ---
        
    float max_val high
        float min_val 
    low
        
        
    // Son 'i_bars' kadar mumu geçmiþe doðru tarayýp o bölgenin Max ve Min deðerlerini buluyoruz
        
    for 0 to i_bars 1
            float _h 
    high[i], float _l low[i]
            
    float _u uYa[i],  float _d lYa[i]
            
            
    max_val := math.max(max_val_h)
            
    min_val := math.min(min_val_l)
            if 
    not na(_u)
                
    max_val := math.max(max_val_u), min_val := math.min(min_val_u)
            if 
    not na(_d)
                
    max_val := math.max(max_val_d), min_val := math.min(min_val_d)
                
        
    // Pencereyi nereye çizeceðiz? Ekranýn mevcut yüksekliðini referans alýyoruz
        
    float hv ta.highest(high300)
        
    float lv ta.lowest(low300)
        
    float cr hv lv == syminfo.mintick 100 hv lv
        float my 
    = (hv lv) / 2
        
        float er 
    cr * (i_vScale 100)
        
    float top_y my er 2
        float bot_y 
    my er 2
        float mid_y 
    = (top_y bot_y) / 2

        int start_x 
    bar_index i_offset
        int end_x   
    start_x i_width
        int mid_x   
    = (start_x end_x) / 2
        
        float hr 
    max_val min_val == syminfo.mintick max_val min_val
        float ir 
    top_y bot_y
        
        
    // Mumlar arasý geniþlik hesaplamasý
        
    float bs float(i_width) / i_bars
        int box_w 
    math.max(1int(bs 2))

        
    // --- 2. ADIM: HÝYERARÞÝK ÇÝZÝM ---
        
        // Hiyerarþi 1: Ana Pencere (Zemin)
        
    array.push(kutu_bgbox.new(start_xtop_yend_xbot_yborder_color=c_borderbgcolor=c_bg))
        
        
    // Hiyerarþi 2: Merkez Denge Çizgisi
        
    array.push(cizgi_merkezline.new(start_xmid_yend_xmid_ycolor=color.graystyle=line.style_dashed))

        
    // Hiyerarþi 3: Alt ve Üst Max/Min Etiketleri
        
    array.push(etiketlerlabel.new(mid_xtop_y"Max: " str.tostring(max_valformat.mintick), color=color.new(color.black100), textcolor=color.graystyle=label.style_label_downsize=size.small))
        array.
    push(etiketlerlabel.new(mid_xbot_y"Min: " str.tostring(min_valformat.mintick), color=color.new(color.black100), textcolor=color.graystyle=label.style_label_upsize=size.small))

        
    // Hiyerarþi 4 & 5: Bulutlar (Arkada) ve Mumlar (Önde)
        
    for 0 to i_bars 1
            int idx 
    i
            
            float _o 
    open[idx], float _h high[idx], float _l low[idx], float _c close[idx]
            
    float _u uYa[idx],  float _d lYa[idx],  float _dir bulut_yon[idx]
            
            
    // Fiyatlarý mini ekranýn y-koordinatlarýna dönüþtürüyoruz
            
    float so bot_y + ((_o min_val) / hr) * ir
            float sh 
    bot_y + ((_h min_val) / hr) * ir
            float sl 
    bot_y + ((_l min_val) / hr) * ir
            float sc 
    bot_y + ((_c min_val) / hr) * ir
            
            int xp 
    end_x int(bs)
            
            
    // A) Önce Bulutu Çiz (Arkada kalmasý için ilk bu çizilir)
            
    if not na(_u) and not na(_d)
                
    float sy_u bot_y + ((_u min_val) / hr) * ir
                float sy_d 
    bot_y + ((_d min_val) / hr) * ir
                color cCloud 
    _dir == c_fillUp _dir == -c_fillDn c_fillRng
                
    array.push(kutu_bulutbox.new(xp box_wsy_uxp box_wsy_dborder_color=nabgcolor=cCloud))
            
            
    // B) Sonra Mumu Çiz (Üste biner)
            
    color col _c >= _o c_up c_down
            
    array.push(cizgi_mumline.new(xpshxpslcolor=col))
            
            
    float box_top math.max(sosc)
            
    float box_bot math.min(sosc)
            if 
    box_top == box_bot
                
    // Mum doji ise çizgi çek
                
    array.push(cizgi_mumline.new(xp 1box_topxp 1box_botcolor=colwidth=2))
            else
                
    // Normal mum gövdesi
                
    array.push(kutu_mumbox.new(xp 1box_topxp 1box_botborder_color=colbgcolor=col)) 
    https://www.tradingview.com/x/XO6xMGDz/
    16.07.2024 - 10.12.2024


  6. PHP Code:
    //@version=6
    indicator("Yörük [3'lü ICS Bulutu: 13-21-34]"shorttitle="."overlay=truemax_lines_count=20max_bars_back=500)

    // ─────────────────────────────────────────────────────────────────
    //  1. SABÝTLER VE GÝRDÝLER
    // ─────────────────────────────────────────────────────────────────
    const float MIN_SIGMA 1e-10   
    const float PI        math.pi 

    color i_fillUp  
    input.color(#26a69a, "Yükseliþ Bulutu")
    color i_fillDn  input.color(#ef5350, "Düþüþ Bulutu")
    color i_fillRng input.color(#888888, "Yatay Bulut")
    int i_fillTr    input.int(85"Bulut Þeffaflýðý"minval 0maxval 100)

    // ─────────────────────────────────────────────────────────────────
    //  2. ÝZOTROPÝK KOORDÝNAT SÝSTEMÝ (ICS) MATEMATÝÐÝ
    // ─────────────────────────────────────────────────────────────────
    f_icsLine(float p1int x1float p2int x2int targetXfloat sig) =>
        
    float out p1
        
    if x1 != x2 and p1 and p2 and sig MIN_SIGMA
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            float yT 
    y1 + (y2 y1) * (targetX x1) / (x2 x1)
            
    out := math.exp(yT sig)
        
    out

    f_icsAngle
    (float p1int x1float p2int x2float sig) =>
        
    float out 0.0
        
    if x1 != x2 and p1 and p2 and sig MIN_SIGMA
            float y1 
    math.log(p1) / sig
            float y2 
    math.log(p2) / sig
            out 
    := math.atan((y2 y1) / (x2 x1)) * 180.0 PI
        out

    // ─────────────────────────────────────────────────────────────────
    //  3. YANG-ZHANG VOLATÝLÝTE (σ) MANTIÐI
    // ─────────────────────────────────────────────────────────────────
    int i_sigmaLen 20
    float _yzOR 
    math.log(open nz(close[1], open))
    float _yzCO math.log(close open)
    float _yzHO math.log(high open)
    float _yzHC math.log(high close)
    float _yzLO math.log(low  open)
    float _yzLC math.log(low  close)

    float _sqOR ta.variance(_yzORi_sigmaLen)
    float _sqCO ta.variance(_yzCOi_sigmaLen)
    float _sqRS ta.sma(_yzHO _yzHC _yzLO _yzLCi_sigmaLen)

    float _k    0.34 / (1.34 + (i_sigmaLen 1.0) / math.max(i_sigmaLen 1.01.0))
    float _sq   nz(_sqOR) + _k nz(_sqCO) + (1.0 _k) * nz(_sqRS)
    float sigma math.max(math.sqrt(math.max(_sq0.0)), MIN_SIGMA)

    // ─────────────────────────────────────────────────────────────────
    //  4. 13-21-34 PERÝYOTLARI ÝÇÝN GEÇMÝÞ BLOK VERÝLERÝ
    // ─────────────────────────────────────────────────────────────────
    float hh13 ta.highest(high13)
    float ll13 ta.lowest(low13)
    float hh21 ta.highest(high21)
    float ll21 ta.lowest(low21)
    float hh34 ta.highest(high34)
    float ll34 ta.lowest(low34)

    max_bars_back(hh13500)
    max_bars_back(ll13500)
    max_bars_back(hh21500)
    max_bars_back(ll21500)
    max_bars_back(hh34500)
    max_bars_back(ll34500)

    // ─────────────────────────────────────────────────────────────────
    //  5. ÇOKLU BULUT ÇÝZÝM MOTORU (NESNE YÖNELÝMLÝ YAPI)
    // ─────────────────────────────────────────────────────────────────
    type CloudDrawing
        line upLn
        line loLn
        line upPj
        line loPj
        linefill chFill
        linefill pjFill

    method updateCloud
    (CloudDrawing thisint Pseries float hhSseries float llSfloat sigcolor cUpcolor cDncolor cRngint transp) =>
        
    int groups 5
        float thresh 
    0.5
        int pjOff 
    34 // Ýleri Projeksiyon 34 Mum olarak sabitlendi
        
        
    bool _ok bar_index >= groups P
        
        
    if barstate.islastconfirmedhistory or barstate.islast
            line
    .delete(this.upLn)
            
    line.delete(this.loLn)
            
    line.delete(this.upPj)
            
    line.delete(this.loPj)
            
    linefill.delete(this.chFill)
            
    linefill.delete(this.pjFill)
            
            array<
    float_bGm = array.new<float>()
            array<
    float_bHi = array.new<float>()
            array<
    float_bLo = array.new<float>()
            array<
    int>   _bCx = array.new<int>()
            
            if 
    _ok
                
    for 0 to groups 1
                    int off 
    P
                    float hi 
    hhS[off]
                    
    float lo llS[off]
                    
    _bGm.push((hi and lo 0) ? math.exp((math.log(hi) + math.log(lo)) / 2.0) : na)
                    
    _bHi.push(hi)
                    
    _bLo.push(lo)
                    
    _bCx.push(bar_index off int(2))
                
                
    int _dir 0
                float _ang 
    0.0
                int _seg 
    0
                
                
    if _bGm.size() >= 2
                    float g0 
    _bGm.get(0)
                    
    float g1 _bGm.get(1)
                    if 
    not na(g0) and not na(g1) and g0 != g1
                        int pd 
    g0 g1 : -1
                        _seg 
    := 1
                        
    if groups 2
                            
    for 1 to groups 2
                                float a 
    _bGm.get(i)
                                
    float b _bGm.get(1)
                                if 
    not na(a) and not na(b)
                                    if (
    : (? -0)) == pd
                                        _seg 
    := 1
                                    
    else
                                        break
                                else
                                    break
                        
                        if 
    _bGm.size() > _seg
                            _ang 
    := f_icsAngle(_bGm.get(_seg), _bCx.get(_seg), _bGm.get(0), _bCx.get(0), sig)
                        
                        
    _dir := math.abs(_ang) <= thresh pd
                
                
    if _seg >= and _bHi.size() > _seg
                    float fHH 
    nafloat fLH nafloat fHL nafloat fLL na
                    int   xHH 
    naint   xLH naint   xHL naint   xLL na
                    
                    
    for 0 to _seg
                        float h 
    _bHi.get(i)
                        
    float l _bLo.get(i)
                        
    int   x _bCx.get(i)
                        if 
    na(fHH) or fHH
                            fHH 
    := hxHH := x
                        
    if na(fLH) or fLH
                            fLH 
    := hxLH := x
                        
    if na(fHL) or fHL
                            fHL 
    := lxHL := x
                        
    if na(fLL) or fLL
                            fLL 
    := lxLL := x

                    int sLx 
    _bCx.get(_seg)
                    
    int sRx _bCx.get(0)
                    
    float uY1 nafloat uY2 nafloat lY1 nafloat lY2 na
                    
                    
    if _dir == 1
                        uY1 
    := f_icsLine(fLHxLHfHHxHHsLxsig)
                        
    uY2 := f_icsLine(fLHxLHfHHxHHsRxsig)
                        
    lY1 := f_icsLine(fLLxLLfHLxHLsLxsig)
                        
    lY2 := f_icsLine(fLLxLLfHLxHLsRxsig)
                    else if 
    _dir == -1
                        uY1 
    := f_icsLine(fHHxHHfLHxLHsLxsig)
                        
    uY2 := f_icsLine(fHHxHHfLHxLHsRxsig)
                        
    lY1 := f_icsLine(fHLxHLfLLxLLsLxsig)
                        
    lY2 := f_icsLine(fHLxHLfLLxLLsRxsig)
                    else
                        
    uY1 := nz(fHH), uY2 := nz(fHH)
                        
    lY1 := nz(fLL), lY2 := nz(fLL)

                    
    int ax bar_index
                    float uYa 
    f_icsLine(uY1sLxuY2sRxaxsig)
                    
    float lYa f_icsLine(lY1sLxlY2sRxaxsig)

                    
    this.upLn := line.new(sLxuY1axuYacolor na)
                    
    this.loLn := line.new(sLxlY1axlYacolor na)

                    
    int eX ax pjOff
                    float uYe 
    f_icsLine(uY1sLxuY2sRxeXsig)
                    
    float lYe f_icsLine(lY1sLxlY2sRxeXsig)
                    
                    
    this.upPj := line.new(axuYaeXuYecolor na)
                    
    this.loPj := line.new(axlYaeXlYecolor na)

                    
    color baseColor _dir == cUp _dir == -cDn cRng
                    color fc 
    color.new(baseColortransp)
                    
                    
    this.chFill := linefill.new(this.upLnthis.loLnfc)
                    
    this.pjFill := linefill.new(this.upPjthis.loPjfc)

    // ─────────────────────────────────────────────────────────────────
    //  6. BULUTLARI BAÞLAT VE GÜNCELLE
    // ─────────────────────────────────────────────────────────────────
    var c13 CloudDrawing.new(nananananana)
    var 
    c21 CloudDrawing.new(nananananana)
    var 
    c34 CloudDrawing.new(nananananana)

    // Fiyata eþ zamanlý olarak 3 ayrý katmanda iþleniyor
    c13.updateCloud(13hh13ll13sigmai_fillUpi_fillDni_fillRngi_fillTr)
    c21.updateCloud(21hh21ll21sigmai_fillUpi_fillDni_fillRngi_fillTr)
    c34.updateCloud(34hh34ll34sigmai_fillUpi_fillDni_fillRngi_fillTr)
    ///////////////////

    // ─────────────────────────────────────────────────────────────────
    // 1. 5'LÝ SAR MOTORU
    // ─────────────────────────────────────────────────────────────────
    roSarSlow     ta.sar(0.010.0010.02)
    roSarModerate ta.sar(0.010.0020.02)
    roSarFast     ta.sar(0.010.0030.02)
    roSarFast2    ta.sar(0.010.000010.02)
    roSarFast23   ta.sar(0.0010.000010.02)

    // SAR Seviyeleri
    plot(roSarSlow,     "SAR Yavaþ"color=color.new(color.blue0),    linewidth=1style=plot.style_cross)
    plot(roSarModerate"SAR Orta",  color=color.new(color.green0),   linewidth=1style=plot.style_cross)
    plot(roSarFast,     "SAR Hýzlý"color=color.new(color.red0),     linewidth=1style=plot.style_cross)
    plot(roSarFast2,    "SAR Trend"color=color.new(color.yellow0),  linewidth=1style=plot.style_cross)
    plot(roSarFast23,   "SAR Yörük"color=color.new(color.fuchsia0), linewidth=1style=plot.style_cross)

    // ─────────────────────────────────────────────────────────────────
    // 2. MATEMATÝKSEL ÇAKIÞMA KONTROLÜ (5'in 3'lü Kombinasyonlarý)
    // ─────────────────────────────────────────────────────────────────
    // Float (Küsürat) hassasiyeti için 1 tik yanýlma payý
    isEq(v1v2) => math.abs(v1 v2) <= syminfo.mintick

    // 3 Deðerin de birbirine eþit olma durumu
    isEq3(v1v2v3) => isEq(v1v2) and isEq(v1v3)

    s1 roSarSlow
    s2 
    roSarModerate
    s3 
    roSarFast
    s4 
    roSarFast2
    s5 
    roSarFast23

    // 10 Olasý 3'lü Çakýþma Senaryosu (Kombinasyon C(5,3) = 10)
    c1  isEq3(s1s2s3)
    c2  isEq3(s1s2s4)
    c3  isEq3(s1s2s5)
    c4  isEq3(s1s3s4)
    c5  isEq3(s1s3s5)
    c6  isEq3(s1s4s5)
    c7  isEq3(s2s3s4)
    c8  isEq3(s2s3s5)
    c9  isEq3(s2s4s5)
    c10 isEq3(s3s4s5)

    // Herhangi bir 3'lü çakýþma var mý?
    any3 c1 or c2 or c3 or c4 or c5 or c6 or c7 or c8 or c9 or c10

    // Çakýþan deðeri bul (Elmasý ekranda tam olarak o fiyata basabilmek için)
    float matchVal na
    if c1 or c2 or c3 or c4 or c5 or c6
        matchVal 
    := s1
    else if c7 or c8 or c9
        matchVal 
    := s2
    else if c10
        matchVal 
    := s3

    // Sinyali, çakýþmanýn gerçekleþtiði ve yeni baþladýðý barda tetikle
    trigger any3 and not any3[1]

    // ─────────────────────────────────────────────────────────────────
    // 3. GÖRSELLEÞTÝRME VE ALARM
    // ─────────────────────────────────────────────────────────────────
    // Çakýþma anýnda fiyat çakýþma noktasýnýn üstündeyse Destek (Yeþil), altýndaysa Direnç (Kýrmýzý)
    isSupport close matchVal
    diamondColor 
    isSupport color.green color.red

    // Sinyal (Elmas)
    plotshape(trigger matchVal na"3'lü Çakýþma Sinyali"shape.diamondlocation.absolutecolor=diamondColorsize=size.small)

    // Alarmlar
    alertcondition(trigger and isSupport"Çakýþma: Destek""5 SAR'dan 3'ü çakýþtý. Fiyat üstte, YEÞÝL (Destek) elmas oluþtu.")
    alertcondition(trigger and not isSupport"Çakýþma: Direnç""5 SAR'dan 3'ü çakýþtý. Fiyat altta, KIRMIZI (Direnç) elmas oluþtu.")
    //////////////
    // ─────────────────────────────────────────────────────────────────
    //  1. GÝRDÝLER
    // ─────────────────────────────────────────────────────────────────
    volLength   input.int(20,  "Oynaklýk Uzunluðu"minval 5)
    projBars    input.int(5,   "Ýleriye Projeksiyon (Mum Yakýnlýðý)"minval 1
    barsPerYear input.int(50,  "Yýllýk Mum Çarpaný"minval 10)

    // ─────────────────────────────────────────────────────────────────
    //  2. YÖN TAYÝNÝ (0.02 - 0.02 - 0.2 SAR)
    // ─────────────────────────────────────────────────────────────────
    // Belirttiðiniz deðerlerle klasik SAR motoru
    hedefSar ta.sar(0.020.020.2)
    isLong   close hedefSar

    // SAR'ý grafikte göster (yönü teyit etmek için þeffaf bir haç olarak)
    plot(hedefSar"SAR"color=isLong color.new(color.white00) : color.new(color.white0), style=plot.style_crosslinewidth=1)

    // ─────────────────────────────────────────────────────────────────
    //  3. ÝSTATÝSTÝKSEL VOLATÝLÝTE (%68) VE HEDEFLER
    // ─────────────────────────────────────────────────────────────────
    // Logaritmik getiri ve volatilite hesaplamasý
    logReturn math.log(close nz(close[1], close))
    rawVol    ta.stdev(logReturnvolLength)
    annualVol rawVol math.sqrt(barsPerYear)

    // Koni formülü (Belirli bir zaman t sonrasýndaki tahmini sapma)
    conePrice(float basePricefloat volint tfloat sigmaMultiplierint direction) =>
        
    drift direction sigmaMultiplier vol math.sqrt(float(t) / float(barsPerYear))
        
    basePrice math.exp(drift)

    var 
    label[] sigmaLabels = array.new<label>()
    var 
    line[]  sigmaLines  = array.new<line>()

    // Sadece aktif (son) barda projeksiyonu hesapla ve çiz
    if barstate.islast
        
    // Eski etiket ve çizgileri temizle
        
    if sigmaLabels.size() > 0
            
    for 0 to sigmaLabels.size() - 1
                label
    .delete(sigmaLabels.get(i))
                
    line.delete(sigmaLines.get(i))
            
    sigmaLabels.clear()
            
    sigmaLines.clear()

        
    // 1 Standart Sapma (%68 olasýlýk) fiyat seviyeleri
        
    float tip1up conePrice(closeannualVolprojBars1.0,  1)
        
    float tip1dn conePrice(closeannualVolprojBars1.0, -1)
        
    int tipX bar_index projBars 

        
    // SAR Yönüne göre hedef belirle, etiket ve kýlavuz çizgi at
        
    if isLong
            sigmaLabels
    .push(label.new(tipXtip1up"(YTD. @yörük@)\n" str.tostring(tip1upformat.mintick), color=color.new(color.lime80), textcolor=color.limestyle=label.style_label_leftsize=size.small))
            
    sigmaLines.push(line.new(bar_indexclosetipXtip1upcolor=color.new(color.lime50), style=line.style_dotted))
        else
            
    sigmaLabels.push(label.new(tipXtip1dn"(YTD. @yörük@)\n" str.tostring(tip1dnformat.mintick), color=color.new(color.red80), textcolor=color.redstyle=label.style_label_leftsize=size.small))
            
    sigmaLines.push(line.new(bar_indexclosetipXtip1dncolor=color.new(color.red50), style=line.style_dotted))
    //////////////////

    // ─────────────────────────────────────────────────────────────────
    //  1. OTONOM ZAMAN DÝLÝMÝ (SABÝT BELLEK KÝLÝDÝ)
    // ─────────────────────────────────────────────────────────────────
    // Çarpanlar ve Zýrh ana uzunluðu
    simple int z_len = switch timeframe.period
        
    "1"   => 34
        
    "3"   => 21
        
    "5"   => 13
        
    "15"  => 8
        
    "60"  => 5
        
    "240" => 3
        
    => 2

    // ─────────────────────────────────────────────────────────────────
    //  2. 7 KATMANLI FRAKTAL MATRÝS (HMA vs ALMA)
    // ─────────────────────────────────────────────────────────────────
    src hlc3

    // Her katmanda HMA (Kýlýç) ve ALMA (Zýrh) çarpýþýr, aradaki mesafe (Ývme) ölçülür
    f_titan_dalga(_f_s) => ta.hma(src_f) - ta.alma(src_s0.856)

    // Fraktal Fibonacci Katmanlarý
    ao1 f_titan_dalga(256)
    ao2 f_titan_dalga(358)
    ao3 f_titan_dalga(560)
    ao4 f_titan_dalga(863)
    ao5 f_titan_dalga(1368)
    ao6 f_titan_dalga(2176)
    ao7 f_titan_dalga(3489)

    // ─────────────────────────────────────────────────────────────────
    //  3. SÜPERPOZÝSYON (MASTER DALGA) VE KÝNETÝK EVRELER
    // ─────────────────────────────────────────────────────────────────
    // 7 Katmanýn toplam gücü
    float master_wave = (ao1 ao2 ao3 ao4 ao5 ao6 ao7) / 7

    // Master Dalga'nýn 4 Kinetik Evresi
    bool guclu_boga   master_wave and master_wave master_wave[1]
    bool yorulan_boga master_wave and master_wave <= master_wave[1]
    bool guclu_ayi    master_wave and master_wave master_wave[1]
    bool yorulan_ayi  master_wave and master_wave >= master_wave[1]

    // Kinetik Renk Paleti (Mumlar için)
    color dalga_rengi guclu_boga color.new(#00ffaa, 0) : yorulan_boga ? color.new(#eafa03, 0) : guclu_ayi ? color.new(#ff0055, 0) : yorulan_ayi ? color.new(#c604ed, 0) : color.gray

    // ─────────────────────────────────────────────────────────────────
    //  4. FÝYATA PROJEKSÝYON (MUM BOYAMA VE OMURGA)
    // ─────────────────────────────────────────────────────────────────
    // Bütün zekâyý mumlarýn gövdesine aktarýyoruz
    barcolor(dalga_rengi)

    // Fiyatýn ortasýndan geçen referans Gauss Zýrhý (Trendi görsel tutmak için)
    omurga ta.alma(src550.856)
    //plot(omurga, "Yörük", color=color.new(dalga_rengi, 0), linewidth=1)

    // ─────────────────────────────────────────────────────────────────

    // ─────────────────────────────────────────────────────────────────

    h_start input.float(0.06"Hýzlý SAR Baþlangýç"step=0.01group="Yin-Yang SAR")
    h_inc   input.float(0.06"Hýzlý SAR Ývme"step=0.01group="Yin-Yang SAR")
    h_max   input.float(0.30"Hýzlý SAR Max"step=0.1group="Yin-Yang SAR")




    f_ozel_sar(src_hsrc_l_start_inc_max_reset_hiz) =>
        var 
    int trend 0
        
    var float sar_val 0.0
        
    var float ep 0.0
        
    var float af 0.0

        
    if trend == and not na(src_h[1])
            
    trend   := src_h >= src_h[1] or src_l >= src_l[1] ? : -1
            sar_val 
    := trend src_l[1] : src_h[1]
            
    ep      := trend src_h[1] : src_l[1]
            
    af      := _start
        
    else 
            if 
    _reset_hiz
                af 
    := _start

            float nextsar 
    sar_val
            
    if trend 0
                
    if src_h[1] > ep
                    ep 
    := src_h[1]
                    
    af := math.min(_maxaf _inc)
                
    nextsar := sar_val af * (ep sar_val)
                
    nextsar := math.min(math.min(src_l[1], src_l[2]), nextsar)
                if 
    nextsar src_l
                    trend   
    := -1
                    nextsar 
    := ep
                    ep      
    := src_l
                    af      
    := _start
            
    else 
                if 
    src_l[1] < ep
                    ep 
    := src_l[1]
                    
    af := math.min(_maxaf _inc)
                
    nextsar := sar_val af * (ep sar_val)
                
    nextsar := math.max(math.max(src_h[1], src_h[2]), nextsar)
                if 
    nextsar src_h
                    trend   
    := 1
                    nextsar 
    := ep
                    ep      
    := src_h
                    af      
    := _start
            sar_val 
    := nextsar
        
    [sar_valtrend]

    yeni_gun ta.change(time("D")) != 0

    [sar_hizlitrend_hizli] = f_ozel_sar(highlowh_starth_inch_maxyeni_gun)
    ayna_hizli trend_hizli close math.abs(close sar_hizli) : close math.abs(close sar_hizli)


    // 3. Trend Çizgisi (Hýzlý Ayna)
    color col_hizli = (ayna_hizli close) ? color.lime color.red
    plot
    (ayna_hizlititle="Ayna"color=col_hizlistyle=plot.style_linelinewidth=1)

    /////////////////// 
    16.07.2024 - 10.12.2024

Sayfa 402/402 ÝlkÝlk ... 302352392400401402

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
  •