X-Ray Flow Bands
X-Ray Flow Bands is an indicator drawn over the price chart.
renko, heikin ashi, x-ray
1
indicator "X-Ray Flow Bands"2
bars: xray(20)3
4
input band_length = 305
6
center = hma(close, band_length)7
width = stdev(close, band_length) * 28
up_band = center + width9
down_band = center - width10
11
channel upper: up_band, lower: down_band, fill: linear_gradient(start: green.fade(80), end: red.fade(80))12
plot center, color: white, width: 213
mark triangle_up, at: below, when: crosses_above(close, down_band), color: green, size: tiny14
mark triangle_down, at: above, when: crosses_below(close, up_band), color: red, size: tinyWhat this script says
X-Ray Flow Bands is an indicator drawn over the price chart.
You can change one input: band_length (default 30).
It calculates center as the HMA of the close over band_length bars, width as 2 × the standard deviation of the close over band_length bars, up_band as center plus width and down_band as center minus width.
On the chart, it draws a channel, plots center, marks triangle up below the bar when the close crosses above down_band and marks triangle down above the bar when the close crosses below up_band.