MetaTrader 5 Python User Group - the summary - page 3

 
Sergey Golubev:

hi sergey ,

do you mean that there is no way to connect strategy tester with python ? 

i'm trying to connect strategy tester with python but i didn't get useful things. 

i'll be really appreciate you if guide me to do this. 



 
jalal ahmadi:

hi sergey ,

do you mean that there is no way to connect strategy tester with python ? 

i'm trying to connect strategy tester with python but i didn't get useful things. 

i'll be really appreciate you if guide me to do this. 



I am not programmer.
I am just providing the links and and the copies of some posts to make this thread to be alive.
 

hi,

i am getting the following error when trying to wait for the terminal:



Clearly, the terminal is up and running correctly. I have just launched it with the \portable argument.

Any idea of why this is happening?


thanks in advances!!

 

Hey guys, I would just like to point out a slight bug that I found in the MetaTrader5 package for Python3.

There is an error on the data received from the MT5CopyRatesFromPos function, as the "low" price always seem to be higher than all other prices.

Example:

MT5Rate(time=datetime.datetime(2019, 9, 20, 14, 57), open=49.79, low=49.9, high=49.79, close=49.9, tick_volume=12, spread=1, real_volume=3800)

I tried to validate the data with MT5 graphs and apparently, the MT5Rate "high" field is switched with the "low".

If your method depend on these fields, be careful as they are presented backwards.
 

Forum on trading, automated trading systems and testing trading strategies

MetaTrader 5 Python User Group - how to use Python in Metatrader

MetaQuotes Software Corp. , 2019.10.20 11:29

Released an updated version of MetaTrader 5.0.7 for Python.

You can upgrade as follows:

pip install --upgrade matplotlib
pip install --upgrade MetaTrader5

Changes/fixes on the updated version -

Forum on trading, automated trading systems and testing trading strategies

MetaTrader 5 Python User Group - how to use Python in Metatrader

MetaQuotes Software Corp. , 2019.10.20 11:39

Transition from true / false results to detailed numeric codes.

Improved standby modes for data availability from the terminal.

 

Hi Can we stream bid and ask volume out via python

MT5CopyTicksFrom this function can not perform this job thx

 
cryptowhale:

Hi Can we stream bid and ask volume out via python

MT5CopyTicksFrom this function can not perform this job thx

You might try and grab an XML datafeed directly to minimize delay's.

You can also look around for one of the many API's and use JSON calls.
 
Please do not double post.
 

The announcement -

----------------

New MetaTrader 5 Platform beta build 2245: DirectX functions for 3D visualization in MQL5 and symbol settings in Strategy Tester 

MQL5: Fixed time operations in the MetaTrader module for Python integration. Now all output data use the time of the trading server to which the terminal is connected.

MetaEditor: Added ability to compile C/C++ and Python projects directly from MetaEditor. Now, multi-lingual projects can be managed using the built-in editor.

New MetaTrader 5 Platform beta build 2245: DirectX functions for 3D visualization in MQL5 and symbol settings in Strategy Tester
New MetaTrader 5 Platform beta build 2245: DirectX functions for 3D visualization in MQL5 and symbol settings in Strategy Tester
  • 2019.11.29
  • www.mql5.com
The beta version of the updated MetaTrader 5 platform will be released on November 29, 2019...
 

The library is not getting installed or even upgraded. The current version I am using is 5.0.4 and the latest is 5.0.8.

This is the log. What should I do?

Collecting MetaTrader5
  Downloading https://files.pythonhosted.org/packages/56/76/58682d9a70b8eea2a707634125fb495bf457b21fef565d2d4bac559aad94/MetaTrader5-5.0.8.tar.gz
Building wheels for collected packages: MetaTrader5
  Building wheel for MetaTrader5 (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: 'c:\python35\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\la\\AppData\\Local\\Temp\\pip-install-s2bqudzg\\MetaTrader5\\setup.py'"'"'; __file__='"'"'C:\\Users\\la\\AppData\\Local\\Temp\\pip-install-s2bqudzg\\MetaTrader5\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\la\AppData\Local\Temp\pip-wheel-6x877lgv' --python-tag cp35
       cwd: C:\Users\la\AppData\Local\Temp\pip-install-s2bqudzg\MetaTrader5\
  Complete output (10 lines):
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build\lib.win-amd64-3.5
  creating build\lib.win-amd64-3.5\MetaTrader5
  copying MetaTrader5\__init__.py -> build\lib.win-amd64-3.5\MetaTrader5
  running build_ext
  building 'MetaTrader5.C' extension
  error: [WinError 2] The system cannot find the file specified
  ----------------------------------------
  ERROR: Failed building wheel for MetaTrader5
  Running setup.py clean for MetaTrader5
Failed to build MetaTrader5
Installing collected packages: MetaTrader5
  Found existing installation: MetaTrader5 5.0.4
    Uninstalling MetaTrader5-5.0.4:
      Successfully uninstalled MetaTrader5-5.0.4
    Running setup.py install for MetaTrader5 ... error
    ERROR: Command errored out with exit status 1:
     command: 'c:\python35\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\la\\AppData\\Local\\Temp\\pip-install-s2bqudzg\\MetaTrader5\\setup.py'"'"'; __file__='"'"'C:\\Users\\la\\AppData\\Local\\Temp\\pip-install-s2bqudzg\\MetaTrader5\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\la\AppData\Local\Temp\pip-record-7ohhmuga\install-record.txt' --single-version-externally-managed --compile
         cwd: C:\Users\la\AppData\Local\Temp\pip-install-s2bqudzg\MetaTrader5\
    Complete output (10 lines):
    running install
    running build
    running build_py
    creating build
    creating build\lib.win-amd64-3.5
    creating build\lib.win-amd64-3.5\MetaTrader5
    copying MetaTrader5\__init__.py -> build\lib.win-amd64-3.5\MetaTrader5
    running build_ext
    building 'MetaTrader5.C' extension
    error: [WinError 2] The system cannot find the file specified
    ----------------------------------------
  Rolling back uninstall of MetaTrader5
  Moving to c:\python35\lib\site-packages\metatrader5-5.0.4.dist-info\
   from c:\python35\lib\site-packages\~etatrader5-5.0.4.dist-info
  Moving to c:\python35\lib\site-packages\metatrader5\
   from c:\python35\lib\site-packages\~-tatrader5
ERROR: Command errored out with exit status 1: 'c:\python35\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\la
\\AppData\\Local\\Temp\\pip-install-s2bqudzg\\MetaTrader5\\setup.py'"'"'; __file__='"'"'C:\\Users\\la
\\AppData\\Local\\Temp\\pip-install-s2bqudzg\\MetaTrader5\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\la\AppData\Local\Temp\pip-record-7ohhmuga\install-record.txt' --single-version-externally-managed --compile Check the logs for full command output.
Reason: