Momentum cascade detector
A sharp rebound off a short dip, scored by its size; zero on most bars.
It compares how far close has moved over window_short, window_med and window_long bars, as percent changes. A bar scores only when the short move beats the medium, the medium is positive and the long is no lower than -0.1%. The score is the short move times 2, or times 3 when the three are strictly ordered and the short beats the medium by at least acceleration_factor; otherwise it is 0. Despite the name, it needs the close three bars back below the close eight bars back, so it catches a sharp rebound from a dip, not a steady climb.
How to read it
- The line sits in its own pane below the price and reads zero on at least half of bars at default settings.
- A value above zero means the latest close has climbed back above the close eight bars ago, after the close three bars ago fell below it.
- At default settings, readings above about 0.05 are the top 5% of bars; in the one-month SPY sample the peak was about 0.96.
- Read it as a rebound flag. A steady climb or a plain downtrend keeps it at zero.
What it outputs
- Cascade score
- Zero unless the rebound pattern holds; otherwise the short-move percent times 2 or 3. In a one-month SPY sample at defaults it peaked near 0.96.
Settings
- window_short
- Lookback for the fastest leg, the close change over this many bars. Shorter follows the last few bars, so brief dips and bounces swing the score more. Longer makes this leg span more bars and drift toward the middle leg.
- window_med
- Lookback for the middle leg, the reference the fastest leg must beat. Raising it measures against an older close, so the recent dip must sit below a further-back price. Lowering it measures against a closer price.
- window_long
- Lookback for the slowest leg. The 3x score needs the middle leg to beat it and the latest close above the price this many bars back; the 2x score only needs it no lower than -0.1%. Raising it asks more of the rebound; lowering it asks less.
- acceleration_factor
- Sets how far the short leg must beat the middle leg to earn 3x instead of 2x, on strictly ordered bars. Raising it moves more of them to 2x. Values at or below 1 give all of them 3x. It never changes whether the pattern fires.
Pitfalls
- The name says accelerating rally, but a steady climb never scores. Both branches need the close three bars back below the close eight bars back.
- Zero on at least half of bars at default settings, with readings above about 0.05 on roughly one bar in twenty, so the pane looks flat most of the time.
- Window order is not checked: the labels hold only when window_short < window_med < window_long. Values of acceleration_factor at or below 1 behave the same, and its slider runs to plus or minus 151.