Adding and Reading Indicator value from Indicator Windows

Back to topics list To post a new topic, please log in or register
avatar
2
sundayokpokor 2015.10.05 10:31
 

I am trying to implement a trading strategy into an EA. The strategy is with the combination of an ATR and a Moving Average indicator, both indicator are in the indicator windows as shown below:

ATR and MA in indicator window 

My challenge is how would I through an EA, add and read the value of the Moving Average in the indicator window? 

avatar
Moderator
3406
GumRai 2015.10.05 10:49 #
 

Do you mean an MA on ATR?

You could write a custom indicator with 2 buffers, the ATR and the 2nd for an iMAOnArray

Get the values for the EA with an iCustom call. 

The other way would be to use arrays in the EA to calculate the values, but that can be a bit more complicated. 

avatar
2
sundayokpokor 2015.10.05 10:59 #
 
Hi GumRai, thanks for your quick response, I think your suggestion should be the best solution. Though I am not too good writing a custom indicator, I prefer doing it with an EA. Better still I would try your solution with a custom indicator. Thanks.
Back to topics list  

To add comments, please log in or register