OPEN-SOURCE SCRIPT

My script

63
//version=5
indicator("12M High Volume Screener", overlay=false, screen=true)

// Calculate 12-month window dynamically
var int lookbackDays = 252
var int maxBarsBack = 5000

// Define timeframe for volume analysis (daily regardless of chart TF)
dailyVolume = request.security(syminfo.tickerid, "D", volume, lookahead=barmerge.lookahead_on)

// Calculate highest volume over trailing 12 months (excl. current bar)
highestVol = ta.highest(dailyVolume[1], lookbackDays)

// Detect volume breakout condition
volumeBreakout = dailyVolume > highestVol and barstate.isrealtime

// Screener output formatting
screener_output = volumeBreakout ? 1 : 0

// Visual confirmation (optional)
plot(screener_output, "Volume Breakout", plot.style_columns,
color=volumeBreakout ? color.new(color.green, 70) : color.gray)

Penafian

Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.