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:
My challenge is how would I through an EA, add and read the value of the Moving Average in the indicator window?
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.
To add comments, please log in or register