DEV Community

Cover image for Q. Quarterly Inc: A Flatiron School DS Capstone Project
Boi N Moriba
Boi N Moriba

Posted on

Q. Quarterly Inc: A Flatiron School DS Capstone Project

Guys It's Finally HERE, My Final Project

Here is the direct link to the Github if this project: https://github.com/bmor2552/QQuarterlyInc/blob/master/README.md

Here is direct link to the video presentation of the project: https://www.youtube.com/watch?v=8tBPOyyXLzE&t=11s

The Idea

I must have missed something this time around because I had on my overthinking pants for this project. Let me tell you, I underestimated the power of overthinking!!

Originally I had an idea which came from my very faint but present experience with fundamental analysis. I wanted to see if the sentiment of certain documents had an influence on the stock price change of a company.

The Process

The steps I had to take were as followed:

  1. Gather a list of companies I wanted to analyze
  2. Gather the documents of focus for the list of companies
  3. Clean the documents (stops words, html, etc...)
  4. Parse through the documents
  5. Run a sentiment analysis on the documents
  6. Compare the sentiment values to the price change in the companies

Seems simple enough right?

A-man-saying-couldn't-be-more-simple

But what if you have never done it before, and can't seem to find anyone else who has done it either? Then what?

A-drawing-of-girl-stating-she's-alone

Figuring It Out As I Go

After my project idea was approved, I got straight to work. I had an idea of how to begin because of very helpful blogger named Osho Jha. He shared the beginning steps of how to obtain the documents you want to focus on for your sentiment analysis; I chose quarterly reports. This is where the help stopped ... dun dun duuuuuuuuunnnnnnn!!

dun-dun-dun-said dramatically

Here is a link to his blog post: https://towardsdatascience.com/useful-sentiment-analysis-mining-sec-filings-part-1-358942fc98ed

This did not stop me, with the guidance of my Instructor and Coach I was able to proceed with the steps listed in "The Process", but not without overthinking for two days straight, searching for data for a week, cleaning the data for another week, and finally conducting the sentiment analysis a couple of days before my presentation/final grade is due (We had a total of 3 weeks FYI)!

a-dog-sitting-in-a-burning-house-calmly-saying-this-is-fine

To those who are more level headed when it comes to tackling a task, this may come across as complaining. But I assure you this was a test of my patience with the process & with myself.

I have been over analyzing everything since the beginning, and after 27+ years of doing this, task start to take longer then they should. Please NEVER ask me what I want to eat!

a-man-yelling-what-do-you-want

But it's ok, because through trail and error along with three different notebooks I was able to find signs of correlation between the stock price change of a company and it's quarterly reports. (See Github link at the beginning of the blog, don't be shy be curious lol)

Images Of The Results

Below you will see a scatter plot of the price change of a company and the subjectivity of the quarterly reports.

Alt Text

Below you will see a scatter plot of the price change of a company and the polarity of the quarterly reports.

Alt Text

Below you will see a scatter plot of the price change of a company and the price change of the overall market. (This is kind of obvious but also cool to plot, give me a break I'm trying here lol)

Alt Text

What's Next

Because of the timeframe I was unable to look into more companies, although I did find a way to automate the document retrieval process, something was wrong with the os.listdir method, the function kept returning only one company (got to love those for loops!). Feel free to take a swing at it if you dare!

I also did not get a chance to tokenize the reports or parse through the digits of the reports, this will be my next task after I fix the function that I mentioned above.

Closing Statement

This was one of the most frustrating, exciting, encouraging experiences of my life and I feel like I am on cloud nine! If you are interested in doing a coding bootcamp I say go for it. You will come out with a new set of skills and as a more evolved human. Sounds like a win win to me, anyways happy coding people!!

celebrity-saying-until-next-time

Top comments (0)