Giter Club home page Giter Club logo

metatraderforecast's Introduction

MetaTraderForecast

Project that involves training, testing, evaluating and forecasting time series forex data from MetaTrader using Sockets to connect with Python. An RNN Model of various architecture like LSTM, Bidirectional and GRU can be created. Supports CUDA Computation.

What does the project do?

MQL based Expert Advisors are attached to charts of trading platforms to make RNN based forecasts. All machine learning parameters can be tuned from the input interface of the EA. The model can be trained and exported as a serialized .hdf5 file. Tests are run simultaneously with initial train and the data is split based on Testing Part (in %) parameter. The model can be evaluated on any number of metrics as provided in the input screen of the EA. The model can be loaded to retrain or forecast any number of future bars.

Recurrent Neural Network Specs

The various parameter that can be opted for tuning the ML model are -

RNN Architecture

  • Long Short Term Memory
  • Gated Recurrent Units
  • Bidirectional LSTM
  • Bidirectional GRU

Losses

  • Mean Sqaure Error
  • R^2 Score

Optimizers

  • RMSProp (Recommended)
  • Stochastic Gradient Descent (Momentum can be specified)
  • Adam
  • Adagrad

Learning Rate

Specify amount of change to the model during each step of this search process, or the step size

GPU Computations

For faster computations, GPU can be used. CUDA Support is required. CuDNN implemented RNN layers are used if GPU is opted

Input screen of EA

Inputs of EA

Setting up the project

To run the forecaster, run the socketserver.py and wait for socket to be created. Now, attach the EA to the MT4/MT5 platform and specify the parameters for building the model. The predicted values are displayed on the same chart window.

python socketserver.py

Test GPU Support

To install tensorflow-gpu use python package manager

pip install tensorflow-gpu

If tensorflow-gpu is present, run the following commands to check

import tensorflow as tf
tf.test.is_gpu_available()

Dependencies

  • Python 3.6 or higher (dev versions not recommended, use stable releases)
  • Tensorflow 1.14 or higher
  • Keras

For GPU Support

  • tensorflow-gpu
  • CUDA 9.0 or higher (10.0 recommended)
  • cuDNN Library v7.4 or higher

Workflow

Forecast Workflow

metatraderforecast's People

Contributors

jyotimalik3 avatar kartikmadan11 avatar pratikyadavr4 avatar viveksahrawat7 avatar

Watchers

 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.