How to EMA-based to code trix result??

#1
Hello, Folk

I understand that trix indicator is triple exponential smoothed price. But why:

TRIX(10) is not equal to EMA(EMA(EMA(C,10),10),10) ??? :confused:

I want to pick 'O' instead of 'C' into trix. Anyone can teach me how I can write the code in EMA-based for get the trix result??

Much thanks! :)
 

johnnypareek

Well-Known Member
#2
hi,

Because you are taking raw data and in build takes % change.

t=EMA(EMA(EMA(C,9),9),9);
tr=t-ref(t,-1);

may be u r taking this. Add

tm=((t-Ref(t,-1))/t)*100;
Plot(tm,"",1,1);
n c

johnny
 

Similar threads