Triangular moving average (TMA) ... - page 55

 

Hi mladen

I find a TMA bands ,but I know its a TMAcentered

TMAcentered & bands 2.02 mtf.mq4

https://www.mql5.com/en/forum/179807/page197

if can make a TMA band nrp indi?

thx a lot.

 
blueface:
Hi mladen

I find a TMA bands ,but I know its a TMAcentered

TMAcentered & bands 2.02 mtf.mq4

https://www.mql5.com/en/forum/179807/page197

if can make a TMA band nrp indi?

thx a lot.

blueface

Version with regular TMA was posted here : https://www.mql5.com/en/forum/179807/page245

 

I've been using this TMA centered bands indicator but it is using 100% cpu on 1 chart with 5 instances, 1min, 5min, 15, 1hr, 4hr.

I see these lines are calling for calculateTma indicator but there is no such indicator

buffer1 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,0,y);

buffer2 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,1,y);

buffer3 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,2,y);

trend = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,3,y);

Files:
tma.mq4  9 kb
 
eesnard:
I've been using this TMA centered bands indicator but it is using 100% cpu on 1 chart with 5 instances, 1min, 5min, 15, 1hr, 4hr.

I see these lines are calling for calculateTma indicator but there is no such indicator

buffer1 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,0,y);

buffer2 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,1,y);

buffer3 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,2,y);

trend = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,3,y);

Same thing on my terminal :

PS: 3ed parameter in iCustom call is the name of the indicator. Not the 4th

Files:
tma.gif  110 kb
 
eesnard:
I've been using this TMA centered bands indicator but it is using 100% cpu on 1 chart with 5 instances, 1min, 5min, 15, 1hr, 4hr.

I see these lines are calling for calculateTma indicator but there is no such indicator

buffer1 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,0,y);

buffer2 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,1,y);

buffer3 = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,2,y);

trend = iCustom(NULL,timeFrame,indicatorFileName,"calculateTma",HalfLength,Price,ATRMultiplier,ATRPeriod,3,y);

How many bars on chart you have?

 
nbtrading:
How many bars on chart you have?

It depends on the half period too

In any case, with normal values it should work as shown a few posts ago (the indicator recalculates just as many bars as it is necessary)

 

A big hug from Brazil...

...Mladen,thanks for sharing such valuable files!!!!

=)

It is possible to add six (or More) bands in TMAcentered & bands?

extern string TimeFrame = "current time frame";

// Band 1

extern int HalfLength = 56;

extern int Price = PRICE_CLOSE;

extern double ATRMultiplier = 1.0;

extern int ATRPeriod = 100;

extern bool Interpolate = true;

// Band 2

extern int HalfLength = 56;

extern int Price = PRICE_CLOSE;

extern double ATRMultiplier = 2.0;

extern int ATRPeriod = 100;

extern bool Interpolate = true;

// Band 3

extern int HalfLength = 56;

extern int Price = PRICE_CLOSE;

extern double ATRMultiplier = 2.0;

extern int ATRPeriod = 100;

extern bool Interpolate = true;

Like this...

Great Regards,

Fernando Sanches

ps.: Sorry my bad English

 
fernandosem:
A big hug from Brazil...

...Mladen,thanks for sharing such valuable files!!!!

=)

It is possible to add six (or More) bands in TMAcentered & bands?

extern string TimeFrame = "current time frame";

// Band 1

extern int HalfLength = 56;

extern int Price = PRICE_CLOSE;

extern double ATRMultiplier = 1.0;

extern int ATRPeriod = 100;

extern bool Interpolate = true;

// Band 2

extern int HalfLength = 56;

extern int Price = PRICE_CLOSE;

extern double ATRMultiplier = 2.0;

extern int ATRPeriod = 100;

extern bool Interpolate = true;

// Band 3

extern int HalfLength = 56;

extern int Price = PRICE_CLOSE;

extern double ATRMultiplier = 2.0;

extern int ATRPeriod = 100;

extern bool Interpolate = true;

Like this...

Great Regards,

Fernando Sanches

ps.: Sorry my bad English

fernandosem

Yes (in new mt4 you can use up to 512 buffers)

Just adding multiple ATR multipliers I assume?

 

I know that it recalculates, but is there a tradestation version of centered TMA?

 
sebastianK:
I know that it recalculates, but is there a tradestation version of centered TMA?

Does tradestation allows using future values (I heard it does not)?

Reason: