cspunar |
Gold User, Member, TeleChart
|
Registered User |
|
|
|
|
Unsure |
|
Monday, August 15, 2005 |
Tuesday, December 16, 2008 8:29:42 PM |
1 [0.00% of all post / 0.00 posts per day] |
|
I've incorporated these ideas to simplify this:
The key is that I'm looking for (+DM) - (-DM) that is very close to Zero.
So I take my DM for a given day; its either + or -. If its - I keep the sign negative. Multiply it by its weighting factor. And then add that value to the sum.
As for as the weighting factors: since we have the difference of two infinite sums, I just subtract the A0 term from the A1 term to get my difference between days.
So I'm actually calculating the change in DM. To give it some perspective, I divide it by an approximation of Wilder's true range, XAVGH14-XAVGL14 (this ignores gaps but serves the purpose of eliminating stocks that are trading in a 0.25 point band).
Then with this method I just scan for stocks that are + or - .05 of zero. A word of warning. It should match deadnutz with Wilder's 14 14 DI lines, and most of the time the DI lines are crossing or are within a couple days of crossing. But sometimes it looks like a big miss, however if I look back at price I can always identify the beginnings of a potential trend change.
Anyhow here is my formula, let me know what you think or if you have any improvements. Oh the error is minimized because I add back in the last term with the full multiplier. I'm not a math guy but it makes sense because it balances the terms.
( 0.0866773148027758*( ( (H34-H35)>(L35-L34)) * (H34>H35) * (H34-H35) - ( ( (L35-L34)>(H34-H35) ) * (L34<L35) * (L35-L34) ) ) + 0.00666748575405968*( ( (H33-H34)>(L34-L33)) * (H33>H34) * (H33-H34) - ( ( (L34-L33)>(H33-H34) ) * (L33<L34) * (L34-L33) ) ) + 0.00718036927360273*( ( (H32-H33)>(L33-L32)) * (H32>H33) * (H32-H33) - ( ( (L33-L32)>(H32-H33) ) * (L32<L33) * (L33-L32) ) ) + 0.00773270537157217*( ( (H31-H32)>(L32-L31)) * (H31>H32) * (H31-H32) - ( ( (L32-L31)>(H31-H32) ) * (L31<L32) * (L32-L31) ) ) + 0.00832752886169311*( ( (H30-H31)>(L31-L30)) * (H30>H31) * (H30-H31) - ( ( (L31-L30)>(H30-H31) ) * (L30<L31) * (L31-L30) ) ) + 0.00896810800490026*( ( (H29-H30)>(L30-L29)) * (H29>H30) * (H29-H30) - ( ( (L30-L29)>(H29-H30) ) * (L29<L30) * (L30-L29) ) ) + 0.00965796246681566*( ( (H28-H29)>(L29-L28)) * (H28>H29) * (H28-H29) - ( ( (L29-L28)>(H28-H29) ) * (L28<L29) * (L29-L28) ) ) + 0.0104008826565707*( ( (H27-H28)>(L28-L27)) * (H27>H28) * (H27-H28) - ( ( (L28-L27)>(H27-H28) ) * (L27<L28) * (L28-L27) ) ) + 0.01120095055323*( ( (H26-H27)>(L27-L26)) * (H26>H27) * (H26-H27) - ( ( (L27-L26)>(H26-H27) ) * (L26<L27) * (L27-L26) ) ) + 0.0120625621342477*( ( (H25-H26)>(L26-L25)) * (H25>H26) * (H25-H26) - ( ( (L26-L25)>(H25-H26) ) * (L25<L26) * (L26-L25) ) ) + 0.0129904515291898*( ( (H24-H25)>(L25-L24)) * (H24>H25) * (H24-H25) - ( ( (L25-L24)>(H24-H25) ) * (L24<L25) * (L25-L24) ) ) + 0.0139897170314352*( ( (H23-H24)>(L24-L23)) * (H23>H24) * (H23-H24) - ( ( (L24-L23)>(H23-H24) ) * (L23<L24) * (L24-L23) ) ) + 0.0150658491107764*( ( (H22-H23)>(L23-L22)) * (H22>H23) * (H22-H23) - ( ( (L23-L22)>(H22-H23) ) * (L22<L23) * (L23-L22) ) ) + 0.0162247605808361*( ( (H21-H22)>(L22-L21)) * (H21>H22) * (H21-H22) - ( ( (L22-L21)>(H21-H22) ) * (L21<L22) * (L22-L21) ) ) + 0.0174728190870543*( ( (H20-H21)>(L21-L20)) * (H20>H21) * (H20-H21) - ( ( (L21-L20)>(H20-H21) ) * (L20<L21) * (L21-L20) ) ) + 0.0188168820937507*( ( (H19-H20)>(L20-L19)) * (H19>H20) * (H19-H20) - ( ( (L20-L19)>(H19-H20) ) * (L19<L20) * (L20-L19) ) ) + 0.0202643345625008*( ( (H18-H19)>(L19-L18)) * (H18>H19) * (H18-H19) - ( ( (L19-L18)>(H18-H19) ) * (L18<L19) * (L19-L18) ) ) + 0.021823129528847*( ( (H17-H18)>(L18-L17)) * (H17>H18) * (H17-H18) - ( ( (L18-L17)>(H17-H18) ) * (L17<L18) * (L18-L17) ) ) + 0.0235018318002967*( ( (H16-H17)>(L17-L16)) * (H16>H17) * (H16-H17) - ( ( (L17-L16)>(H16-H17) ) * (L16<L17) * (L17-L16) ) ) + 0.0253096650157042*( ( (H15-H16)>(L16-L15)) * (H15>H16) * (H15-H16) - ( ( (L16-L15)>(H15-H16) ) * (L15<L16) * (L16-L15) ) ) + 0.0272565623246045*( ( (H14-H15)>(L15-L14)) * (H14>H15) * (H14-H15) - ( ( (L15-L14)>(H14-H15) ) * (L14<L15) * (L15-L14) ) ) + 0.0293532209649587*( ( (H13-H14)>(L14-L13)) * (H13>H14) * (H13-H14) - ( ( (L14-L13)>(H13-H14) ) * (L13<L14) * (L14-L13) ) ) + 0.0316111610391863*( ( (H12-H13)>(L13-L12)) * (H12>H13) * (H12-H13) - ( ( (L13-L12)>(H12-H13) ) * (L12<L13) * (L13-L12) ) ) + 0.0340427888114314*( ( (H11-H12)>(L12-L11)) * (H11>H12) * (H11-H12) - ( ( (L12-L11)>(H11-H12) ) * (L11<L12) * (L12-L11) ) ) + 0.0366614648738492*( ( (H10-H11)>(L11-L10)) * (H10>H11) * (H10-H11) - ( ( (L11-L10)>(H10-H11) ) * (L10<L11) * (L11-L10) ) ) + 0.039481577556453*( ( (H9-H10)>(L10-L9)) * (H9>H10) * (H9-H10) - ( ( (L10-L9)>(H9-H10) ) * (L9<L10) * (L10-L9) ) ) + 0.0425186219838725*( ( (H8-H9)>(L9-L8)) * (H8>H9) * (H8-H9) - ( ( (L9-L8)>(H8-H9) ) * (L8<L9) * (L9-L8) ) ) + 0.0457892852134011*( ( (H7-H8)>(L8-L7)) * (H7>H8) * (H7-H8) - ( ( (L8-L7)>(H7-H8) ) * (L7<L8) * (L8-L7) ) ) + 0.0493115379221243*( ( (H6-H7)>(L7-L6)) * (H6>H7) * (H6-H7) - ( ( (L7-L6)>(H6-H7) ) * (L6<L7) * (L7-L6) ) ) + 0.0531047331469031*( ( (H5-H6)>(L6-L5)) * (H5>H6) * (H5-H6) - ( ( (L6-L5)>(H5-H6) ) * (L5<L6) * (L6-L5) ) ) + 0.0571897126197417*( ( (H4-H5)>(L5-L4)) * (H4>H5) * (H4-H5) - ( ( (L5-L4)>(H4-H5) ) * (L4<L5) * (L5-L4) ) ) + 0.0615889212827988*( ( (H3-H4)>(L4-L3)) * (H3>H4) * (H3-H4) - ( ( (L4-L3)>(H3-H4) ) * (L3<L4) * (L4-L3) ) ) + 0.0663265306122449*( ( (H2-H3)>(L3-L2)) * (H2>H3) * (H2-H3) - ( ( (L3-L2)>(H2-H3) ) * (L2<L3) * (L3-L2) ) ) + 0.0714285714285714*( ( (H1-H2)>(L2-L1)) * (H1>H2) * (H1-H2) - ( ( (L2-L1)>(H1-H2) ) * (L1<L2) * (L2-L1) ) ) - 1*( ( (H-H1)>(L1-L)) * (H>H1) * (H-H1) - ( ( (L1-L)>(H-H1) ) * (L<L1) * (L1-L) ) ) ) * (-1)*0.0714285714285714*100 / (XAVGH14-XAVGL14)
|
|