Explosive surge
A 0 to 10 score for how big a price, volume or bar range spike is, with no up or down direction.
Each minute ExplosiveSurge adds points from three threshold checks. The first measures how sharply the last three closes bend, as a percent of price, for up to 4 points; the bend check starts at 0.08%, about 0.6 dollars on SPY near 765. The second compares the bar's volume with the average over the window, for up to 3 points. The third compares the bar's high-low range with its average over the window, for up to 3 points. The checks only measure size, so a sharp drop scores as high as a sharp rally.
How to read it
- The score is drawn in its own pane below the price, as a whole number from 0 to 10.
- Most bars read 0. On SPY one-minute bars the median is 0, and roughly 5% of bars reach 5 or more.
- A 5 or more needs at least two of the three checks to fire together. A 10 needs all three at their top step.
- The score has no sign, so read the candles beside it to tell a rally surge from a sell-off surge.
What it outputs
- Surge score
- Whole-number total from 0 to 10 of the bend, volume and range checks. It shows how big the jump was, not which way price moved.
Settings
- window
- Bars in the baseline for average volume and average bar range. Longer windows give a steadier baseline, so spikes score higher. Shorter windows let a spike lift its own average, so those checks fire less. Below 5 it always reads 0.
Pitfalls
- A window below 5 always reads 0, because the code needs five bars of history and the history is capped at the window. The catalog allows 1, so keep it at 5 or more.
- The score is direction-blind: a crash and a squeeze score alike. Pair it with the candles or a trend filter before treating it as a signal.
- The range check uses each bar's high minus low and ignores the gap from the prior close, so a gap between bars adds no range.