There is also the choppiness index by Dreiss (an Aussie!) which makes sense. I use my more elaborate (smoothed, and some tweaks which I may share when I have cleaned up my messy coding) version of this to create adaptive indicators. I copy this from a Ward Systems site. From memory this may be upside down or something, I had to fix it and added some things.
There are possibly easier to understand languages upon a little googling.
HMax = MaxList(Max(High, Close), Period)
LMax = MinList(Min(Low, Close), Period)
Choppiness = 100.0 * Log(Sum(TrueRange,Period)/(HMax -LMax)) / Log(Period)
Close is Close one bar ago,
Max(a,b) is the largest of a and b,
MaxList(a,N) is the largest a in N bars back,
MinList(a,N) is the smallest a in N bars back,
Sum(a,N) is the sum of a over N bars back,
TrueRange is True Range.
Carlos Sevcik's fractal dimension calculation was published first time here : A procedure to Estimate the Fractal Dimension of Waveforms
He published a code written using basic there that was supposed to calculate the FDI. The problem with it was (and still is) that it will almost never go bellow 1.5 (the value that is important as a kind of a boundary between the trending - bellow 1.5 - and random - values above 1.5 - estimation). After that, I gave up that approach.
There is a version made by Alex Matulich (here : http://unicorn.us.com/trading/src/_FractalDim.txt ) that corrects some errors made by Sevcik. Also, there is another fractal dimension calculation made by Mark Jurik (he made it before he made the composite fractal behavior) which has nothing in common with either Sevcik's way or Matulich's way of calculating it and is more a kind of a curiosity than anything else
Now, one more thing.
My coding produces values that go above and below 1.5. I have mentioned an academic critique, which confirmed my analysis in excel (where I can plop in values where things "ought" to result in a number - that it does have its limitations as to values - I think it cannot get below about 1.25 from memory. I think it may have an upper bound of maybe 1.9, again from memory. I can cope with that.
By this method I also found Ehlers FRAMA a bit TOO incorrect.
As to the german critique, I am guessing it could be two things - that if there is a spike, this pretty much makes all values for the period thereafter silly until that spike is eliminated from the calculations. An example is when the Yen rallied a lot in just a couple days sometime last year or whenever, and then went mostly back to normal - the FDI gave stupid results until that rally was eliminated.
The other reason may be that a market will have vastly different FDIs depending on the time frame - they are essentially different markets - you might be short in one timeframe and long in another. Or, one timeframe may be trending and another random. But isn't this true of many indicators at times?
As to the german critique, I am guessing it could be two things - that if there is a spike, this pretty much makes all values for the period thereafter silly until that spike is eliminated from the calculations. An example is when the Yen rallied a lot in just a couple days sometime last year or whenever, and then went mostly flat.
If you take original Carlos Sevcik's basic code from that page the cases when it goes bellow 1.5 can be counted on one hands fingers. Alex Matulich's way produces correct results. My problem with that is that the code from Sevcik's page was not tested before published and it took some time for some people to find where the errors are. That is not what we should expect from a serious publication (but then, hey, Mark Jurik published something that he called Jurik TPO and it turned out to be Spearman rank auto-correlation and then he quickly removed all the mentioning of that unfortunate TPO)
I was not talking about other ways of calculating FDI
As of German paper : it was not a critique, but a mathematical proof that FDI can not be used in financial markets. But untill I re-find that link, let us leave that part as a hypothetical for now (otherwise it would become just a rumor or a gossip) . All I wanted to do is to point out that there are disagreements of FDI usability in financial markets (and financial time series ultimately)
I think Matulich is wrong when he says "Because the lookback length n goes from 0 to n, we also have nintervals, and not n-1 intervals as described in the paper."Let's say to are building a fence, and you have just three fence posts for this wonderful fence that many will admire. You need to put a gate between each of them. How many gates do you need?
That is not how fdi is calculated (and as far as I see you know it)
The basic idea is to go over a sample of data over and over extending the calculation length further and further and that way extending the sample used in the calculation. There is no room for "doors"
Yes, I looked at his original code and I scratched my head for a few weeks until I stumbled across others who had coded it in a manner I could cope with.
pd:=whatever you like;
x:=C; (only because I played with what I wanted x to be)
.etc for the number periods specified - some clever people may have a sub routine.
FDI:=1+(Log(a1+a2+up to a"pd")+Log(2))/Log(2*(pd-1));
Yes, it is a far from perfect measure of FDI, but there you go. I have said what I think about FRAMA.
Anyway. There is my metastock code.
Frankly, box-counting isnt any robust at all. The formula tells you as much. The error terms in this file below was for a strict gaussian distribution time series. One can only imagine ow much robustness there is when the series varies away from Gaussian occasionally.
The idea of Rescaled Range Analysis was excellent in itself, but the amount of data needed for Hurst Exponent calculation as stated in some papers to range from afew thousand to tens of thousands.
The Variance Ratio sounds like a very raw/noisy form to me if the formula is as stated in the link there. The bad thing here is that it divides the longer time ratio by the shorter time ratio. The least that could be done there is to observe Einstein's Square Root rule for random particles. As a whole, the idea seems to be using variance comparison as a base for comparing volatility.
This is the modified version of FDI Free download of the 'Variation Index' indicator by 'Ilnur' for MetaTrader 4 in the MQL5 Code Base has anyone seen it?I find it useful.
That is pretty cool, thanks for that. Having just spent some time comparing it to FGDI, they are not too dissimilar, I think the VI is a bit more conservative - it calls a market flat before FGDI, but this varies.. I fail to understand the code - it seems that there is an iterative procedure.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.