Archives for posts with tag: Investing

An automated approach to web scraping publicly traded companies’ financial statements is something that I’ve been working on for a while. My first post¬†identified the balance sheet due to a firm-specific characteristic of FCCY’s 12/31/2017 balance sheet- namely that it had a row titled “ASSETS.” Of course, not every firm is going to have this header in all caps to identify which table in the .html file is the balance sheet. But it was a start. The next, currently unpublished, step pulled the annual report and then identified the balance sheet using the summation of the number of times accounts commonly found on balance sheets were present.

Some of the issues I ran into while programming this: ¬†the amount of account variation between balance sheets of companies in different industries, the presence of extra spaces or characters present in the .html file that are not readily apparent to human eyes, the use of capital letters in account titles (or not) by different firms, and variation in how the same account may be called by different companies (e.g., additional paid in capital vs. additional paid-in capital and stockholder’s equity(deficiency) vs. shareholders’ equity vs. stockholders’ equity, etc.), financial statements being split in two across separate pages and identified in the file as two separate tables, notes at the bottom of the page with the financial statements also being tagged as tables by the issuer, substantial variation in the exact titles firms use for the various financial statements, and the actual layout of the tables after they have been scraped (e.g., multiple columns for a given year with data spread across the columns).

All of these are things that can be programmed around, and some of these issues we will see later in the post with FCCY’s 12/31/2017 10-K after we scrape it.

Read the rest of this entry »

With the exception of 2018, the S&P 500 has performed well over recent years. My question is how representative of the overall market is this? Daniel Kahneman talks about “base rates” in his book Thinking, Fast and Slow and the mistakes that people make when not correctly considering base rates in decision making.

Assuming most investors buy shares of companies they believe will increase in value, how often does this happen on average? What percentage of stocks have share prices that have increased in value each year over a given period? Naturally, this assumption ignores dividends and diversification considerations, but neither of those impact the base rate calculation.

Read the rest of this entry »