Giter Site home page Giter Site logo

mt4pycon's Introduction

โœจ The spark of light at the end of the tunnel, electrocuting โšก you, into submission of Love! ๐Ÿ’–
...and then there were mushrooms. ๐Ÿ„

Scientist, Ex-Broker and Trader

Navigating the rough seas intersecting ethics, finance and overly intelligent
technology, all while dodging the monsters in the dark depths of ignorance.

Developer - not so much, but

  • Made MT4/5 EA's, Indicator's, Scripts's and trading robots
  • Built a lot of other things...

Things I do and use, that will bore most

  • Process automation and optimization
  • For Pleasure: Python, NodeJS, JavaScript,
  • For Stat: MatLab, Octave, R
  • For Self-Torture: C++, C#, Java
  • Sometimes: ARM Assembly / Machine Code, Perl, Ruby, Go
  • Embedded Hardware Design
  • Reverse Engineer soft & hard things...

Things that waste my time (but saves your life)

  • Converting Powershell cmdlets into Bash
  • Convert any long Windows cmd/pwsh junk into one-liners
  • Constantly bothering Windows all developers to fix this or that and update their repo documentation

An occupational hazard of diverse interests

  • Machine Learning in Applied Finance
  • Deep Deep Trancendant Learning
  • Applied AI/ML/DL for Trading automation
  • Open socialized Hedge Fund management
  • High Frequency Trading (HFT)
  • High Performance Parallel Computing (HPPC)
  • Computational Simulation
  • Extremely Low Latency Systems

My Recommended Repos

Donations?

Yes, please. Almost everything I do is Free and Open Source Software (FOSS).
This means that I do not receive any income on any of my projects.
So if you find any of my projects useful and want to help keeping
them updated and alive...

Crypto Adresses
Symbol Name Address
BTC Bitcoin bc1qkcyxnerc2sa8xn8d30wkgfqy64jhcxxzf0xv05
ZEC Zcash t1aDszWfkHcSR5yjYrpjYLxj44Lfw7g9GDn
XMR Monero 43ACVrQMQ23bh99S7ohJ4cbDA7mVXwUcYRNjyVkr4t3bgqikfpvQu9i4aBeu7vmzCKJek3pkidEFMYEZ6fJpb6Y6HgPAC5m
ETH Ethereum 0x53266f143193e08B91bF943a694f8F9D9435163B
LTC Litecoin LW7Eu5omvBPRA1sXrKDtemVBrMYzFdwRAF

eabase stats

Hits Tech Blog Badge (WIP)

mt4pycon's People

Contributors

eabase avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

mt4pycon's Issues

Consider changing default installation directory

Doing pip install mt4pycon, installs the scripts in the c:\python38\scripts\ , and/or similar directories.
This may not be ideal for this use case, and could easily cause script name conflicts when using many other packages.

Perhaps suggest the user to always install in a virtualenv?

List of things ToDo

Here I leave a list of things yet needed to fix.

  • Fix (or check) default (pip) installation paths for the scripts
  • Fix double run problem/bug, when data in MT Terminal is not yet available.
  • Fix ModuleNotFoundError: No module named 'clr' error, when running from powershell after (pip install).
Traceback (most recent call last):
  File "C:\Python38\Scripts\con2mtapi.py", line 93, in <module>
    import clr
ModuleNotFoundError: No module named 'clr'
  • Update requirements for Python 3.10+
  • Update README with:
    • link to pyreadline3, since the original one does not work for Py3.10+.
    • Link to original repo
    • add/fix missing gif video
    • fix local install command. pip install -e ./
  • Update mt5api from original repo.
  • Fix pypi info by adding fulltext to setup files
  • add badge's
  • add coloring to output

con2mtapi fails when candle data not yet loaded and available

When running the script for the first time on a certain symbol and timeframe, the
candle data will not be available in the MT4 terminal buffer, so the script will fail.

The solution is to just run it again and MT4 will most likely have already downloaded the new data.
However, I have not been able to resolve this issue.

More examples for Python scripts

Would you guide and help with the following block code to get Libe tricks inside Python.

#----------------------------------------------------------
#  ToDo
#----------------------------------------------------------
#def getLiveTicks():
    # Here  be dragons
    # SymbolInfoTick
    # MqlTick tick;
    #   if (!SymbolInfoTick(symbol, tick)) {
    #      response = CreateErrorResponse(GetLastError(), "SymbolInfoDouble failed");
    #      return;
    #   }
    #SymbolInfoTick

Thank you for any kind of help.

Include most recent mtapi DLL's in pip installer

We'd like to make the usage of this very easy, so a good start is to include all the latest DLLs from the mtapi repo releases.
In order to make this happen, we need to bake in the correct DLL paths into the setup.py file among the ./libs/*.dll files.

Check where things are going:

python.exe -c "import distutils.sysconfig as a; print(a.get_python_lib());"

The trick is to add something like this:

setup(
	# [...]
	# use: --executable (or -e) to overrride "#!"  substitution
	scripts=['scripts/xmlproc_parse', 'scripts/xmlproc_val']

	# Package Data
	packages=['mypkg'],
	package_dir={'mypkg': 'src/mypkg'},
	package_data={'mypkg': ['data/*.dat']},

	# Additional Files
	#data_files = [(distutils.sysconfig.get_python_lib(), ["/path/to/the/DLL"])],
	data_files = [('', ["/path/to/the/DLL"])],
)

Where else?

All about using DLL's in python:

Add MT4 tick push to custom symbol in MT5

Using the functionality of pushing ticks from one platform (e.g. MT4) to another (MT5), we can use the already built-in MT5 custom symbol feature as explained here:

But we don't want to have to shuffle and fuck around with files, so we make a tool to push the ticks over TCP or pipe, into an MT5 EA to display external symbol data.

How can we do this?

  1. ๐Ÿšซ Using 2 EA's as Server (MT4) and Client (MT5). -- This prevents using ATAPI!
  2. ๐Ÿšซ Using MTAPI on both sides (MT4 and MT5) to internally push ticks, using a C# "bridge" app.
  3. โ˜‘๏ธ Using MTAPI on MT4 and a Python tool to push into MT5 via custom client EA (over IP port).

We chose (3), because of much less coding and already available tools.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.