On the other hand, when the market price has climbed far above the fair value estimate, this may be an indication that the stock is overvalued and potentially vulnerable to any hiccups that might come along.
So instead of buying shares based on what everyone else is doing, buy a stock only when it's selling at a decent margin of safety to your estimate of its fair value. Don't even think about the overall direction of the stock market, because that's impossible to predict with any consistency. Patience is indeed a virtue when using this approach, because often it may take many months, or longer, before a suitable opportunity presents itself.
Obviously, to determine whether a particular stock is trading with a sufficient margin of safety, you must have some sort of an estimate of what you think the stock is worth. Also, you must determine how much of a margin of safety you'll require before buying a stock. If the firm is not very risky, you could be content with a 15-20% discount to its fair value. If the firm is riskier than average, you may demand a 30-40% discount. Ultimately, it's your decision and varies depending on the company in question.