Bitcoin

CRT HAB

101
//version=5
indicator("CRT SNIPER PRO", overlay=true)

// ================= INPUT =================
fastEMA = input.int(20, "EMA Cepat")
slowEMA = input.int(100, "EMA Besar")
wickRatio = input.float(1.5, "CRT Wick")
atrMult = input.float(1.2, "ATR SL")
probFilter = input.float(0.6, "Probability")

// ================= TREND =================
emaFast = ta.ema(close, fastEMA)
emaSlow = ta.ema(close, slowEMA)

plot(emaFast, color=color.yellow)
plot(emaSlow, color=color.blue)

uptrend = emaFast > emaSlow
downtrend = emaFast < emaSlow

// ================= CRT =================
body = math.abs(close - open)
upperWick = high - math.max(close, open)
lowerWick = math.min(close, open) - low

bullCRT = lowerWick > body * wickRatio
bearCRT = upperWick > body * wickRatio

// ================= LIQUIDITY SWEEP =================
liqHigh = high > ta.highest(high, 10)[1]
liqLow = low < ta.lowest(low, 10)[1]

// ================= MARKET STRUCTURE =================
bosUp = close > ta.highest(high, 15)[1]
bosDown = close < ta.lowest(low, 15)[1]

// ================= ATR =================
atr = ta.atr(14)
buySL = close - atr * atrMult
sellSL = close + atr * atrMult

// ================= PROBABILITY FILTER =================
probBuy = (bullCRT ? 0.3 : 0) + (liqLow ? 0.3 : 0) + (uptrend ? 0.4 : 0)
probSell = (bearCRT ? 0.3 : 0) + (liqHigh ? 0.3 : 0) + (downtrend ? 0.4 : 0)

validBuy = probBuy >= probFilter
validSell = probSell >= probFilter

// ================= SIGNAL =================
buy = validBuy and bosUp
sell = validSell and bosDown

plotshape(buy, style=shape.labelup, color=color.green, text="BUY SNIPER")
plotshape(sell, style=shape.labeldown, color=color.red, text="SELL SNIPER")

// ================= ALERT =================
alertcondition(buy, "BUY", "CRT SNIPER BUY")
alertcondition(sell, "SELL", "CRT SNIPER SELL")

Penafian

Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.