# Hurst Exponent – Checking for Trend Persistance – Python Notebook

Hurst exponent is originally developed by the famous hydrologist Harold Edwin Hurst to study the Long-Term Storage Capacity of Reservoirs. Hurst is developed to model reservoirs but later found to be used in other natural systems to measure the long term memory of time series.

Hurst was looking for a better way to model the levels of the river Nile to construct an appropriately sized reservoir system.

In a Hurst Exponent is used to determining the trend persistence (i.e whether a given time series is trending, mean-reverting or random series)

How to Read Hurst Exponent Values?

Hurst value ranges between 0 < H < 1

i) Trending: If the Hurst value range is between 0.5 < H < 1 indicates persistence in time series. The higher the value of the Hurst exponent more the trendiness of the market structure. For values close to 1 the series is persistent.

ii) Mean Reverting: If the Hurst value range is between 0 < H < 0.5 indicates anti persistence in time series. The lower the value of the Hurst exponent more the mean-reverting behavior (trend reversal). For values close to 0, the series is anti-persistent

iii) Geometrical Brownian Motion: It explains the random walk with the l unpredictability of the time series. If Hurst Exponent value is H = 0.5 then the time series is expected to move in a random walk.

Geometric Brownian Motion is widely used to model stock prices in finance

Jupyter Python Notebook to compute Hurst Exponent for Nifty

1. H.E. Hurst, 1951, “Long-term storage of reservoirs: an experimental study,” Transactions of the American Society of Civil Engineers, Vol. 116, pp. 770-799.
2. Bo Qian, Khaled Rasheed, 2004, “Hurst Exponent and financial market predictability,” IASTED conference on “Financial Engineering and Applications”(FEA 2004), pp. 203-209,
3. Mandelbrot, Benoit B., 2004, “The (Mis)Behavior of Markets, A Fractal View of Risk, Ruin and Reward,” Basic Books, 2004.
4. Miguel Ángel Sánchez1, Juan E. Trinidad2, José García2, Manuel Fernández, 2015, “The Effect of the Underlying Distribution in Hurst Exponent Estimation

## How to Retrieve Opening Balance, Total Turnover, Realized and…

This tutorial explores how to access the limits API functionality in Algomojo using python to retrieve the Account Balance, Total Turnover, Realized, UnRealized PNL,...

Backtrader is an open-source python framework for backtesting, optimizing, and deploying live algorithmic trading strategies.

## Getting Started with Google Colab

Google Colab also known as Google Colaboratory is a product from Google Research which allows user to run their python code from their browser...

## One Reply to “Hurst Exponent – Checking for Trend Persistance – Python…”

1. Narender Ponna says:

Hi Rajandran, Interesting to see a theoretical concept from you, as I have graduated in same domain.
I understood the concept and the relationship of the Hurst Exponent values to the time series data. However for practical use, it would be useful to calculate the changing values of the exponent by taking small set of samples from the time series data and keep shifting them in time as we move from the beginning to the end of time series. For example, let us say we have 1000 values in the time series. Then start with first 100 values, calculate Hurst exponent for that set. Then take next 100 and so on. This leads to 10 exponents. We can see how it changes as future unfolds.
Can you redo the steps you have done for the three different time series data cases and post the Hurst Exponent series?
Btw, the second link is not working. It went to a page with an error.