OPEN-SOURCE SCRIPT

MRX_M7 777

102
//version=5
indicator("MRX_M7 777 MTF ALERT (jgar)", overlay=true)

// === SOZLAMALAR ===
tfInput = input.timeframe("15", "Qaysi TF")
showZone = input.bool(true, "Zonani ko‘rsat / o‘chirish")

zoneColor = color.new(color.lime, 75)

// === MTF DATA (BITTA QATORDA!) ===
[mtfHigh, mtfLow, mtfOpen, mtfClose] = request.security(syminfo.tickerid, tfInput, [high, low, open, close])

// === ENGULF ===
engulf = mtfHigh > mtfHigh[1] and mtfLow < mtfLow[1]

// === ZONA ===
zoneHigh = mtfHigh[1]
zoneLow = mtfLow[1]

// === CHARTGA CHIZISH ===
if engulf and showZone
box.new(bar_index - 1, zoneHigh, bar_index, zoneLow, bgcolor = zoneColor, border_color = color.lime)
label.new(bar_index, zoneHigh, "ENGULF " + tfInput, style = label.style_label_down, textcolor = color.white, bgcolor = color.lime)

// === ALERT ===
alertcondition(engulf, title="MTF ENGULF", message="ENGULF " + tfInput + " timeframe da sodir bo‘ldi")

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.