How to Start Investing in Value as a Data Scientist

The Dos and Don’ts of Data Science in Value Investing

Photo by David Pupaza on Unsplash

Granted, the only reason I got into data science was to make money.

I did not do the doctorate. or Master because I sincerely had no scientific curiosity for the field of data science.

Really, all I wanted to do was get good at data so I could be a good investor.

So a data science certificate of completion was really all I needed.

Also, to be honest, data science and value investing don’t really go together.

The reason is that machine learning works best in a closed and predictable environment; however, the stock market is unpredictable and driven by social, political, and even environmental factors.

Perhaps you could gain the upper hand by using NLP on news articles or deep latent space learning on sudden stock price changes, but leave that to day traders.

But, if you want to invest in value, then should you give up your data science skills and just go into investing?

Definitely not!

Value investing is an art that takes years to perfect and the feedback loop is long. However, your data science skills can make this long journey more productive.

1. Use your Python, R, or SQL skills to automate financial statement data management

Photo by JESHOOTS.COM on Unsplash

Value investing emphasizes reading financial statements, and that’s a skill you need to learn separately.

However, you will soon face a challenge that is not easy to compare between financial years, as annual reports will only ever provide 2 years of data in an annual report.

There are 3 ways to approach this.

To have multiple years of financial statement data in a single dataframe, you can call it from an API, such as Yahoo Finance, and arrange the data so that it comes in a format usable. The only problem with this method is that free APIs are usually only limited to the last 4 years.

Another way, which I prefer to use, is to fill out a form while reading the annual report and selectively record certain financial values ​​on the form. You can then use python to transform the form data into something that can be interpreted.

The last method is to use computer vision to translate a financial statement into a table. I have found this method unreliable, even when using self-built, off-the-shelf computer vision products. Problems arise with white space in financial statements and accounting terminology that changes over time.

The takeaway here is to experiment with different ways to automate financial statements into a useful format.

2. Use text-to-speech to listen to annual reports

Most of the annual report is boring to read, except for the parts where you find statistical anomalies and investigate.

However, it would be foolish for you to invest solely on the basis of statistical analysis. It’s like taking care of a baby and believing it only needs food. Feeding a baby will allow him to grow healthily, but feeding will ensure healthy functioning of the baby.

That’s what reading footnotes is for. The numbers can tell you if the business is healthy, but the footnotes can tell you if the managers are doing it sustainably.

I’m pretty lazy, so what I do is use a text-to-speech app and copy and paste the footnote text into the app.

If you’re cheap or have access to a good speech training package, you can run the text through a deep learning text-to-speech API, to read the text to you.

For example, you can do this with the AWS Polly API.

Moreover, there is no point in doing NLP on annual reports. Yearly explanation writers usually copy and paste previous years and useful information is usually removed by stats-based NLP because fluff takes up a lot more space.

3. Make data visualizations

Since you won’t be using large data sets, the best way to identify patterns is through data visualization, also known as exploratory data analysis.

There are no fancy techniques here. To see if your business has become more profitable over the years, simply plot 10 years of EBIT data and find the gradient of the line of best fit.

Here is my rule of thumb.

The higher the level of the dataset, the simpler the algorithm you should use. For example, transactional data works with boosted trees, but financial summaries require one degree linear regression.

Also, I’d be lying if I told you to do this in python. Since value investing is most often about looking at just one company at a time, it’s quicker to save some data in a spreadsheet and use the built-in chart builder to create the graphic.

The only exception to this rule is that after creating multiple business analysis worksheets, you can use loops and functions to compare all of the business data at once.

Another way to do this is to make API calls from financial APIs and plot data on a chart. However, the weakness of this is that free APIs are usually limited in the number of calls you can make each month and as mentioned you will likely only have 4 years of data.

Conclusions: Does Data Science Make You a Better Investor?

In my honest opinion, yes.

What financial analysts lack is being able to be more productive with the data they have (e.g. finding better ways to understand the data), and what data scientists lack is an understanding of the accounting, and potentially, a desire to find models where there are none. to exist.

However, with a little persistence and effort, a data scientist can become a high-value investor once they understand the data they are working with. I say this from personal experience. Before, I was naive when it came to investing, but now I am cautious when it comes to investing and financial data.

Sean N. Ayres