I have a strategy based on harmonic patterns like gartleys, crab, and some other customized patterns. I am thinking of learning python to hopefully implement my strategy. Would this be possible to program using MQL5 as well to create an algorithmic trading strategy? Could I also be alerted of when these trade set ups occur so I can use my discretion in entering? It would be much easier for me to implement an algorithm to scan hundreds of securities rather than spending numerous hours looking for them manually. Any advice on the steps I can take would be greatly appreciated. Thank you so much in advance!!!
EDIT: Would it possible if admin can move this to MT5's trading system section? Thanks!
GBWT094114:
The Question in formal Automata Theory means, You want to prove if two equal sets of instructions from two different languages, can produce the same results as described above. And prove it by a condition if and only if, the results will always be the same for all possible combination of algorithms under the rules of those languages?
Sorry for being unclear. I'm not asking about whether I can apply the same coding for the different languages. I'm just wondering if I can implement the harmonic pattern on MQL5.
Thanks, and apologies if I'm still not clear lol.
Yes but it has to be coded.
The easiest way is to make use of what i call, the go over value model where you hard coded a symmetric version of the pattern into the code and then compare live incoming market feed to that pattern, and every time a match has been found that represents a replica of the pattern you can have the ea give off an alert.
The problem usually is that the patterns look a lot like each other, but are never really exactly the same, so you also have to add some differential values.
The easiest way to do that is to set minimal and maximal amplitude values so that the pattern comparison becomes flexible.
Now of course new problems will arrive because when you receive the alert, the pattern has already happened so how are you planning to trade it ?
The solution could be to slice the pattern in half and have it set off the alert when it detects that the first half move has been made.
It's all relatively simple but you have to make sure that the values you use are all just right, and that takes other mechanisms to calculate them.
A quick start for example would be to analyze large breakout movements, there are questions 1.what happens always 2.what happens never, or rarely 3.what usually happens, or is expected to happen. 4. when does the value reach or go over the first leg of the pattern.etc.
So you can define standard moves and define larger moves and whenever market goes over the standard move you set off the alert.
This is the most simple form of breakout pattern recognition.
Now you can add the time scale and add that the move has to happen in X seconds, or minutes because you don't want an alert when the market moves over your value in too long a time span.
And you keep on adding filters to discriminate between wanted and unwanted criteria.
It can be done and it isn't difficult at all, but like i said you have to use the correct values else you will get too many, or too little alerts.
The codebase already has a harmonic pattern finder https://www.mql5.com/en/code/16435 written by me, so it certainly can be done yes.
An alert can be sent using the standard methods like SendMail SendNotification and Alert. Should be as simple as inserting those calls (1 line of code) in the appropriate places.
For scanning hundreds of securities, just open a chart for each one and attach the indicator.
- votes: 12
- 2016.10.12
- Andre Enger
- www.mql5.com
Yes but it has to be coded.
The easiest way is to make use of what i call, the go over value model where you hard coded a symmetric version of the pattern into the code and then compare live incoming market feed to that pattern, and every time a match has been found that represents a replica of the pattern you can have the ea give off an alert.
The problem usually is that the patterns look a lot like each other, but are never really exactly the same, so you also have to add some differential values.
The easiest way to do that is to set minimal and maximal amplitude values so that the pattern comparison becomes flexible.
Now of course new problems will arrive because when you receive the alert, the pattern has already happened so how are you planning to trade it ?
The solution could be to slice the pattern in half and have it set off the alert when it detects that the first half move has been made.
It's all relatively simple but you have to make sure that the values you use are all just right, and that takes other mechanisms to calculate them.
A quick start for example would be to analyze large breakout movements, there are questions 1.what happens always 2.what happens never, or rarely 3.what usually happens, or is expected to happen. 4. when does the value reach or go over the first leg of the pattern.etc.
So you can define standard moves and define larger moves and whenever market goes over the standard move you set off the alert.
This is the most simple form of breakout pattern recognition.
Now you can add the time scale and add that the move has to happen in X seconds, or minutes because you don't want an alert when the market moves over your value in too long a time span.
And you keep on adding filters to discriminate between wanted and unwanted criteria.
It can be done and it isn't difficult at all, but like i said you have to use the correct values else you will get too many, or too little alerts.
The codebase already has a harmonic pattern finder https://www.mql5.com/en/code/16435 written by me, so it certainly can be done yes.
An alert can be sent using the standard methods like SendMail SendNotification and Alert. Should be as simple as inserting those calls (1 line of code) in the appropriate places.
For scanning hundreds of securities, just open a chart for each one and attach the indicator.
Thanks, but I want to customize what you already offer. Is the coding already available so that I can customize it?
Appreciate it!
Tony
Thanks, but I want to customize what you already offer. Is the coding already available so that I can customize it?
Appreciate it!
Tony
Yes, click the "Download as ZIP" link on the code base link or download it directly from MT5 by searching it up in the "Code Base" tab of the toolbox.
PS: if you liked the code make sure to rate it!
Yes, click the "Download as ZIP" link on the code base link or download it directly from MT5 by searching it up in the "Code Base" tab of the toolbox.
PS: if you liked the code make sure to rate it!
Yes, click the "Download as ZIP" link on the code base link or download it directly from MT5 by searching it up in the "Code Base" tab of the toolbox.
PS: if you liked the code make sure to rate it!
Hey Andre,
How can I learn to code MQL5?
Thanks,
Tony
Hey Andre,
How can I learn to code MQL5?
Thanks,
Tony
It's more or less similar to C++, so if you can code C++ you can code MQL5.
Naturally there's more free education available for C++, you can try this https://www.sololearn.com/Course/CPlusPlus/ and just follow instructions.
- www.sololearn.com
- 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 have a strategy based on harmonic patterns like gartleys, crab, and some other customized patterns. I am thinking of learning python to hopefully implement my strategy. Would this be possible to program using MQL5 as well to create an algorithmic trading strategy? Could I also be alerted of when these trade set ups occur so I can use my discretion in entering? It would be much easier for me to implement an algorithm to scan hundreds of securities rather than spending numerous hours looking for them manually. Any advice on the steps I can take would be greatly appreciated. Thank you so much in advance!!!
EDIT: Would it possible if admin can move this to MT5's trading system section? Thanks!