With the S&P 500 only 3% below its all-time high, finding stocks that are undervalued by the market is not easy. When the rising tide is lifting all boats, stocks that are under water from their intrinsic value likely means they're being discounted for a reason.

Usually, maybe -- but not always. There are plenty of mispricings by the market due to incorrectly reading a company's temporary problems as systemic ones. Today we'll look at three such cases where a stock has been beaten down, but its business still holds long-term promise.

Image source: Flickr via Random Retail.

Pennies on the dollar

Over the past couple of years, few companies have profited as well from the economic malaise that has afflicted the country than deep-discount chain Dollar General (DG -5.10%). As consumers struggled to regain their financial footing, they flocked to dollar stores as a means of allowing their wallets to stretch to the maximum.

Dollar General and rival Dollar Tree (DLTR -6.53%) flourished as consumers liked the dollar-or-more treasure hunt of their stores. And as they installed refrigerators and freezers to give customers a wider selection of consumable goods (items that might have carried slightly lower margins but helped boost store traffic), their sales, profits, and footprints grew.

But that all seemed to change with the second quarter as Dollar General and Dollar Tree stumbled, falling well short of analyst expectations. Shares of Dollar General have fallen nearly 30% from their all-time highs while Dollar Tree's are down an equally precipitous 25%.

The main culprit was a change in consumer perception of their value proposition, while a resurgent Wal-Mart (WMT -0.29%) refocused its energy on being the low-cost leader. Coupled with food price deflation and cuts in SNAP food stamp benefits, the retailer has been put under pressure. but those are factors that impact many discounters, including Dollar Tree and Wal-Mart. However, the long-term demand and need for the dollar stores remains intact.

Currently valued at 14 times forward earnings and at a fraction of its sales, Dollar General is worth a look.

Image source: Tractor Supply.

Plowing under growth

Rural retailer Tractor Supply (TSCO 4.61%) got hit especially hard after providing early guidance for its fiscal third quarter that saw it anticipate comparable sales, revenues, and profit all coming in lower than previously anticipated. Blaming weakness in both the energy and agricultural markets, Tractor Supply also said winter season products were falling short of expectations, suggesting its troubles might not be limited to just one quarter.

The deflation being experienced by the discount retailers is also hitting the farm equipment supplier's customers, which are comprised largely of farmers and ranchers. If farm incomes are down due to the commodity cycle hitting its low point, Tractor Supply will have a tough time selling its big-ticket items, while the consumables business will be impacted by the falling prices, too.

Yet its livestock and pet operations, which account for around 45% of its revenue, remain strong. Even though its business weakened in the current quarter, that segment still generated mid-single digit comparable-store sales increases. This will continue to assume a larger portion of its business as it grows its footprint from the 1,575 stores it currently operates, giving it a chance to pick off the higher-margin private label goods sales and increasing the amount of consumables it sells. When the cycle turns once more, it will be positioned to capitalize.

Paying a $0.96 dividend that currently yields 1.55%, Tractor Supply is planting the seeds for the payout to grow in the future.

Image source: Lear.

Bolting together a plan

Trading just a point or two below its all-time highs means auto parts maker Lear (LEA 0.92%) can't be considered a beaten-down stock, but that doesn't mean it's not still undervalued. Indeed, when it reported third-quarter results recently, it beat Wall Street expectations and raised its guidance for the rest of the year. It certainly looks like it's firing on all cylinders.

Despite that, however, Lear remains an underappreciated stock, perhaps because of the more difficult time Ford, GM, and Chrysler are having moving cars this year compared to last. Although the automakers are still selling millions of cars,  2015 was a record year when more than 17.4 million cars were sold. As of this writing, though, October auto sales are expected to fall 7% from last year, the sixth month of falling sales, a situation that hasn't been seen since the financial markets' collapse.

Lear, however, is still doing brisk business. The automotive seating and electrical distribution systems posted sales of $4.53 billion in the third quarter, beating analyst forecasts of $4.48 billion, with adjusted earnings of $3.19 per share coming in ahead of expectations of $3.02 per share.

For all that, Lear is cheap across multiple metrics. Its stock is valued at just 8.5 times future earnings, it is priced at less than half its sales, and when you compare its price to its earnings, shares trade at just a fraction of their growth potential. That suggests there is a lot of upside still in this stock if Lear's shares simply trade up to a fair market valuation.