FOR SALE: Large House in the Hamptons on 20 acres, leaky roof: $100,000/obo.

It's not likely we would find this posting as we peruse the classifieds. No matter what the problems, houses in the Hamptons just don't sell at those discounts. But sometimes tarnished stocks do.

Certainly, there was no shortage of free-falling prima donnas after the dot-com bubble burst. But high-flying stocks fall on hard times more often than you might think, and some of these prove to be very good deals. Here are five steps to help identify attractive bargain-bin opportunities.

Step 1: Look for companies with low market capitalizations.
I hesitate to put a specific boundary on the market cap; there are bargain stocks of all sizes that can provide good investment opportunities (look at McDonald's (NYSE:MCD) in April 2003). But by focusing on smaller companies, we increase our potential returns.

Why is this? First, smaller stocks tend to grow more quickly (and growth makes us happy). Second, smaller stocks that fall on hard times rapidly lose institutional support. This selling pressure often drives the price down artificially low, thus creating exciting bargain opportunities. But the institutions don't forget about these stocks. If the companies show signs of righting their ships, institutions will jump back in -- and the ride upward can be lucrative.

Step 2: Look for companies trading at significant discounts to their recent (52-104-week) highs.
By significant, I mean 50% or more. This is partly related to Step 1. Notably, we want to make sure that the weary investors have been shaken out of the stock. This includes the institutions that have lost confidence and fled to greener pastures.

But recent high valuations also provide another benefit. At one point (in the not so distant past), Wall Street recognized value in these companies' offerings. Just because the stock has tanked doesn't necessarily mean the value behind it has evaporated. Take a look at these examples:

Company Drop from previous 2-yr high to low Market cap @ low (date) Annualized gain from low to 9/10/04
Amazon (NASDAQ:AMZN) 94% $2.4B (9/01) 88%
Yahoo (NASDAQ:YHOO) 97% $5.5B (9/01) 99%
EBay (NASDAQ:EBAY) 79% $9.2B (12/00) 65%
McDonald's (NYSE:MCD) 59% $15.3B (12/00) 70%

But how do we figure out whether the value is still there? We have to take a look under the hood.

Step 3: Look for companies with a P/E ratio well below their competitors.
P/E ratios can be finicky, but they have their uses. P/E is one of most ubiquitous measures -- nearly every financial site provides individual numbers for stocks and average numbers for sectors and industries. We want to compare individual companies to their peers, and the P/E is a good way to do this. Specifically, we are looking for companies with P/E ratios well below their industry average. These companies will have maintained solid earnings during their decline and may represent strong upside potential.

Step 4: Look for companies with an EV/FCF/Growth ratio less than 0.75.
We want companies with low debt, lots of cash, strong free cash flow, and good growth prospects. The enterprise valuation to free cash flow to growth (EV/FCF/G) ratio provides a qualitative method to compare these metrics between companies. We want the enterprise valuation to be as low as possible and the free cash flow and growth to be as high as possible. This means the lower the EV/FCF/G ratio, the better. As a general rule of thumb, companies with an EV/FCF/G ratio under 1 are attractive investment opportunities. But let's add in an extra margin of safety and only consider companies with an EV/FCF/G ratio less than 0.75. That would make Warren Buffett proud.

Step 5: Look for companies that have a competitive advantage in an industry you understand.
Yowsers. This last step seems daunting, but it is really quite easy. There is sure to be an abundance of articles online explaining the company's great product from its days as a Wall Street darling.

A good place to look for this information is on Yahoo Finance (one of my favorite research sites). Go to the company's home page (by typing in the company's ticker symbol in the search box), and click on the "Headlines" link in the left side navigation bar. Go back to the days when the company was flying high, and read about why their product was so exciting. Then go to the articles written during the decline and get a measure of what problems the company faced.

Then read the company's press releases and the press' responses (from outfits such as Reuters, The Associated Press, The Motley Fool, and others) regarding recent earnings statements. How is the company addressing their challenges? This research should arm you with a basic knowledge of what's going on with the company, how serious the problems are, and what steps the company is taking to address them.

Finally, measure your knowledge of the company's target market. If the company makes computers, check your understanding of the computer market. What features do you like most on your computer? What features do you wish you had? Are your friends buying computers? Is your office investing in new hardware? If so, are they buying laptops or desktops?

All of this may seem trivial, but you are a consumer, and in the end you drive the demand for the company's products. Your observations and experiences can provide valuable insights into where the market is going.

Where to from here?
Have hankering for value? The Motley Fool's new Inside Value newsletter finds great companies at deep discounts to their intrinsic value. Check it out for free. For more Fool commentary, see Panning for Gold and McDonald's: Bland No More.

Fool contributor Jim Schoettler spends most of his time in the Mission district of San Francisco eating burritos. The agglomeration of food groups, large size, and low price tag make the Mission burrito the bargain of the food world. Jim doesn't own any of the stocks mentioned in this article. The Fool has a disclosure policy.