Skip to content
forked from gbeced/basana

A Python async and event driven framework for algorithmic trading, with a focus on crypto currencies.

License

Notifications You must be signed in to change notification settings

HappyQuant/basana

 
 

Repository files navigation

Testcases PyPI version Read The Docs License Downloads

Basana

Basana is a Python async and event driven framework for algorithmic trading, with a focus on crypto currencies.

Key Features

  • Backtesting exchange so you can try your trading strategies before using real funds.
  • Live trading at Binance and Bitstamp crypto currency exchanges.
  • Asynchronous I/O and event driven.

Getting Started

Installation

The examples use TALIpp for the technical indicators, pandas and statsmodels.

$ pip install basana[charts] talipp pandas statsmodels

Backtest a pairs trading strategy

Download historical data for backtesting

$ python -m basana.external.binance.tools.download_bars -c BCH/USDT -p 1h -s 2021-12-01 -e 2021-12-26 -o binance_bchusdt_hourly.csv
$ python -m basana.external.binance.tools.download_bars -c CVC/USDT -p 1h -s 2021-12-01 -e 2021-12-26 -o binance_cvcusdt_hourly.csv

Run the backtest

$ python -m samples.backtest_pairs_trading

./docs/_static/readme_pairs_trading.png

The Basana repository comes with a number of examples you can experiment with or use as a template for your own projects:

Note that these examples are provided for educational purposes only. Use at your own risk.

Documentation

https://basana.readthedocs.io/en/latest/

Help

You can seek help with using Basana in the discussion area on GitHub.

About

A Python async and event driven framework for algorithmic trading, with a focus on crypto currencies.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%