Giter VIP home page Giter VIP logo

quant-lstm-onestock's Introduction

Open-quant

Open-source LSTM chain for quant

What the code is for ? This is an open source chain for testing trading opportunities, it allows to:

  • Get financial information from Quandl, and define wanted financial technical indicators,
  • Set up a LSTM model to "learn the knowledge" from the training set,
  • Then make prediction in order to provide trading signals for the test set,
  • And run Backtrader to test the strategy performance. The chain includes the following modulus:
  1. Main.py is the main code to run the different modules;
  2. A_Parameters.py defines the parameters (buy/short threshold, superparameters, train/test set etc.) for iterate testings;
  3. B_SourceData.py defines the sources of financial information and technical indicators, needed for the machine learning model;
  4. C_StructureData.py is the module allowing restructuring the data, defining the variables and labels for the supervised learning;
  5. D_ModelTrain.py defines the LSTM model architecture, and runs the training process;
  6. E_PredicAll.py allows to make prediction for the test data set;
  7. F_BackTesting.py allows to run the backtrader program, and provide backtesting results for the training and testing data sets.

How to run the code ? In order the run this chain, you need to:

  • get an Quandl key and put it into the B_SourceData.py,
  • set up python 3.5 environment
  • install libraries (keras, numpy, pandas, quandl, talib, matplotlib, sklearn, datetime, backtrader)

How to contribute ? To indicate....

quant-lstm-onestock's People

Contributors

yifeng-lin 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.