Artan

35,20 10 18:10
18,81 10 18:10
3,63 10 18:10
46,46 9.99 18:10
349,75 9.98 18:10
Artan Hisseler

Azalan

3.240.000,00 -10 18:10
425,25 -10 18:10
3,52 -9.97 18:10
30,70 -9.97 18:10
34,12 -9.97 18:10
Azalan Hisseler

İşlem

13.970.723.188,18 18:10
13.497.889.288,75 18:10
13.310.583.928,75 18:10
9.149.578.845,90 18:10
8.507.414.847,66 18:10
Tüm Hisseler
Sayfa 357/357 İlkİlk ... 257307347355356357
Arama sonucu : 2856 madde; 2,849 - 2,856 arası.

Konu: Tradingview

  1. 16.07.2024 - 10.12.2024

  2. asels 289 üzeri 290 hareket ederse...vadeli 14114 e gidebilir.
    sonrası long devam gibi.
    16.07.2024 - 10.12.2024

  3. https://www.tradingview.com/x/iXX3y0uH/ kırılım geliyor...82 kırılınca...
    https://www.tradingview.com/x/YZ35z20a/ 107 cepte olur ki...al verir...

    https://www.tradingview.com/x/RGpOfdZ2/ saatlik düzeltme onayı olmuş gibi olabilir....

    14010 ile 13910 ise trend değişimi yapar...
    16.07.2024 - 10.12.2024

  4. 16.07.2024 - 10.12.2024



  5. 16.07.2024 - 10.12.2024

  6. kombine kod denemesi.....

    örnek görüntü.... https://www.tradingview.com/x/JsZz92iL/

    kod yazarlarının değerleri oynanmadan.... birleştirilmiş hali.... denemek isteyenler için....

    PHP Code:
    //@version=6
    indicator('EĞİTİM ÇALIŞMASIDIR. ASLA YATIRIM TAVSİYESİ OLARAK KULLANILAMAZ. YATIRIM TAVSİYESİ DEĞİLDİR. @yörük@ 2026'overlay truemax_lines_count 500max_boxes_count 500)

    // --- 1. VISUAL SETTINGS ---
    i_boxColor input.color(color.new(#787b86, 92), 'Range Background', group = 'Visuals')
    i_gpBullishColor input.color(color.new(#4caf50, 60), 'Bullish GP Color', group = 'Visuals')
    i_gpBearishColor input.color(color.new(#f44336, 60), 'Bearish GP Color', group = 'Visuals')
    i_liqColor input.color(color.new(#ffeb3b, 85), 'Liquidity Zones Color', group = 'Visuals')
    i_lineColor input.color(color.white'Boundary Line Color'group 'Visuals')
    i_whiteText color.white

    // Range Settings
    i_autoFit input.bool(true'Auto-Fit Box to last high and low'group 'Range Settings')
    i_lookback input.int(100'Lookback Period'minval 2group 'Range Settings')
    i_offsetR input.int(10'Box Offset Right'minval 0group 'Range Settings')

    // FVG Settings
    i_showFVG input.bool(true'Show Fair Value Gaps (FVG)'group 'FVG Settings')
    i_fvgLen input.int(10'FVG Extension (Bars)'minval 1group 'FVG Settings')
    i_bullFVGColor input.color(color.new(#4caf4f, 100), 'Bullish FVG Color', group = 'FVG Settings')
    i_bearFVGColor input.color(color.new(#f44336, 100), 'Bearish FVG Color', group = 'FVG Settings')

    i_showLabels input.bool(true'Show Price Lines & Labels'group 'Visuals')

    // --- 2. CORE CALCULATIONS ---
    int hOff ta.highestbars(highi_lookback)
    int lOff ta.lowestbars(lowi_lookback)

    float rHigh high[-hOff]
    float rLow low[-lOff]
    float rDiff rHigh rLow

    // KORREKTUR: anchorBar nutzt nun die korrekten Identifier lOff und hOff
    int anchorBar i_autoFit bar_index math.min(hOfflOff) : bar_index i_lookback

    float bUp 
    rLow rDiff 0.382
    float bLo 
    rLow rDiff 0.35
    float sUp 
    rHigh rDiff 0.35
    float sLo 
    rHigh rDiff 0.382

    // --- 3. FVG LOGIC ---
    if i_showFVG
        
    if low high[2]
            
    box.new(bar_index[1], lowbar_index i_fvgLenhigh[2], bgcolor i_bullFVGColorborder_color na)
        if 
    high low[2]
            
    box.new(bar_index[1], highbar_index i_fvgLenlow[2], bgcolor i_bearFVGColorborder_color na)

    // --- 4. VISUALS (BOXES) ---
    var box b_Range box.new(nanananaxloc xloc.bar_indexbgcolor i_boxColorborder_color color.gray)
    var 
    box b_Bullish box.new(nanananaxloc xloc.bar_indexbgcolor i_gpBullishColorborder_color natext 'LONG ALAN'text_color color.whitetext_size size.small)
    var 
    box b_Bearish box.new(nanananaxloc xloc.bar_indexbgcolor i_gpBearishColorborder_color natext 'SHORT ALAN'text_color color.whitetext_size size.small)
    var 
    box b_LiqTop box.new(nanananaxloc xloc.bar_indexbgcolor i_liqColorborder_color natext ' SHORT STOP ALAN'text_color i_whiteTexttext_size size.small)
    var 
    box b_LiqBot box.new(nanananaxloc xloc.bar_indexbgcolor i_liqColorborder_color natext 'LONG STOP ALAN'text_color i_whiteTexttext_size size.small)

    var array<
    linel_levels = array.new_line()
    var array<
    labellb_prices = array.new_label()

    if 
    barstate.isfirst
        
    for 0 to 7 by 1
            
    array.push(l_levelsline.new(nanananaxloc xloc.bar_indexcolor i_lineColor))
            array.
    push(lb_priceslabel.new(nana''xloc xloc.bar_indexcolor color.new(color.black100), textcolor i_lineColorsize size.normalstyle label.style_label_left))

    if 
    barstate.islast
        int rightBar 
    bar_index i_offsetR
        box
    .set_lefttop(b_RangeanchorBarrHigh)
        
    box.set_rightbottom(b_RangerightBarrLow)
        
    box.set_lefttop(b_BullishanchorBarbUp)
        
    box.set_rightbottom(b_BullishrightBarbLo)
        
    box.set_lefttop(b_BearishanchorBarsUp)
        
    box.set_rightbottom(b_BearishrightBarsLo)
        
    box.set_lefttop(b_LiqTopanchorBarrHigh)
        
    box.set_rightbottom(b_LiqToprightBarrHigh rDiff 0.05)
        
    box.set_lefttop(b_LiqBotanchorBarrLow rDiff 0.05)
        
    box.set_rightbottom(b_LiqBotrightBarrLow)

        if 
    i_showLabels
            
    array<floatp_vals = array.from(rHighrHigh rDiff 0.05sUpsLobUpbLorLow rDiff 0.05rLow)
            for 
    0 to 7 by 1
                float v 
    = array.get(p_valsi)
                
    line.set_xy1(array.get(l_levelsi), anchorBarv)
                
    line.set_xy2(array.get(l_levelsi), rightBarv)
                
    label.set_xy(array.get(lb_pricesi), rightBarv)
                
    label.set_text(array.get(lb_pricesi), ' ' str.tostring(vformat.mintick))

    // --- 5. SIGNAL LOGIC ---
    bool sfpShort high rHigh and close rHigh
    bool sfpLong 
    low rLow and close rLow

    var bool tBear false
    var bool tBull false
    if high >= sLo and low <= sUp
        tBear 
    := true
        tBear
    if low <= bUp and high >= bLo
        tBull 
    := true
        tBull

    bool pL 
    close[2] < open[2] and close[1] > open[1] and close high[1]
    bool pS close[2] > open[2] and close[1] < open[1] and close low[1]

    bool signalLongOnly tBull and pL
    bool signalShortOnly 
    tBear and pS

    if signalShortOnly or tBear and high rHigh
        tBear 
    := false
        tBear
    if signalLongOnly or tBull and low rLow
        tBull 
    := false
        tBull

    // --- 6. ALERTS ---
    alertcondition(ta.crossover(highsLo) or ta.crossunder(lowbUp), '1. GP Touch''Price entered Golden Pocket.')
    alertcondition(signalLongOnly'2. Long: 2-Candle Pattern''Long confirmed in BULLISH GP.')
    alertcondition(signalShortOnly'3. Short: 2-Candle Pattern''Short confirmed in BEARISH GP.')
    alertcondition(sfpLong'4. SFP Long (Liquidity Grab)''SFP: Liquidity grab below Low.')
    alertcondition(sfpShort'5. SFP Short (Liquidity Grab)''SFP: Liquidity grab above High.')
    /////////////////////////

    // ─────────────────────────────
    // SETTINGS
    // ─────────────────────────────
    grp_logic "Logic Settings"
    backBars      input.int(300"Bars to Apply"minval 50group grp_logictooltip "Historical bars scanned for pivots.")
    pivotSrc      input.string("High/Low""Pivot Source"options = ["High/Low""Close"], group grp_logic)
    pivotStrength input.int(10"Pivot Strength"minval 5maxval 15group grp_logictooltip "Range limited to 5-15.")
    minTouches    input.int(3"Min Pivot Confirmation"minval 2maxval 8group grp_logictooltip "Range limited to 2-8.")

    grp_style "Styling"
    resColor  input.color(color.red"Resistance Color"group grp_style)
    supColor  input.color(color.green"Support Color"group grp_style)
    transpSR  input.int(50"Zone Transparency"minval 0maxval 100group grp_style)

    // ─────────────────────────────
    // INTERNAL CONSTANTS (Hidden Settings)
    // ─────────────────────────────
    float FIXED_ATR_MULT 0.5   // Fixed Zone Width
    int   FIXED_STABILITY 5    // Fixed Stability Buffer (Bars)

    // ─────────────────────────────
    // DATA STORAGE
    // ─────────────────────────────
    float atr ta.atr(14)
    float maxThreshold atr FIXED_ATR_MULT

    float srcHigh 
    pivotSrc == "Close" close high
    float srcLow  
    pivotSrc == "Close" close low

    var float[] phPrices = array.new_float(0)
    var 
    int[]   phBarIdx = array.new_int(0)
    var 
    float[] plPrices = array.new_float(0)
    var 
    int[]   plBarIdx = array.new_int(0)

    var 
    line[] allLines = array.new_line(0)
    var 
    linefill[] allFills = array.new_linefill(0)

    // Alert States
    var int[] zoneStates = array.from(00
    var 
    float[] zoneTops = array.from(0.00.0)
    var 
    float[] zoneBots = array.from(0.00.0)

    // ─────────────────────────────
    // PIVOT COLLECTION
    // ─────────────────────────────
    ph ta.pivothigh(srcHighpivotStrengthpivotStrength)
    pl ta.pivotlow(srcLowpivotStrengthpivotStrength

    if 
    not na(ph)
        array.
    push(phPricesph)
        array.
    push(phBarIdxbar_index pivotStrength)
    if 
    not na(pl)
        array.
    push(plPricespl)
        array.
    push(plBarIdxbar_index pivotStrength)

    // ─────────────────────────────
    // FILTERING & DRAWING LOGIC
    // ─────────────────────────────
    clearDrawings() =>
        if array.
    size(allLines) > 0
            
    for l in allLines
                line
    .delete(l)
            array.
    clear(allLines)
        if array.
    size(allFills) > 0
            
    for f in allFills
                linefill
    .delete(f)
            array.
    clear(allFills)

    findClosestZone(float[] pPricesint[] pIndicescolor colbool isResistance) =>
        
    int size = array.size(pPrices)
        
    int lookbackThreshold last_bar_index backBars
        int stabilityThreshold 
    last_bar_index FIXED_STABILITY
        
        
    // Logic: Look for the zone with the smallest distance to the current price
        
    float minDistanceToPrice 1e10 
        
        
    // Variables to store the winner
        
    int   bestP1x       0
        float bestP1y       
    0.0
        float bestSlopeVal  
    0.0
        float bestMaxUp     
    0.0
        float bestMaxDown   
    0.0
        bool  foundAny      
    false

        
    if size >= minTouches
            
    for 0 to size 2
                
    if array.get(pIndicesi) < lookbackThreshold
                    
    continue
                
                
    float p1_y = array.get(pPricesi)
                
    int   p1_x = array.get(pIndicesi)
                
                for 
    1 to size 1
                    float p2_y 
    = array.get(pPricesj)
                    
    int   p2_x = array.get(pIndicesj)
                    
    float currentSlope = (p2_y p1_y) / (p2_x p1_x)
                    
                    
    int touches 0
                    bool isBroken 
    false
                    float currentMaxUp 
    0.0
                    float currentMaxDown 
    0.0
                    
                    
    for 0 to size 1
                        int pk_x 
    = array.get(pIndicesk)
                        if 
    pk_x p1_x 
                            
    continue
                            
                        
    float pk_y = array.get(pPricesk)
                        
    float expected_y p1_y currentSlope * (pk_x p1_x)
                        
    float diff pk_y expected_y
                        
                        
    if math.abs(diff) <= maxThreshold
                            touches 
    += 1
                            
    if diff currentMaxUp 
                                currentMaxUp 
    := diff
                            
    if diff currentMaxDown 
                                currentMaxDown 
    := diff
                        
                        
    // Stability Breach Logic: Only discard if breach is OLDER than fixed buffer (5 bars)
                        
    if pk_x stabilityThreshold
                            
    if isResistance and diff maxThreshold
                                isBroken 
    := true
                                
    break
                            if 
    not isResistance and diff < -maxThreshold
                                isBroken 
    := true
                                
    break

                    if 
    touches >= minTouches and not isBroken
                        
    // CALCULATE DISTANCE TO CURRENT PRICE
                        
    float current_projected_y p1_y currentSlope * (last_bar_index p1_x)
                        
    float dist math.abs(current_projected_y close)
                        
                        
    // IF this valid line is CLOSER than the previous best, keep it
                        
    if dist minDistanceToPrice
                            minDistanceToPrice 
    := dist
                            bestP1x      
    := p1_x
                            bestP1y      
    := p1_y
                            bestSlopeVal 
    := currentSlope
                            bestMaxUp    
    := currentMaxUp
                            bestMaxDown  
    := currentMaxDown
                            foundAny     
    := true

        
    if foundAny
            float endY 
    bestP1y bestSlopeVal * (last_bar_index bestP1x)
            
    l_top line.new(bestP1xbestP1y bestMaxUplast_bar_indexendY bestMaxUpcolor=color.new(col50), extend=extend.right)
            
    l_bot line.new(bestP1xbestP1y bestMaxDownlast_bar_indexendY bestMaxDowncolor=color.new(col50), extend=extend.right)
            
    fill  linefill.new(l_topl_botcolor.new(coltranspSR))
            
            array.
    push(allLinesl_top)
            array.
    push(allLinesl_bot)
            array.
    push(allFillsfill)
            
            
    int idx isResistance 1
            
    array.set(zoneTopsidxendY bestMaxUp)
            array.
    set(zoneBotsidxendY bestMaxDown)
        
    foundAny

    // Execute
    clearDrawings()
    findClosestZone(phPricesphBarIdxresColortrue)
    findClosestZone(plPricesplBarIdxsupColorfalse)

    // ─────────────────────────────
    // ALERT LOGIC
    // ─────────────────────────────
    bool alertBreakout false
    bool alertTouch    
    false

    checkAlerts
    (int idx) =>
        
    float top = array.get(zoneTopsidx)
        
    float bot = array.get(zoneBotsidx)
        
    int prevState = array.get(zoneStatesidx)
        
    bool bOut false
        bool tCh 
    false
        
    if top 0
            
    if close top
                
    if prevState == -
                    bOut 
    := true
                
    array.set(zoneStatesidx1)
            else if 
    close bot
                
    if prevState == 
                    bOut 
    := true
                
    array.set(zoneStatesidx, -1)
            if (
    high >= bot and high <= top) or (low <= top and low >= bot)
                
    tCh := true
        
    [bOuttCh]

    [
    rBrT] = checkAlerts(0)
    [
    sBsT] = checkAlerts(1)
    alertBreakout := rB or sB
    alertTouch    
    := rT or sT

    alertcondition
    (alertBreakout"Zone Breakout""Price broke the zone")
    alertcondition(alertTouch"Zone Touch""Price touched the zone")
    //////////////////////

    // -----------------------------------------------------------------------------
    // SETTINGS
    // -----------------------------------------------------------------------------
    grp_sett "General Settings"
    len        input.int(5"Short-Term Sensitivity"minval=2group=grp_sett)
    color_up   input.color(#089981, "Historical Wave Color", group=grp_sett)

    grp_cast "Short-Term Forecast"
    show_ext_bull input.bool(true"Show Bullish Extension (Up)"group=grp_cast)
    show_ext_bear input.bool(true"Show Bearish Extension (Down)"group=grp_cast)
    color_cont    input.color(#ff9800, "Extension Color", group=grp_cast)

    link_scenarios input.bool(false"Start Reversal after Extension?"group=grp_cast)

    show_reversal input.bool(true"Show Reversal"group=grp_cast)
    color_rev     input.color(#2962ff, "Reversal Color", group=grp_cast)

    grp_macro "Long-Term Forecast (1 Year)"
    show_macro    input.bool(false"Show 1-Year Macro Projection"group=grp_macro)
    len_macro     input.int(21"Macro Sensitivity"minval=10group=grp_macro)
    macro_spacing input.int(50"Bars per Wave (Time)"minval=5group=grp_macro)
    color_macro   input.color(#9c27b0, "Macro Color", group=grp_macro)

    grp_vis   "Dashboard & Visuals"
    show_table  input.bool(true"Show Target Table"group=grp_vis)
    show_labels input.bool(true"Show Chart Labels"group=grp_vis)
    show_grid   input.bool(true"Show Horizontal Fib Levels"group=grp_vis)
    show_inv    input.bool(true"Show Invalidation Line"group=grp_vis)
    show_div    input.bool(true"Show RSI Divergence (⚡)"group=grp_vistooltip="Highlights setups where Price and RSI disagree (Divergence), indicating a stronger reversal signal.")

    // -----------------------------------------------------------------------------
    // STORAGE
    // -----------------------------------------------------------------------------
    var float[] pPrices = array.new_float()
    var 
    int[]   pBars   = array.new_int()
    var 
    bool[]  pDirs   = array.new_bool() 
    var 
    float[] pRSI    = array.new_float() // NEW: Store RSI values

    var float[] pPricesM = array.new_float()
    var 
    int[]   pBarsM   = array.new_int()
    var 
    bool[]  pDirsM   = array.new_bool()

    var 
    line[]  ghostLines  = array.new_line()
    var 
    label[] ghostLabels = array.new_label()
    var 
    table   infoTable   table.new(position.top_right420border_width 1)

    // -----------------------------------------------------------------------------
    // FUNCTIONS
    // -----------------------------------------------------------------------------
    // Updated to store RSI
    addPivot(float pint bbool dfloat rfloat[] pricesint[] barsbool[] dirsfloat[] rsis) =>
        array.
    unshift(pricesp)
        array.
    unshift(barsb)
        array.
    unshift(dirsd)
        array.
    unshift(rsisr// Store RSI
        
    if array.size(prices) > 20
            
    array.pop(prices)
            array.
    pop(bars)
            array.
    pop(dirs)
            array.
    pop(rsis)

    // Overload for Macro (no RSI tracking needed yet)
    addPivotMacro(float pint bbool dfloat[] pricesint[] barsbool[] dirs) =>
        array.
    unshift(pricesp)
        array.
    unshift(barsb)
        array.
    unshift(dirsd)
        if array.
    size(prices) > 20
            
    array.pop(prices)
            array.
    pop(bars)
            array.
    pop(dirs)

    drawPred(int t1float p1int t2float p2string txtstring fibcolor colint width) =>
        
    line.new(t1p1t2p2color=colstyle=line.style_dashedwidth=width)
        array.
    push(ghostLinesl)
        
        if 
    show_grid
            l_hor 
    line.new(t2p2t2 10p2color=color.new(col50), style=line.style_dottedwidth=1)
            array.
    push(ghostLinesl_hor)

        if 
    show_labels
            lbl_text 
    txt "\n" str.tostring(p2format.mintick)
            
    lb label.new(t2p2text=lbl_textcolor=color.new(color.white100), textcolor=colstyle=label.style_label_leftsize=size.small)
            array.
    push(ghostLabelslb)

    fillRow(int rstring tstring ffloat pcolor c) =>
        
    pct_diff = (close) / close 100
        pct_str  
    = (pct_diff "+" "") + str.tostring(pct_diff"#.##") + "%"
        
    pct_col  pct_diff >= #089981 : #f23645 
        
        
    table.cell(infoTable0rttext_color=color.whitebgcolor=ctext_size=size.small)
        
    table.cell(infoTable1rftext_color=color.whitebgcolor=color.new(c20), text_size=size.small)
        
    table.cell(infoTable2rstr.tostring(pformat.mintick), text_color=color.whitebgcolor=color.new(color.black20), text_size=size.small)
        
    table.cell(infoTable3rpct_strtext_color=pct_colbgcolor=color.new(color.black20), text_size=size.small)

    // -----------------------------------------------------------------------------
    // MAIN LOGIC
    // -----------------------------------------------------------------------------
    // Calculate RSI for Divergence Checks
    my_rsi ta.rsi(close14)

    ph77 ta.pivothigh(highlenlen)
    pl77 ta.pivotlow(lowlenlen)

    if 
    not na(ph77)
        
    // Pass RSI at the time of the pivot (offset by len)
        
    addPivot(ph77bar_index[len], truemy_rsi[len], pPricespBarspDirspRSI)
    if 
    not na(pl77)
        
    addPivot(pl77bar_index[len], falsemy_rsi[len], pPricespBarspDirspRSI)

    phM ta.pivothigh(highlen_macrolen_macro)
    plM ta.pivotlow(lowlen_macrolen_macro)

    if 
    not na(phM)
        
    addPivotMacro(phMbar_index[len_macro], truepPricesMpBarsMpDirsM)
    if 
    not na(plM)
        
    addPivotMacro(plMbar_index[len_macro], falsepPricesMpBarsMpDirsM)

    if (
    not na(ph77) or not na(pl77)) and array.size(pPrices) > 1
        p1_val 
    = array.get(pPrices0)
        
    p1_bar = array.get(pBars0)
        
    p2_val = array.get(pPrices1)
        
    p2_bar = array.get(pBars1)
        
    line.new(p2_barp2_valp1_barp1_valcolor=color_upwidth=2)

    // 3. PREDICTIVE LOGIC & TABLE
    if barstate.islast
        
    for l in ghostLines
            line
    .delete(l)
        for 
    lb in ghostLabels
            label
    .delete(lb)
        array.
    clear(ghostLines)
        array.
    clear(ghostLabels)
        
        
    table.clear(infoTable00319)
        
        if 
    show_table
            table
    .cell(infoTable00"Wave"bgcolor=color.graytext_color=color.white)
            
    table.cell(infoTable10"Fib"bgcolor=color.graytext_color=color.white)
            
    table.cell(infoTable20"Target"bgcolor=color.graytext_color=color.white)
            
    table.cell(infoTable30"% +/-"bgcolor=color.graytext_color=color.white)
        
        
    int tbl_row 

        
    if array.size(pPrices) > 0
            last_conf_val 
    = array.get(pPrices0)
            
    last_conf_bar = array.get(pBars0)
            
    last_conf_dir = array.get(pDirs0)
            
            
    int bars_elapsed bar_index last_conf_bar
            float live_pivot_val 
    0.0
            int   live_pivot_bar 
    0
            bool  live_pivot_dir 
    bool(na)
            
    float live_pivot_rsi 50.0 // Default
            
            
    if last_conf_dir 
                lowest_val 
    1000000.0
                lowest_idx 
    0
                
    for 0 to bars_elapsed
                    
    if low[i] < lowest_val
                        lowest_val 
    := low[i]
                        
    lowest_idx := bar_index[i]
                        
    live_pivot_rsi := my_rsi[i// Capture RSI at lowest point
                
    live_pivot_val := lowest_val
                live_pivot_bar 
    := lowest_idx
                live_pivot_dir 
    := false 
            
    else 
                
    highest_val 0.0
                highest_idx 
    0
                
    for 0 to bars_elapsed
                    
    if high[i] > highest_val
                        highest_val 
    := high[i]
                        
    highest_idx := bar_index[i]
                        
    live_pivot_rsi := my_rsi[i// Capture RSI at highest point
                
    live_pivot_val := highest_val
                live_pivot_bar 
    := highest_idx
                live_pivot_dir 
    := true 

            float vol 
    math.abs(last_conf_val live_pivot_val)
            if 
    vol == 
                vol 
    := syminfo.mintick 100

            float rev_start_price 
    live_pivot_val
            int   rev_start_bar   
    live_pivot_bar
            
            
    // =========================================================
            // SCENARIO 1: EXTENSION
            // =========================================================
            
    float pExt na
            int   tExt 
    bar_index 10
            bool  drawing_ext 
    false

            
    if not live_pivot_dir 
                
    if show_ext_bear
                    calc_price 
    live_pivot_val - (vol 0.5)
                    
    pExt := math.max(0.01calc_price)
                    
    drawPred(live_pivot_barlive_pivot_valtExtpExt"(Ext)""0.5"color_cont2)
                    if 
    show_table
                        fillRow
    (tbl_row"Bear Ext""0.5 Vol"pExtcolor_cont)
                        
    tbl_row += 1
                    drawing_ext 
    := true
            
    else 
                if 
    show_ext_bull
                    pExt 
    := live_pivot_val + (vol 0.5)
                    
    drawPred(live_pivot_barlive_pivot_valtExtpExt"(Ext)""0.5"color_cont2)
                    if 
    show_table
                        fillRow
    (tbl_row"Bull Ext""0.5 Vol"pExtcolor_cont)
                        
    tbl_row += 1
                    drawing_ext 
    := true

            
    if link_scenarios and drawing_ext
                rev_start_price 
    := pExt
                rev_start_bar   
    := tExt

            
    // =========================================================
            // SCENARIO 2: REVERSAL + RSI DIVERGENCE CHECK
            // =========================================================
            
    if show_reversal
                int t_step 
    5
                
                
    // --- RSI DIVERGENCE LOGIC ---
                
    bool has_div false
                
    // Check if we have history
                
    if array.size(pPrices) > 1
                    
    // If Live is Low, compare to Previous Low (index 1)
                    
    if not live_pivot_dir 
                        prev_low_val 
    = array.get(pPrices1)
                        
    prev_low_rsi = array.get(pRSI1)
                        
    // BULLISH DIV: Lower Price + Higher RSI
                        
    if live_pivot_val prev_low_val and live_pivot_rsi prev_low_rsi
                            has_div 
    := true
                    
    // If Live is High, compare to Previous High (index 1)
                    
    else 
                        
    prev_high_val = array.get(pPrices1)
                        
    prev_high_rsi = array.get(pRSI1)
                        
    // BEARISH DIV: Higher Price + Lower RSI
                        
    if live_pivot_val prev_high_val and live_pivot_rsi prev_high_rsi
                            has_div 
    := true

                
    // Invalidation Line
                
    if show_inv
                    inv_col 
    color.red
                    inv_y   
    rev_start_price
                    l_inv   
    line.new(rev_start_barinv_yrev_start_bar 30inv_ycolor=inv_colwidth=2style=line.style_solid)
                    array.
    push(ghostLinesl_inv)
                    
                    
    // Add Lightning Bolt if Divergence Detected
                    
    inv_txt "INV" + (has_div and show_div " ⚡" "")
                    
    inv_txt_col has_div and show_div color.yellow inv_col
                    
                    
    if show_labels
                        lb_inv 
    label.new(rev_start_bar 30inv_ytext=inv_txtcolor=color.new(color.white100), textcolor=inv_txt_colstyle=label.style_label_leftsize=size.small)
                        array.
    push(ghostLabelslb_inv)
                    
                    if 
    show_table
                        fillRow
    (tbl_row"INVALIDATION", (has_div and show_div "DIV ⚡" "Start"), inv_ycolor.red)
                        
    tbl_row += 1

                
    if not live_pivot_dir 
                    p1 
    math.max(0.01rev_start_price + (vol 0.382))
                    
    t1 rev_start_bar 
                    drawPred
    (rev_start_barrev_start_pricet1p1"(1)""0.382"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave 1""0.382"p1color_rev)
                        
    tbl_row += 1
                    
                    p2 
    math.max(0.01p1 - ((p1 rev_start_price) * 0.618))
                    
    t2 t1 t_step
                    drawPred
    (t1p1t2p2"(2)""0.618"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave 2""0.618"p2color_rev)
                        
    tbl_row += 1
                    
                    p3 
    math.max(0.01p2 + ((p1 rev_start_price) * 1.618))
                    
    t3 t2 t_step
                    drawPred
    (t2p2t3p3"(3)""1.618"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave 3""1.618"p3color_rev)
                        
    tbl_row += 1

                    p4 
    math.max(0.01p3 - ((p3 p2) * 0.382))
                    
    t4 t3 t_step
                    drawPred
    (t3p3t4p4"(4)""0.382"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave 4""0.382"p4color_rev)
                        
    tbl_row += 1

                    p5 
    math.max(0.01p4 + (p1 rev_start_price))
                    
    t5 t4 t_step
                    drawPred
    (t4p4t5p5"(5)""1.0"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave 5""1.0"p5color_rev)
                        
    tbl_row += 1
                    
                
    else 
                    
    pA math.max(0.01rev_start_price - (vol 0.382))
                    
    tA rev_start_bar 5
                    drawPred
    (rev_start_barrev_start_pricetApA"(A)""0.382"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave A""0.382"pAcolor_rev)
                        
    tbl_row += 1

                    pB 
    math.max(0.01pA + ((rev_start_price pA) * 0.618))
                    
    tB tA t_step
                    drawPred
    (tApAtBpB"(B)""0.618"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave B""0.618"pBcolor_rev)
                        
    tbl_row += 1

                    pC 
    math.max(0.01pB - ((rev_start_price pA) * 1.272))
                    
    tC tB t_step
                    drawPred
    (tBpBtCpC"(C)""1.272"color_rev2)
                    if 
    show_table
                        fillRow
    (tbl_row"Wave C""1.272"pCcolor_rev)
                        
    tbl_row += 1

        
    // =========================================================
        // SCENARIO 3: MACRO
        // =========================================================
        
    if show_macro and array.size(pPricesM) > 0
            last_M_val 
    = array.get(pPricesM0)
            
    last_M_bar = array.get(pBarsM0)
            
    last_M_dir = array.get(pDirsM0)
            
            
    int M_elapsed bar_index last_M_bar
            float live_M_val 
    0.0
            int   live_M_bar 
    0
            bool  live_M_dir 
    bool(na)
            
            if 
    last_M_dir 
                lowest_val 
    1000000.0
                lowest_idx 
    0
                
    for 0 to M_elapsed
                    
    if low[i] < lowest_val
                        lowest_val 
    := low[i]
                        
    lowest_idx := bar_index[i]
                
    live_M_val := lowest_val
                live_M_bar 
    := lowest_idx
                live_M_dir 
    := false 
            
    else 
                
    highest_val 0.0
                highest_idx 
    0
                
    for 0 to M_elapsed
                    
    if high[i] > highest_val
                        highest_val 
    := high[i]
                        
    highest_idx := bar_index[i]
                
    live_M_val := highest_val
                live_M_bar 
    := highest_idx
                live_M_dir 
    := true 

            float volM 
    math.abs(last_M_val live_M_val)
            if 
    volM == 
                volM 
    := syminfo.mintick 100

            int t_step_M 
    macro_spacing
            
            
    if show_table
                table
    .cell(infoTable0tbl_row"MACRO (1Y)"bgcolor=color.graytext_color=color.white)
                
    table.merge_cells(infoTable0tbl_row3tbl_row)
                
    tbl_row += 1

            
    if not live_M_dir 
                p1 
    math.max(0.01live_M_val + (volM 0.382))
                
    t1 live_M_bar t_step_M
                drawPred
    (live_M_barlive_M_valt1p1"M(1)""Start"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro 1""Start"p1color_macro)
                    
    tbl_row += 1
                
                p2 
    math.max(0.01p1 - ((p1 live_M_val) * 0.618))
                
    t2 t1 t_step_M
                drawPred
    (t1p1t2p2"M(2)""0.618"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro 2""0.618"p2color_macro)
                    
    tbl_row += 1
                
                p3 
    math.max(0.01p2 + ((p1 live_M_val) * 1.618))
                
    t3 t2 t_step_M
                drawPred
    (t2p2t3p3"M(3)""1.618"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro 3""1.618"p3color_macro)
                    
    tbl_row += 1

                p4 
    math.max(0.01p3 - ((p3 p2) * 0.382))
                
    t4 t3 t_step_M
                drawPred
    (t3p3t4p4"M(4)""0.382"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro 4""0.382"p4color_macro)
                    
    tbl_row += 1

                p5 
    math.max(0.01p4 + (p1 live_M_val))
                
    t5 t4 t_step_M
                drawPred
    (t4p4t5p5"M(5)""1.0"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro 5""1.0"p5color_macro)
                    
    tbl_row += 1
                
            
    else 
                
    pA math.max(0.01live_M_val - (volM 0.382))
                
    tA live_M_bar t_step_M
                drawPred
    (live_M_barlive_M_valtApA"M(A)""Start"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro A""Start"pAcolor_macro)
                    
    tbl_row += 1

                pB 
    math.max(0.01pA + ((live_M_val pA) * 0.618))
                
    tB tA t_step_M
                drawPred
    (tApAtBpB"M(B)""0.618"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro B""0.618"pBcolor_macro)
                    
    tbl_row += 1

                pC 
    math.max(0.01pB - ((live_M_val pA) * 1.272))
                
    tC tB t_step_M
                drawPred
    (tBpBtCpC"M(C)""1.272"color_macro4)
                if 
    show_table
                    fillRow
    (tbl_row"Macro C""1.272"pCcolor_macro)
                    
    tbl_row += 
    16.07.2024 - 10.12.2024

Sayfa 357/357 İlkİlk ... 257307347355356357

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
  •