Inverse Functions

Discussion in 'Technical Analysis' started by TSOKAKIS, Aug 11, 2003.

  1. We may express Close as a function of MA or EMA or DEMA with the

    // Inverse functions, by D. Tsokakis, Aug 2003
    p=20;fp=2/(p+1);
    CloseviaMA=p*MA(C,p)-(p-1)*Ref(MA(C,p-1),-1);// [1]
    CloseviaEMA=0.5*((P+1)*EMA(C,P)-(P-1)*Ref(EMA(C,P),-1));// [2]
    CloseviaDEMA=(DEMA(C,p)+(1-fp)*fp*Ref(EMA(C,p),-1)-(1-fp)*Ref(DEMA(C,p),-1))/((2-fp)*fp);// [3]
    Plot(C,"CLOSE",1,1);
    Plot(CloseviaMA,"CloseviaMA",5,1);
    Plot(CloseviaEMA,"CloseviaEMA",7,1);
    Plot(CloseviaDEMA,"CloseviaDEMA",4,1);

    It is obvious that [1], [2] and [3] are independent of the smoothing period p, they are all equal to Close.

    See also
    http://www.amibroker.com/library/detail.php?id=286
    http://groups.yahoo.com/group/amibroker/message/45801
     
  2. maxpi

    maxpi

    So you solved for "close" and then said it equals "close" no matter how you calculate it. I, for one, already pretty much knew that I guess. Close = close, yup. Now if you had a bunch of formulas that all equaled close and you set them equal to each other and solved for tomorrow's close somehow and all the variables cancelled themselves out, you should PM me with the formulas.

    I think you are trippin' personally, but my opinion, quite often, has proved itself to be worth about what you pay for it and this may well be just one of those cases.
     
  3. You miss something here: All the variables DO NOT cancell out.
    The use is the following :
    A CloseviaMAp will be equal to a CloseviaMAk for two different periods p and k. This argument gives interesting results for tomorrows MAk, MAp and, mainly, for their probable cross.