I am trying to make my EA based on the Fractals sample form the Indicator-->Examples folder. Here is the code that I tried:
I don't know why I can not able to trade with the signals that are produced by this code and the indicator. Any Idea and help? I am using MQL5
This article may help:
https://www.mql5.com/en/articles/43
![How to call indicators in MQL5 How to call indicators in MQL5](https://c.mql5.com/36/16/how-to-call-indicators-in-mql5.png)
- 2010.03.12
- KlimMalgin
- www.mql5.com
This article may help:
https://www.mql5.com/en/articles/43
Can you just get me a sample code that will help me understand how the indicator in the example folder --> Fractals work in the EA. Kindly show a small code so that I can used it the way. I have tried teh article what you have suggested already.
Kindly, help me.
Can you just get me a sample code that will help me understand how the indicator in the example folder --> Fractals work in the EA. Kindly show a small code so that I can used it the way. I have tried teh article what you have suggested already.
Kindly, help me.
I have the same problem.
One can only confirm fractals a few bars after the fact, so you will never detect a fractal by looking at the current bar nor even the previous bar.
If one had a series array representing the fractal values, where index “0” is the current bar, then you will only be able to detect a fractal at index “2” or “3”.
At “2” it would still be tentative and in progress and not confirmed as the current price could still change and invalidate it. Only at “3” is it confirmed!
So, when analyzing the fractal indicator, search from index “2” or preferably from “3” and beyond for earlier fractals.
void OnTick() { int test = iCustom(_Symbol,_Period,"Examples\\Fractals");
Perhaps you should read the manual, especially the examples.
How To Ask Questions The Smart Way. (2004)
How To Interpret Answers.
RTFM and STFW: How To Tell You've Seriously Screwed Up.
They all (including iCustom) return a handle (an int). You get that in OnInit. In OnTick/OnCalculate (after the indicator has updated its buffers), you use the handle, shift and count to get the data.
Technical Indicators - Reference on algorithmic/automated trading language for MetaTrader 5
Timeseries and Indicators Access / CopyBuffer - Reference on algorithmic/automated trading language for MetaTrader 5
How to start with MQL5 - General - MQL5 programming forum - Page 3 #22 (2020)
How to start with MQL5 - MetaTrader 5 - General - MQL5 programming forum - Page 7 #61 (2020)
MQL5 for Newbies: Guide to Using Technical Indicators in Expert Advisors - MQL5 Articles (2010)
How to call indicators in MQL5 - MQL5 Articles (2010)
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I am trying to make my EA based on the Fractals sample form the Indicator-->Examples folder. Here is the code that I tried:
I don't know why I can not able to trade with the signals that are produced by this code and the indicator. Any Idea and help? I am using MQL5