HAMA indicator returns EMA instead of colors

Back to topics list To post a new topic, please log in or register
avatar
14
filipefr 2015.02.08 15:24
 
I'm developing an EA which uses HAMA indicator (attached). But the indicator returns an EMA for me, but I want that it returns the bar color (e.g. yellow or green), so I can classify market condition. How can I do this?
Attached files:
  hama.mq4  (3.88 KB)
avatar
2017
gooly 2015.02.08 16:25 #
 
An indicator can only return double values not colors. The bar's color you have to find yourself by comparing the various return values.
avatar
Moderator
3427
GumRai 2015.02.08 22:49 #
 
filipefr:
I'm developing an EA which uses HAMA indicator (attached). But the indicator returns an EMA for me, but I want that it returns the bar color (e.g. yellow or green), so I can classify market condition. How can I do this?

The indicator that you attached does not have yellow or green colors.

use  iCustom calls for buffers 2 and 3 

if buffer 2 is > buffer 3, it is one color else it is the other color 

Back to topics list  

To add comments, please log in or register