OPEN-SOURCE SCRIPT

Nithin Liquidity Sweep

122
//version=6
indicator("Liquidity Sweep Finder", overlay=true, max_labels_count=500)

// Input settings
lookback = input.int(10, "Lookback Bars for High/Low", minval=2)
showHighSweep = input.bool(true, "Show High Sweeps")
showLowSweep = input.bool(true, "Show Low Sweeps")

// Identify recent swing high/low
recentHigh = ta.highest(high, lookback)
recentLow = ta.lowest(low, lookback)

// Sweep conditions
highSweep = showHighSweep and high > recentHigh and close < recentHigh
lowSweep = showLowSweep and low < recentLow and close > recentLow

// Plot signals
plotshape(highSweep, title="High Liquidity Sweep", style=shape.labeldown,
text="Sweep ⬇", location=location.abovebar, color=color.red, size=size.tiny)

plotshape(lowSweep, title="Low Liquidity Sweep", style=shape.labelup,
text="Sweep ⬆", location=location.belowbar, color=color.green, size=size.tiny)

// Highlight background when sweep occurs
bgcolor(highSweep ? color.new(color.red, 85) : na)
bgcolor(lowSweep ? color.new(color.green, 85) : na)

คำจำกัดสิทธิ์ความรับผิดชอบ

ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ ข้อกำหนดการใช้งาน