Coder Social home page Coder Social logo

markettimeseriessideprediction's Introduction

Weekly Market Direction Prediction

Overview

This project involves the analysis of weekly market data with the goal of predicting market direction ('Up' or 'Down'). The data spans from 1990 to 2010 and includes various lag variables, volume, and the direction of the market.

Data Description

The dataset contains the following columns:

  • Year: The year of the observation.
  • Lag1 to Lag5: The percentage returns for each of the five previous weeks.
  • Volume: The number of shares traded (in billions).
  • Today: The percentage return for this week.
  • Direction: The direction of the market movement, either 'Up' or 'Down'.

Objective

The primary objective is to build models that can predict the weekly direction of the market ('Up' or 'Down') using various statistical and machine learning techniques.

Methodology

We employed several methods to achieve our objective:

  1. Logistic Regression
  2. Linear Discriminant Analysis (LDA)
  3. Quadratic Discriminant Analysis (QDA)
  4. K-Nearest Neighbors (KNN) with k=1

The models were trained using the data from 1990 to 2008 and tested on the held-out data from 2009 and 2010.

Results

The performance of the models was evaluated based on the accuracy and the confusion matrix. The key findings are:

  • Logistic Regression and LDA both achieved the highest accuracy of 62.50%.
  • QDA showed a lower accuracy of 58.65%, with a tendency to predict 'Up' movements.
  • KNN (k=1) had the lowest accuracy of 49.04%, indicating less effectiveness in this scenario.

Conclusion

Linear Discriminant Analysis (LDA) appears to provide the best results on this data, closely followed by logistic regression. Both QDA and KNN (k=1) showed lower effectiveness. The modest accuracy of the best models suggests that predicting market direction might be inherently challenging with the given variables, or additional predictors and more complex models might be necessary for improved performance.

Future Work

Further analysis could explore:

  • The inclusion of additional predictors.
  • More complex models or ensemble techniques.
  • A deeper analysis of market conditions and external factors that might influence the market direction.

markettimeseriessideprediction's People

Contributors

samousavizade 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.