Quote:
Originally Posted by dpaterso
There is just one thing that is concerning me though (and I'm not sure if it will affect the 'bigger picture' of things):
kaalilaatikko:
You'll notice that my 'unsmoothed' ADX/ADXR starts on day 14 right from the beginning of the chart. Yours does as well BUT you'll notice that the ADX/ADXR are not being calculated correctly for (I would imagine) at least the first 42 bars. Now I know WHY this is happening BUT are you sure that this is not affecting the indicator from 'way back then' BECAUSE remember now that (because you're 'smoothing') every last bit of data is being taken into account (unlike the 'unsmoothed' version where anything prior to a 14 day period is being ignored). Actually: OBVIOUSLY it's affecting the current data BUT just how much of a difference this makes to the current data IF IT'S A FULL CHART i.e. 999 days I would imagine is negligable BUT if it's a relatively newly added instrument where the chart is NOT a FULL CHART then the difference will be pronounced (and as a matter of fact the monthly charts for many of the instruments are not FULL CHARTS as yet e.g. AUD/NZD).
|
When we dissected ADX last time, there was quite extensive cross-checking of the implementations by different people and re-reading of the calculations by more than one person. As a result, I became very assured that my calculations are done in accordance with Wilder.
What I did this time was to port the same calculations to use Delta's data structures. Then I checked the values of a few sample +DI/-DI crossing points against my text-form analysis dump, which used my original implementation, and all of the values matched at least to the 2nd decimal (I did not dump more in the text-form analysis). So I was satisfied with this, and forgot to look at the beginning of the chart.
But indeed, there was a bug in this new implementation (but not in the benchmark one). I forgot to divide the sum of the first 14 DX values by 14, and this caused distortion to the beginning. I added the missing division, and now the calculations look as they should right from the beginning.
After the correction, my checkpoints still matched completely with the reference data. So a full chart was able to totally smooth out the initialisation bug.
Quote:
Originally Posted by dpaterso
I'm also assuming that somehow you've managed to test this and compare it to what the 'smoothed' ADX/ADXR is supposed to be in 'the book' (unlike me who ASSUMED that the ADX/ADXR that I was using was correct)!!!
|
I hope this got answered by the above.
I will mail you the corrected version in a minute.
J.