3
$\begingroup$

About every introduction I've read about automatic trading writes about how well python is suited for the task.

But looking around, I've been able to find just one brooker, Oanda, which has a python api for placing orders. However Oanda is nearly only forex.

Where should I look if I wanted to place orders with stocks, options, futures in north america and european exchanges. With python and standalone (No browser Quantopian)

$\endgroup$
  • 1
    $\begingroup$ Python is good for learning, but I wouldn't use it for something with a reasonably high frequency. $\endgroup$ – John Jun 22 '16 at 17:20
  • $\begingroup$ These guys: quantopian.com $\endgroup$ – rbm Jun 22 '16 at 17:23
3
$\begingroup$

IBPy + IB Gateway + TWS and you can send order to any interactive brokers, how to setup

$\endgroup$
  • $\begingroup$ I saw a video from sentdex about IBPy, where the orders sometimes would not be placed. It seems very unstable. How used is this approach? $\endgroup$ – vandelay Jun 22 '16 at 17:40
  • 1
    $\begingroup$ I saw his video too (May/2014) if you look on IbPy respository, they are working on it. IMHO the problems was with his implemetation. you can help, posting your issues on github so the developers can make it more stable. another option is using quickfix python integration so you can send FIX orders directly and mange execution reports. example $\endgroup$ – Clebson Derivan Jun 22 '16 at 17:56
  • $\begingroup$ They offer an API for C++ as well, it does the job but it’s definitely not the best. They had errors in their own source code for examples, case inconsistencies in the makefile directories, all sorts of bad stuff. I wonder if the Python API is any better. $\endgroup$ – ofey73 Aug 17 '18 at 5:45
1
$\begingroup$

Interactive Brokers hosted a webinar on Nov. 10 2016 about Implement Algo Trading coded in Python using Interactive Brokers API. The presenter gave a good explanation on live trading using IBridgePy, which is a flexible and easy-to-use Python platform. The webinar was published by IB at youtube https://www.youtube.com/watch?v=hogXB07OJ_I

IBridgePy 's website is www.IBridgePy.com One of greatest thing is that IBridgePy can run Quantopian's codes without any changes! The tutorial of migrating from Quantopian to IBridgePy is here. http://www.ibridgepy.com/tutorials/#Migrating_from_Quantopian_to_IBridgePy

Disclaimer: Posted by IBridgPy

$\endgroup$
0
$\begingroup$

You'll be able to send orders to many more brokerages if you learn HTML request protocol and how to use RESTful APIs. For example I have written python API wrappers (scripts that convert python commands into the brokerage's protocol) that allow full trading functionality in both TradeKing and Robinhood.

$\endgroup$
0
$\begingroup$

https://github.com/mementum/backtrader

Offers you a backtester in Python and if you want to go LIVE: integration with IB

On the repository page you will find a list of similar projects using Python. Some offer also live trading

Disclaimer: I am the author

$\endgroup$
-1
$\begingroup$

Python can be used in QuantConnect and Quantopian (which connect to IB, Robinhood, and many other platforms).

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.