GithubHelp home page GithubHelp logo

andrewczgithub / predicting-stock-market-crashes Goto Github PK

View Code? Open in Web Editor NEW

This project forked from roman807/predicting-stock-market-crashes

1.0 0.0 0.0 45.26 MB

Jupyter Notebook 99.30% Python 0.70%

predicting-stock-market-crashes's Introduction

Predicting Stock Market Crashes

Project summary

With this project I am introducing the design of a machine learning algorithm that predicts stock market crashes based on past price information. I used public available market data from seven major stock market indices. This is a classification problem to forecast whether or not a crash will occur within the next 1, 3 or 6 months at any point in time. I trained and tested linear and logistic regression models, support vector machines, decision trees and recurrent neural networks with long short term memory (RNN LSTM). For a detailed description of the problem and findings please refer to the article here

Repository organization

exploration.ipynb: Data exploration and crash definition and identification for all seven data sets.

results.ipynb: A summary of the results for training, validation and test results of all tested models. For more detail refer to the jupyter notebooks in the models directory.

models: Folder containing jupyter notebooks of all tested models. The notebooks illustrate how the models were trained, tuned and tested and present the results on the test set

data: .csv files of the daily price information of all datasets used. This data is available on yahoo finance.

final_predictor: Pre-trained logistic regression model that shows current forecasting probabilities for a crash occurring within the next 1, 3 and 6 months. Clone this repository, download most recent historical price information of any stock market from yahoo finance (at least 3 years of data), specify the filename in inputs.json and run main.py to get prediction results.

Example of crash prediction within 3 months on the S&P 500 (data used as test set) for the time between 1958 and 1976:

predicting-stock-market-crashes's People

Contributors

roman807 avatar

Stargazers

 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.