Skip to content

Repository files navigation

FINM Computing for Finance in Python - Assignment 1

Overview

simulation and backtesting of Momentum strategy and Moving Average Crossover strategy for time series data of AAPL

Structure

  • main.py: Main script to run the simulation.
  • data_loader.py: Function to load market_data.csv data
  • strategies.py: Strategy classes - Momentum strategy and Moving Average Crossover strategy
  • models.py: Contains data models for orders and market data.
  • engine.py: Portfolio and execution logic.
  • reporting.py: Performance metrics and reporting functions.
  • performance.ipynb: Jupyter notebook for analysis and visualization.

Usage

  • Load market data: market_data = load_market_data_from_csv('./data/market_data.csv')
  • Run the main script:
    python main.py
  • Use the Jupyter notebook: Open performance.ipynb in VS Code or JupyterLab and run the cells.

Author

Joe Wang

About

CSV-Based Algorithmic Trading Backtester

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages