Giter VIP home page Giter VIP logo

crypto_trader's Introduction

Crypto Trader

For automatic trading on the stock exchange. Current implementation is for cryptocurrency trading on the cryptocurrency stock exchange Bitfinex.

Features: Web based. Server side: trading, collecting and storing history data, http server. Frontend: GUI, remote management, test strategy.

Overview: Current implementation developed for cryptocurrency trading on the cryptocurrency stock exchange Bitfinex. You have to have account and API Access.

Full overview might be found here

Get started:

  1. Install server and frontend. Then all interactions will go through frontend GUI.
  2. Run GUI (from Start - Anaconda3 - Anaconda Prompt): python trader/monitor_test.py
  3. Start the data collecting: Go to the last Tab and add pairs and timeframes. Start Collector. The history data will be collected for this pairs and timeframes. Note: You can trade only with pairs and timeframes that you've added.
  4. Ensure that the data collecting has been started by pushing the "Info" button. Note: You should wait a while. Check "count" for pairs, it should more than 200.
  5. You can play testing strategy before trading on testing tab
  6. Start trading: Go to the trading tab. Enter parameters and push Start button.

Installation:

Server (Ubuntu 16.04):

Connect to your server. You can do it with following command:

Create user, update packages, clone repo:

adduser --gecos "" crypto_trader
usermod -aG sudo crypto_trader
apt-get -y update
apt-get -y upgrade
apt-get -y install git nano
su - crypto_trader
git clone https://github.com/Closius/crypto_trader.git
cd crypto_trader

I recommend to set your own POSTGRES_PASSWORD and TRADER_PASSWORD in setup.sh for PostgresSql database (With setup.sh PostgresSql will be installed and a new database will be created). Set your values in server/secret_settings.py Hint: press Ctrl+X to finish editing with nano.

chmod +rx setup.sh
nano setup.sh
nano server/secret_settings.py

Run setup script:

sudo bash setup.sh

Frontend (tested on MacOs and Windows 7, 10):

Download files from this repository or clone it with Git.

Clone repository (Install before Git. Then open console and type there):

git clone https://github.com/Closius/crypto_trader.git

Install Anaconda. I use Python 3.5.2 :: Anaconda 4.2.0 (x86_64). Also tested on Python 3.6. From Anaconda you need:

requests
matplotlib
statsmodels
PyQt5 (I use 5.10)
numpy

Windows: Go to Start - Anaconda3 - Anaconda Prompt

Install PyQtGraph:

pip install pyqtgraph

Install TA-lib. For Windows you can try unofficial windows binaries for both 32-bit and 64-bit

For install (from Anaconda Prompt):

pip install TA_lib.whl

Set SERVER_ENDPOINT in secret_settings.py. Note: Do not edit other variables in secret_settings.py on frontend.

Update server

First stop trader and collector from frontend

Then go to your server and:

ssh [email protected] -p 22
cd ~/crypto_trader
git pull origin master

Check your values in server/secret_settings.py

sudo systemctl restart gunicorn_crypto_trader
sudo systemctl restart nginx

crypto_trader's People

Contributors

closius avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

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