HurstExponent
Hurst exponent of recent closes: above 0.5 means moves tend to persist, below 0.5 they tend to reverse.
Over the last window bars it takes the bar-to-bar changes in the close and splits them into blocks of several sizes, from 2 bars up to max_lag (capped at half the window minus 1). For each block size it computes the rescaled range (R/S): how far the running sum of deviations from the block mean wanders, divided by the block's standard deviation, averaged over the blocks. The output is the slope of log(R/S) against log(block size), which is the Hurst exponent: 0.5 for a random walk, higher when moves tend to continue, lower when they tend to reverse.
How to read it
- The line sits in its own pane below the price, not on the candles.
- At default settings on SPY one-minute bars it sat between 0.66 and 0.82 on 90% of bars, with a median of 0.74; that band is the normal picture.
- It measures how persistent the price path is, not which way it goes. A drop toward 0.5 means recent moves are no longer persistent; the lowest default reading was 0.53.
What it outputs
- Hurst exponent
- Hurst exponent of recent closes: about 0.5 for a random walk, above 0.5 when moves tend to persist, below 0.5 when they tend to reverse.
Settings
- window
- Number of recent bars each reading uses. Raising it smooths the line and lengthens the blank start, which is as many bars as the window. Lowering it reacts faster, but short windows read high even on random prices.
- max_lag
- Largest block size in the fit, capped at half the window minus 1, so higher values change nothing. Raising it adds longer block sizes to the fit. Below 4 the line stays blank, since fewer than three block sizes remain.
Pitfalls
- R/S estimates run high on short windows even when prices are random, so 0.74 at 100 bars is not proof of a trend. Compare readings only at the same window and lag settings.
- A window under 10 or max_lag under 4 leaves the line blank on every bar, since fewer than three block sizes fit.
- The first window bars of the chart stay blank, about 0.5% of bars at defaults, and a stretch with no price change gives no reading.