Giter VIP home page Giter VIP logo

recession's Introduction

When's The Next Recession?

โ›” Short the Bonds, sell the Stocks cause a recession is on it's way baby. โ›”

In the Treasury market, shorter-term interest rates this week started to move above some longer-term rates.

That can be an early warning sign of a recession, as it was in 1990, 2001 and 2007, according to a study by Bespoke. The firm said that kind of bond market move may indicate that some of the more widely watched spreads could also soon flip, or invert, a precursor to a recession.

The 3-year Treasury yield Monday moved above the 5-year yield, and it was soon followed by the 2-year. The market most closely watches the spread between the 2-year and 10-year, as well as 3-month to 10-year spread, which is the one preferred by the Fed.

Read More About This Here

So what does this project do.

Recession Gif

Basically we have a small web app here where we fetch the interest rates daily from the stlouisfed API for the 3 Year and 5 Year bonds. We then calculate the difference in the interest dates and forecast it using a D3.js

It's very much near to impossible to actually predict a recession so basically this is just for speculation.

We use the Facebook's Prophet library to do a simple time series forecasting on this data by extrapolating the curve to speculate when the next recession would happen based on the Yield Curve.

Technology

We use a small flask web app in the backend to keep the system together. We have a couple of python scripts to run everyday to fetch the daily interest data and to do the forecasting.

The forecasting is done using Facebook's Prophet. Which is really amazing in figuring out the patterns in the yield curves to give us the most likely outcome.

How to Set Up the Project.


pip install -r requirements.txt

export FLASK_APP=app.py

export FLASK_ENV=development

flask run

To Do's

  • Updating data async
  • Forecasting once a day saving, serving
  • Fix graph
  • Automate process daily
  • Auto data scraping
  • Setup D3 in Node server
  • Deploy to Docker and AWS
  • Auto train model everyday
  • Recession date calculation
  • Add superior UX/UI
  • Deploy on AWS
  • Add support for multiple bonds

recession's People

Contributors

guyandtheworld avatar

Stargazers

 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.