OPEN-SOURCE SCRIPT
Local Hurst Slope [Dynamic Regime]

1. HOW THE INDICATOR WORKS (Math → Market Edge)Step
Math
Market Intuition
1. Log-Returns
r_t = log(P_t / P_{t-1})
Removes scale, makes series stationary
2. R/S per τ
R = max(cum_dev) - min(cum_dev)
S = stdev(segment)
Measures memory strength over window τ
3. H(τ) = log(R/S) / log(τ)
Di Matteo (2007)
H > 0.5 → Trend memory
H < 0.5 → Mean-reversion
4. Slope = dH/d(log τ)
Linear regression of H vs log(τ)
Slope > 0.12 → Trend accelerating
Slope < -0.08 → Reversion emerging
LEADING EDGE: The slope changes 3–20 bars BEFORE price confirms
→ You enter before the crowd, exit before the trap
Slope > +0.12 + Strong Trend = Bullish = Long
Slope +0.05 to +0.12 = Weak Trend = Cautious = Hold/Trail
Slope -0.05 to +0.05 = Random = No Edge
Slope-0.08 to -0.05 = Weak Reversion = Bearish setup = Prepare Short
Slope < -0.08 = Strong Reversion = Bearish= Short
PRO TIPS
Only trade in direction of 200-day SMA
Filters false signals
Avoid trading 3 days before/after earnings
Volatility kills edge
Use on ETFs (SPY, QQQ)
Cleaner than single stocks
Combine with RSI(14)
RSI < 30 + Hurst short = nuclear reversal
Math
Market Intuition
1. Log-Returns
r_t = log(P_t / P_{t-1})
Removes scale, makes series stationary
2. R/S per τ
R = max(cum_dev) - min(cum_dev)
S = stdev(segment)
Measures memory strength over window τ
3. H(τ) = log(R/S) / log(τ)
Di Matteo (2007)
H > 0.5 → Trend memory
H < 0.5 → Mean-reversion
4. Slope = dH/d(log τ)
Linear regression of H vs log(τ)
Slope > 0.12 → Trend accelerating
Slope < -0.08 → Reversion emerging
LEADING EDGE: The slope changes 3–20 bars BEFORE price confirms
→ You enter before the crowd, exit before the trap
Slope > +0.12 + Strong Trend = Bullish = Long
Slope +0.05 to +0.12 = Weak Trend = Cautious = Hold/Trail
Slope -0.05 to +0.05 = Random = No Edge
Slope-0.08 to -0.05 = Weak Reversion = Bearish setup = Prepare Short
Slope < -0.08 = Strong Reversion = Bearish= Short
PRO TIPS
Only trade in direction of 200-day SMA
Filters false signals
Avoid trading 3 days before/after earnings
Volatility kills edge
Use on ETFs (SPY, QQQ)
Cleaner than single stocks
Combine with RSI(14)
RSI < 30 + Hurst short = nuclear reversal
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.