Skip to content

BenStormer/Orderbook

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Orderbook

A Python implementation of a limit-matching orderbook. This orderbook supports four actions:

  • Market buys
  • Markets sells
  • Limit buys
  • Limit sells

Orders are automatically matched and trades are made if possible.

To run unit tests, first activate the virtual environment by running source ./venv/bin/activate after installing the requirements. Then, simply run pytest from the root of the repo to run tests.

The main goal of this orderbook was to get familiar with the most basic logic of an orderbook and matching engine, as well as to simply get better at OOP in Python.

Goals:

  • Integrate main functionality within Python
    • Place market "buy" and "sell" orders
    • Place limit "buy" and "sell" orders
  • Add unit tests for Python version of orderbook

Potential Future Work:

  • Allow order cancellation
  • Add logging for trades that occured

About

An implementation of a limit-matching orderbook

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages