Skip to content

This project is an Algorithmic Trading Dashboard designed to evaluate and backtest trading strategies on Nifty50 stocks. It provides a user-friendly interface powered by Streamlit, allowing users to select strategies, customize parameters, and visualize backtest results.

License

Notifications You must be signed in to change notification settings

arthiondaena/Algo-Trading-Dashboard

Repository files navigation

Algorithmic Trading Dashboard

License CI Hugging Face Spaces

Description

This project is an Algorithmic Trading Dashboard designed to evaluate and backtest trading strategies on Nifty50 stocks. It provides a user-friendly interface powered by Streamlit, allowing users to select strategies, customize parameters, and visualize backtest results. The dashboard supports multiple strategies, including Order Block, Order Block with EMA, and Structure Trading.

Key features:

  • Backtesting of trading strategies on Nifty50 stocks.
  • Customizable parameters such as swing high/low window size, EMA lengths, and trade intervals.
  • Visualization of backtest results, including equity curves and trade performance metrics.
  • Support for multiprocessing to speed up backtesting across multiple stocks.

Table of Contents

Huggingface Spaces Web demo

Integrated into Huggingface Spaces 🤗 using Streamlit. Try it out Hugging Face Spaces

Installation

To set up the project locally, follow these steps:

  1. Clone the repository:

    git clone https://github.com/arthiondaena/Algo-Trading-Dashboard.git
    cd Algo-Trading-Dashboard
  2. Setup virtual environment (optional):

    python -m venv env 
    # Activation for linux
    source env/Scripts/activate
    # Activation for windows
    env/Scripts/activate.ps1
  3. Install the required dependencies:

    pip install -r requirements.txt
  4. Run the Streamlit app:

    streamlit run app.py

Usage

Dashboard Features

  1. Complete Backtest:

    • Run backtests on all Nifty50 stocks using a selected strategy.
    • Customize parameters such as swing high/low window size, EMA lengths, and trade intervals.
    • View aggregated results and detailed plots for individual stocks.
  2. Single Backtest:

    • Run a backtest on a single stock with customizable parameters.
    • Visualize signal plots and backtest results.

Running a Backtest

  1. Select a strategy from the dropdown menu:

    • Order Block: Uses order blocks to generate buy/sell signals.
    • Order Block with EMA: Combines order blocks with EMA crossovers for signal generation.
    • Structure Trading: Focuses on market structure (e.g., breakouts and pullbacks).
  2. Customize parameters such as:

    • Swing high/low window size.
    • EMA lengths (if applicable).
    • Trade interval and period.
  3. Click the Run button to execute the backtest.

  4. View the results, including:

    • Equity curves.
    • Trade performance metrics (e.g., return %, win rate, best/worst trade).
    • Signal plots for individual stocks.

Strategies

1. Order Block

  • Generates buy/sell signals based on order blocks.
  • Sets stop-loss and take-profit levels at 5% of the entry price.

2. Order Block with EMA

  • Combines order blocks with EMA crossovers for signal generation.
  • Allows closing trades on EMA crossovers.

3. Structure Trading

  • Focuses on market structure (e.g., breakouts and pullbacks).
  • Uses trailing stop-loss to manage trades.

License

This project is licensed under the Apache-2.0 License. See the LICENSE file for details.

About

This project is an Algorithmic Trading Dashboard designed to evaluate and backtest trading strategies on Nifty50 stocks. It provides a user-friendly interface powered by Streamlit, allowing users to select strategies, customize parameters, and visualize backtest results.

Resources

License

Stars

Watchers

Forks

Languages