Can anyone tell me what a variable on an indicator does?

hi xxxx peeps,
i’ve got an indicator that draws ATR channles either side of a moving average. i dont know the first thing about what the code means.


it the MA_type that i dont know what it does. my guess is that the number represents a different type of MA such as simple, exponential etc

here is the code on the side of the person who wrote it
http://www.damianifx.com.br/downloads/ATR%20Channels.mq4

can anyone help a fella out?
cheers :slight_smile:

Haven’t checked the code but I suspect so.

0 = SMA
1 = EMA
2 and 3 would give you some very exotic smoothing methods, SMMA and LWMA.

Personally I prefer to use the stringy-type code, e.g. MODE_SMA instead of numbers.

you are right.
i should have just run the indecator along with the different types of MA to see which fit the same.
thanks tho.