
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
For a long time I wanted to calculate the Hurst index. But I am not good at formulas and was looking for information on an example to understand how to calculate it.
I don't know how much the index is applicable to trading. But, after all, to find out you need to check, and to check you need to calculate it.
In general, write more.
Write me what this string looks like in mql.
Thanks in advance.
Question for the author of the article - Dmitry, you mentioned Matlab, I searched in its help for the word Hurst, and found only the use in Wavelet Toolbox.
But I didn't find any calculation, could you tell me where the calculation functions are in Matlab?
Sorry, I've been looking for a string that calculates Log(V) for a long time
Write me what this string looks like in mql.
Thanks in advance.
The article Calculation of Hurst coefficient has been published:
Author: Dmitriy Piskarev
Did you even look at Help-Mathematical Functions?
Sorry, long time looking for a string that calculates Log(V)
Write me what this string looks like in mql.
Thanks in advance.
Victor, V - statistic for each set is subtracted by the formula:
E[Log(R/S)] / sqrt(N)
where E[Log(R/S)] is the average value of R/S for a sample of N items.
N is the sample size.
For example, you calculate R/S by dividing 2000 entry bars into 50 groups of 40 each.
Here N = 40, and E[Log(R/S)] = [Log(R/S)_1 + Log(R/S)_2 + ... + Log(R/S)_50)] / 50
I think translating this into code shouldn't be too difficult. Sorry for the delay.
In real trading, the use of the Hurst coefficient for trend detection works even worse than the classic crossing of dashes. The reason is classical - a large lag.
However, the ideas of its application still arise from time to time in the algo commands of mat-bots, but most often the trade ends in failure, even if there was a random positive result at the beginning. An illustrative example of unsuccessful application of usd trading based on Hirst trend detection is the w-surf strategy from edgstone - the first year in the plus, all the rest - in the minus (to see the real performance, look not at the adverts on the company's website, but google w-surf + mfd).
Alexei, thank you very much for your constructive comment. I will continue to study and research. I will take note of your suggestion.
Dmitry,
I suggest you watch this film and read about this man.
https://forecaster-movie.com/en/the-movie/
Maybe you will be the next to write this programme. Contact me if you start working on it. Thank you.
Dear author! Thank you for your labour, of course, and the indicator is very important, BUT... I understand that none of those who have commented in the comments has ever tried to use the indicator :D
When it turned out that your indicator does not work on small timeframes, does not work with the appearance of new bars (which means it can not be tied to the robot and tested) and calculates negative coefficients of determination, I went inside to fix it and ... forgot non-material expressions for about a week. You don't take the easy way out. Where real types are needed, you use integer types, introduce a bunch of unnecessary variables, useless computational steps, leave a bunch of old methods and references that only confuse and complicate understanding, many times turn data arrays from direct indexing to reverse indexing, create a bunch of unnecessary objects that pass the same set of variables, and instead of the standard in mql concise system of accounting for previous calculations for some reason you invent your own, scary and cumbersome....
Wasn't it easier to just take any standard mql indicator and calculate everything you need on its basis? Believe me, it is much easier to understand it than your code...
I attach an archive with sources, where everything that did not work, works, and removed all (or almost all) unnecessary. The question remains how slow this design will be in real tests. I haven't tested it yet, but I feel I'll have to keep fixing it....