I have tried to code Trix Oscillator in Amibroker AFL. But It does not draw similar to THV Trix Indicator.
Can any one help to enhance this. Many Thanks.
Can any one help to enhance this. Many Thanks.
Inserted Code
_SECTION_BEGIN("Manual Trix");
//TEMA can be implemented via EMA:
fast=20;
slow=35;
fasttx = 3 * EMA(Close,fast) - 3 * EMA(EMA(Close,fast),fast) + EMA(EMA(EMA(Close,fast),fast),fast);
slowtx = 3 * EMA(Close,slow) - 3 * EMA(EMA(Close,slow),slow) + EMA(EMA(EMA(Close,slow),slow),slow);
Plot( fasttx, "fasttx", IIf(fasttx > Ref(fasttx, -1), colorLime, IIf(fasttx < Ref(fasttx, -1), colorRed, colorBlack)), styleLine|styleLine);
Plot( slowtx, "slowTx ", IIf(slowtx > Ref(slowtx, -1), colorDarkGreen, IIf(slowtx < Ref(slowtx, -1), colorDarkRed, colorBlack)), styleThick|styleLine);
_SECTION_END(); Thanks !!!