piker
piker copied to clipboard
(Automatic) Trading Frameworks (aka yabf)
There's quite a few all geared at different things but I figure we might as well start a list of what's been tried as well as what has multi-broker support and/or (a) reasonable API(s) and can be run without a cloud platform.
yabf = yet another backtesting framework
There's obviously going to be a lot to choose from and many different specialties.
I will not be surprised if we end up rolling our own since none of these seem to leverage modern Python's async features..
Python YABFs
- backtrader
- hey look, its feature list is documented (how refreshing)
- has a great list of alternatives (hopefully most of which we'll investigate)
- has a large client repo base (i.e. projects that use it)
- high level view of the GUI
- uses matplotlib
- unfortunately, it leverages multiprocessing + callback-hell
- there's a lighter weight wrapper project,
fastqantthat has this medium pamp :roll_eyes:
- quantopian's
zipline- the gold standard in python algo trading :roll_eyes:
- they have an online web platform (with an IDE) that let's you do "online trading"
- some coolio's made a live trading version, zipline-live
- a pipeline system for peppering over the fact they don't have a streaming / async system underneath or care about generators...
- they do have a ton of very cool quant libs including alphalens, pyfolio and qgrid
- jesse-ai/jesse
- intro blog post talking about the simple design genetic algo for feature optimization
- starter forum
- amazing set of indicators mostly implemented with
numpy/ta-lib - uses the
peeweeORM for storage - interesting set of trading models
- some neato data generators
pylivetraderfrom alpaca- clearly focused for using alpaca as lone broker
- works on a modified version of quantopian pipelines called pipeline-live
- support for persistent storage via redit
- Quantconnect's
Lean- biggest oof is it's mostly C#
- Rob Carver's
pysystemtrade- he has a cool blog all about it.
- QTPyLib which has quite a cool set of features:
- has support for live data and trading with IB
- uses
zeromq - has sms notifications via twilio
- actual notion of common professional tools (like [blotters])
- has a really strange async system that's for whatever reason re-written in this
- freqtrade (another crypto callback soup) but, GPL3
- docs
- has an included "hyper-optimization" subsystem for tuning signal/indicators
- cool org
GUI YABFs
- backtesting which internally uses
bokehfor plotting pyalgotraderwhich is an english port of the famous chinese vnpy- also uses
pyqtgraphfor charting (though not sure if supports real-time quotes; should be a lot of useful code in there tho) - author has some interesting S / R tooling work
- also uses
- of course Quantdom which is the project I based the current charting code on :partying_face:
I've got to say my main issue with most of these ^ is the overuse of classes to define both strategies and the data flow model.
- [x] TODO section on projects with UIs.
List I've got so far:
- backtesting which internally uses
bokehfor plotting pyalgotraderwhich is an english port of the famous chinese vnpy- also uses
pyqtgraphfor charting (though not sure if supports real-time quotes; should be a lot of useful code in there tho) - author has some interesting S / R tooling work
- also uses
- of course Quantdom which is the project I based the current charting code on :partying_face:
vectorbt also looks interesting, in the sense it's not using pandas 😂
Probably worth some digging and peeking. Found it at this reddit thread.
https://docs.nautilustrader.io/index.html is notable for having lower level components in cython and rust but it's still got a gnarly callback API.
Decent integration set including ib.