This post is more than two years old and may contain outdated information.
May 16, 2020
The stock market is a chaotic and emotional place, so just because something is bought or sold at a certain price one day does not mean that this is its actual value the next day (or even same day). A rational investor would expect their investment to increase in value or at least expect to be paid back something of equal value. In short, the rationale is that you can pay a low price (cheap) for something with a high value but also pay too much (expensive) for something with a lower value. However, the actual value may only be determined by each person (subjective theory of value), where some investor could value something a lot higher than someone else. However, and in the context of stocks and the stock market, it is somewhat safe to assume that most participant want their investment to increase in value.
Assuming most investors want to increase the value of their investment, such as buying undervalued stocks and selling overvalued stocks, the overall stock market should be fairly efficient at determining value (efficient-market hypothesis), so the current valuation of most companies would be near its actual value as determined by thousands of stock market participants. However, fairly efficient is good enough to find opportunities, especially on foreign exchanges, smaller or very niche markets, or anywhere where there might exist some information asymmetry (you know more than anyone else).
Determining the value of a company is the problem. Most investors have their own unique process based on traits such as personality, experience, or goals. One approach is to consider buying stock as buying the whole company, where the investor own all the outstanding shares. In this case, the value would be whatever you paid for all the shares, which could be something like the value of all assets, but more realistically a combination of its assets and estimated future earnings (as adjusted for inflation and risk). One simple method to estimate future earnings is to represent earnings as a function of revenue and cost, where most margins should get better over time (this is typically the goal of management). For most companies, it is often safe to assume a slowing growth over time, but improved margins and earnings.
The income statement contains all data needed to estimate earnings. Revenue is the key metric. It is also important to keep an eye on potential non-cash expenses, such as stock-based compensation (SBC), which can be misleading. It is common to exclude SBC if significantly larger than other expenses, otherwise the impact on earnings could make the company seem in a very bad position cash-wise. Ratios and tax can be used to make sure that your estimation is realistic, such as gross margin, operating margin, and tax rate. Ratios should not change too much unless there is some explanation. Over time, gross margin should decrease due to competition and operating margin should increase due to maturity, i.e., more efficient.
The balance sheet is important to make sure that the company have enough cash to cover any short-term liabilities. The cash-flow statement is important to make sure that the company is financially stable (net income could be negative with positive cash flow), where cash generated by the company should approximate the reported earnings over time (Free cash flow).
You should use Microsoft Excel to build a financial model (not financial advice though). A column is quarter, just copy the layout in earnings reports. It is important to input several years of previous earnings before attempting to estimate future earnings. This process takes time, and your forecasts are more accurate with specific knowledge about company or industry. Investors need to consider likelihood of various events, sales targets, new products, and so on. A good model would estimate revenue and expenses for at least a couple of years into the future, then assume lower or negative growth, every year, until earnings are close to zero. which could be many years into the future.
The net present value (NPV) is the sum of the discounted cash flow, which is the estimated future earnings. The discount rate is typically in the 0-10% range, but this varies. Discount rate represents the risk compared to alternative investments, including not investing at all. An example discount rate could be the risk-free rate, i.e., time preference, plus some risk premium, which would reflect the risks to future earnings, your minimum expected return, or relative risk compared with peers. The discount rate should be higher than interest paid on bonds or other debt in the company. The NPV plus net cash is what you should pay for the whole company, so divide by shares outstanding to get price per share.
Buying and selling is not as complicated as building a model but more challenging mentally. In general, you should buy when your financial model seems accurate, risk is tolerable, and current market price is lower than the estimated price per share, or lower than estimated price per share with some margin of safety. You should sell, or short sell, when current market price is higher than the estimated price per share. Another approach is to buy shares in companies with the best models (most certain about risks or information) or with highest potential return within an industry, subset of industry, or even more specific set of securities (universe of securities), and sell the worst, or most overvalued compared to rest in set. Again, not financial advice.