Git Product home page Git Product logo

pyarb's Introduction

UPDATE 2016: don't use this, it's crap :)
Hi! This is a model dependent equity statistical arbitrage backtest module for Python. Roughly speaking, the input is a universe of N stock prices over a selected time period, and the output is a mean reverting portfolio which can be used for trading. 

Please see a more complete introduction in the IPython Notebook file "PyArb Intro.ipynb". If you don't have IPython installed and/or want to just see the results, you can instead view the corresponding HTML version "PyArb Intro.html". Please note that just clicking the file in GitHub opens the raw version, so instead click the following link to see the actual notebook:

https://rawgithub.com/harpone/PyArb/master/PyArb%20Intro.html

Since this is only a backtest module, I've decided to do a "walk-forward" with the optimized parameters from this backtest. In practice this would be just another backtest but the rules are that the parameters cannot be changed to make sure there's no data snooping. Feel free to check out the progress at my homepage at http://www.heikkiarponen.net

UPDATE: Walk forward cancelled: the code is a bit broken and the backtest results should not be trusted (as if they ever could)... and needs more work anyway... 

If you have any questions, drop me an email at [email protected].

NOTE: Unfortunately I can't include the data here because 1) The files are way too big and 2) I don't think I'm allowed to (I guess it's in the TOS/EULA somewhere...). So you have to get your own data. I got some free data at thebonnotgang.com, but their data seems to be pretty dirty. I also got some paid data from eoddata.com (data format is "3F VIP Trading"), which seems to be of higher quality that TBG's. If you want the same data I was using, send me an email and maybe I can send it to you e.g. via Dropbox/Google Drive etc.

pyarb's People

Contributors

harpone avatar

Watchers

James Cloos avatar

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.