Support Board
Date/Time: Fri, 07 Feb 2025 22:46:56 +0000
Post From: New Study - Rescaled Range - Hurst Exponent
[2017-03-13 16:16:47] |
User71961 - Posts: 144 |
i've looked at the Hurst study that you implemented, however, there seems to be some errors...this does not display the Hurst Exponent (i'm not sure what this Hurst study is showing). The Hurst Exponent shows the logarithmic relationship between the avg rescaled range, and the avg st.dev of the data creating that range, over time, vs the log of the number of observations, for a chosen set of "Lag Periods". A set of data will have multiple Hurst exponents, depending on the Lag values chosen (just like how RSI and Bollinger Bands depend on the input values chosen). The Hurst exponent, being the avg slope of that logarithmic relationship, should be between 0-1. 1 = the series has internal trend persistence 0.5 = Random Brownian motion 0 = the series has internal mean reversion (you would expect that for most market data, the Hurst value averages 0.5 = random Brownian motion) (1) For this study to have value in trading, its important for the study to be calced like a moving average. (2) I also noticed that MinLag and Max Lag were not optional parameters to be set in the study. These are necessary for the study to have value in Trading. The Visual Basic code above is the "correct" calculation, which you can use as a benchmark (not for speed...but for accuracy). To test the VB code, i just copied chart data from SierraChart, pasted into a new excel, copy/pasted the VB code into a VBA code module, and then use the =Hurst function in the excel worksheet to get the values. This is just for testing purposes, to check for the proper calculation...its fine for calcing 20-50 values....but takes a long time to calc thousands (the main speed culprit is the VBA platform itself vs the code....VBA is a very slow processing engine). |