Question

I am on a Mac (OS X 10.9.1) and looking to combine Metatrader 4 with a C++ data processing program of my own. This program will take market information from my Metatrader and send back signals for specific instruments.

I have tested the C++ program on its own, by listening to data on a socket published by a Python program. The easiest for me would be to publish and listen to the socket from Metatrader (is this possible?) using mql4.

Alternatively, I am willing to send data and poll for signals, using a DLL-like interface. DLLs are windows specific, so how can one set something similar (e.g. .dylib) up on a Mac and is that even possible to use from Metatrader? If not possible, is it possible to use a windows DLL through a wineskin ?

If anyone has a better suggestion, I am definitely open to changing plans (I also have the code in R and Java).

Was it helpful?

Solution

Designing a serious trading infrastructure, your needs would be well if not best met by a neutral messaging layer. This alowed me to operate a cluster-based computing communicating massively parallel with a crowd of MT4 nodes.

Yes, MT4 can not only publish a low-level <socket> it can belong to a more complex "Scaleable Formal Cummunication Framework" in a very intelligent manner.

Do you wish to have a CLI-interface to command your MT4 nodes -- selectively, with a syntax & grammar of CLI-instructions ( not speaking about test-automation et al ...)?

Do you wish to have a central <syslog> daemon to off-load HFT-traffic loaded MT4 node(s) and automate + administer scripted monitoring & maintenance tasks?

Do you wish to have an external GPU-computing engine/cluster to communicate in a Client/Server manner with MT4 EA on a per-tickEvent basis?

ZeroMQ and/or nanomsg frameworks will allow you to design and develop many-to-many ( node-network-wise ) & any-to-any ( implementation language-wise ) systems.

MT4/MQL4 has a direct smart wrapper for ZeroMQ >>> thanks to Austen Conrad on GitHub MQL4ZMQ

ZeroMQ >>> thanks to it's great team has many language bindings - C/C++, Python, Java, R, Erlang, ..

so your Project may start on rock solid grounds & independent of any particular architecture gridlocks ( DLL moving sands et al )

Engineering built-ins save you a lot of time and efforts and avoid re-inventing wheel

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top