GithubHelp home page GithubHelp logo

webabhi / cryptocurrency_prediction Goto Github PK

View Code? Open in Web Editor NEW

This project forked from draichi/t-1000

0.0 0.0 0.0 6.26 MB

Algotrading and deep analysis of cryptocurrencies

JavaScript 7.55% Vue 34.67% CSS 24.49% Python 33.29%

cryptocurrency_prediction's Introduction

ubuntu windows OS

Cryptocurrency prediction

Codacy Badge

Deep tecnical analysis with ANY cryptocurrency

See also this live demo

Prerequisites

Setup

Go to configs/vars and edit these lines:

PORTFOLIO_SYMBOLS = [
    'eth',
    'xrp',
    'ltc'
]
TIME_INTERVAL = '1d'
FROM_DATE = '2018-11-01'
TO_DATE = '2019-03-18'

Ubuntu

sudo apt-get install gcc g++ build-essential python-dev python3-dev htop
# make sure you have these installed
conda env create -f UBUNTU_CPU.yml
# create env

Windows

# make sure you have a recent C++ compiler
conda env create -f WINDOWS_CPU.yml
# create env

Mac

conda env create -f MAC_CPU.yml
# create env

python plot_portfolio.py --plot_coin [COIN_NAME]
# e.g.: python plot_portfolio.py --plot_coin eth
# open the /path/to/crytocurrency_prediction/temp-plot.html file

imgs/dashboard_demo.gif

Live demos


Algotrading

registering Env

Add this to ~/miniconda3/envs/crypto_prediction/lib/python3.5/site-packages/gym/envs/__init__.py:

# Custon Env
# ----------------------------------------
register(
    id='Trading-v0',
    entry_point='gym.envs.trading_gym:TradingEnv',
    reward_threshold=2.0,

)

and paste the trading_gym folder inside ~/miniconda3/envs/crypto_prediction/lib/python3.5/site-packages/gym/envs/

Run

rllib train --run PPO --env Trading-v0 --stop '{"timesteps_total": 180000}' --checkpoint-freq 10 --config '{"lr": 1e-5, "num_workers": 2, "observation_filter": "MeanStdFilter"}'
rllib rollout /home/lucas/ray_results/default/PPO_Trading-v0_0_2019-03-26_09-40-05q0q7h143/checkpoint_20/checkpoint-20 --run PPO --env Trading-v0 --steps 1000

algorithms

Different algorithms compared (mean reward in BTC)

# to keep monitoring while the algo is trainning you can
# run one of these lines in different terminal windows
tensorboard --logdir=~/ray_results
gpustat -i
htop

terminal_monitoring


Credits

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.