MT5PythonIndicatorExporter
- Utilidades
- Joao Paulo Euko
- Versión: 2.10
- Actualizado: 19 noviembre 2020
Hi you, I need your help! Be my Patron, let's make it possible!
https://www.patreon.com/joaopeuko
https://github.com/Joaopeuko/Mql5-Python-Integration
Channel:
English version - Versão Inglês:
https://www.mql5.com/en/channels/Mql5_Python_Integration_EN
Portuguese version - Versão Português:
https://www.mql5.com/en/channels/Mql5_Python_Integration_PT
Free version with 5 indicators:
https://www.mql5.com/en/market/product/57574
This version has 38 indicators, 5 from the free version plus 33 new indicators.
There is a list with all the indicators below.
I believe that development in PYTHON is easier and simpler to make an Expert Advisor or any other tool that helps you to make a decision when related to the stock market.
So, I built a library in Python that makes it easy and simple to make expert advisors. It is possible to find it here:
https://github.com/Joaopeuko/Mql5-Python-Integration
This MQL5 Service uses Socket communication to send and receive data.
This MQL5 Service is the “Client-Side”, so it will only work if there is a server-side sending data to it, asking for some Indicator.
An example of Expert Advisor using sockets can be found here:
However, there are some difficulties when using python to code an expert advisor, one of these difficulties is the Indicator usage, most of it does not exist yet.
To solve that problem you can:
-
You can recreate all the indicators.
-
You can use a library that has some or all the indicators.
-
You can communicate through the Metatrader5 asking for the indicator data.
This MQL5 Service uses the indicators that are already built on Metatrader5, it just asks for the data, informing the setup first, and the service responds to it.
iCustom is not supported on this version.
This service only works with a few indicators:
-
Accelerator Oscillator
-
Accumulation/Distribution
-
Adaptive Moving Average
-
Alligator
-
Average Directional Movement Index
-
Average Directional Movement Index Wilder
-
Average True Range
-
Awesome Oscillator
-
Bollinger Bands - Free
-
Bears Power
-
Bulls Power
-
Chaikin Oscillator
-
Commodity Channel Index
-
DeMarker
-
Double Exponential Moving Average
-
Envelops
-
Force Index
-
Fractal Adaptive Moving Average
-
Fractals
-
Gator Oscillator
-
Ichimoku Kinko Hyo
-
MACD - Free
-
Market Facilitation Index
-
Momentum
-
Money Flow Index
-
Moving Average - Free
-
Moving Average of Oscillator
-
OBV On Balance Volume - Free
-
Parabolic SAR
-
Relative Strength Index
-
Relative Vigor Index
-
Standard Deviation
-
Stochastic - Free
-
Triple Exponential Average
-
Triple Exponential Moving Average
-
Variable Index Dynamic Average
-
Volumes
-
Williams' Percent Range
I built the communication using the same pattern used on MetaTrader5:
https://www.mql5.com/en/docs/indicators
The address and the port must be the same on the MQL5 Service and in the python code.
To use a service you just need to go in service, and a new one, it is near the expert advisor folder, at the button, on MetaTrader 5.
Image 1
You can use as many services you want until you reach the “Activation” limits.
Image 2
When using more than one service they might conflict, changing the port is a solution.
To be able to send data out of MetaTrader5 you first need to allow it, the “localhost” needs to be added.
-
Tools -> Options -> Expert advisors -> WbRequest (checkbox)
Image 3
It is good to know that I built that Service to work only in the “localhost.”
If you are in doubt, it uses sockets to work.
It is possible to call the same indicator with a different setup of how many times you want. However, when using too many indicators it might reduce performance.
You can see the expert advisor using indicator here:
All the indicators are defined to work with a time frame of one minute, to change it you just need to change the “time_frame.”
All the indicators have comments to make it easy to understand and know how to use it.
https://github.com/Joaopeuko/Mql5-Python-Integration/blob/master/Include/indicator_connector.py
Image 4
If you are having any trouble, please send me a direct message.