GithubHelp home page GithubHelp logo

altfund / bitcoin-exchange-smart-order-router Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ianmadlenya/bitcoin-exchange-smart-order-router

0.0 2.0 0.0 4 KB

A smart order router for selling bitcoin at the exchange with the best price for amount being sold

Python 100.00%

bitcoin-exchange-smart-order-router's Introduction

bitcoin-exchange-smart-order-router

2015 C. Papathanasiou

A "smart" order router for selling bitcoin at the exchange with the best price for amount being sold.

Precisely replicates orderbooks at Bitstamp, Bitfinex, Kraken and models impact to price of Market sell order taking into account withdraw fees and comission (correct as of 26 Jan 2015).

Output is exchange which would 'win' i.e, give you highest payout for amount of btc being sold.

Exercise left to reader to use bitcoinrpc send etc to send btc to that exchange and implement hedging.

Things to consider: 3 confirmations will likely mean that by the time your btc arrive on the winning exchange, the order book will be different. You need to either hedge your position while btc are in transit or have btc ready on the other end that you can then do the accounting for.

Depends on:

https://github.com/unwitting/bitstampy
https://github.com/scottjbarr/bitfinex
https://github.com/veox/python2-krakenex

Christian-Papathanasious-iMac:/ chris$ ./smartrouter.py 50
** BITSTAMP ** our bankroll is: $15079.65
** BITSTAMP ** total fees are: $75.40
** BITSTAMP ** take home is: $15003.35
** kraken ** our bankroll is: $10924.77
** kraken ** total fees are: $54.62
** kraken ** take home is: $10869.25
** bitfinex ** our bankroll is: $15131.74
** bitfinex ** total fees are: $75.60
** bitfinex ** take home is: $15055.24
Bitfinex wins: 15055.24
Christian-Papathanasious-iMac:/ chris$

bitcoin-exchange-smart-order-router's People

Watchers

 avatar  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.