Mottl / hurst

Hurst exponent evaluation and R/S-analysis in Python
MIT License
289 stars 80 forks source link

Hurst exponent #8

Open Prossi79 opened 4 years ago

Prossi79 commented 4 years ago

Hello! Just working with your code on a time series analysis, to compute the Hurst exponent of a equity, e.g. Google.

Here is the code:

import matplotlib.pyplot as plt from hurst import compute_Hc from datetime import datetime import pandas_datareader as web

series = web.DataReader("GOOG", "yahoo", datetime(2000,1,1), datetime(2013,1,1))

H, c, data = compute_Hc(series['Adj Close'], kind='price', simplified=True)

Output: H 0.82083 C 0.5268

Following this resource for the Google stock a Hurst of 0.50788 was calculated -> https://www.quantstart.com/articles/basics-of-statistical-mean-reversion-testing

In your script c is the equivalent to the Hurst Exponent being calculated in above link? Or are the two methods not comparable?

geofffoster commented 3 years ago

change simplified=False