TradeZoro
Notifications

Cookbook

Opening gap marks

Mark days that open away from the prior close.

//@zscript 1
indicator("Gap marks", overlay=true)
minGap = input.float(0.3, "Minimum gap %", step=0.1)
newDay = dayofmonth != dayofmonth[1]
gapPct = (open - close[1]) / close[1] * 100
plotshape(newDay and gapPct > minGap, "Gap up", shape.triangleup, location.belowbar, color.green)
plotshape(newDay and gapPct < -minGap, "Gap down", shape.triangledown, location.abovebar, color.red)
50365042504850535059
Sample bars, not market data. Gap marks.

How it works

Compares each day's first open with the last close before it.

Education only. Not financial advice. Examples are teaching samples, not trading results.

Zscript is coming soon

The manual opens when Zscript launches.

Back to home