The stock market has crushed some bears over the past six months. That doesn't mean it's too late to join the party -- as long as you pick the right stocks.

With the S&P 500 back above 1,000 again, you might think that if you've missed out on the rally that has taken the U.S. stock market up 50%, you must also be too late to find any bargains. But nothing could be further from the truth.

A tale of two markets
When the big market averages seem to go up every day, it's tempting to think that every stock is rising with them. Certainly, plenty of well-known stocks have seen their share prices multiply, even in the early stages of the rally. In many cases, stocks that had been left for dead came back the strongest. Moreover, there's no denying that the vast majority of stocks have logged at least some gains since the market's lows in early March.

Yet as odd as it may seem, only a portion of the overall market has seen the biggest advances. You can still find many high-quality stocks that really haven't seen much if any gains from earlier this year. Take a look at these companies:

Stock

CAPS Rating (out of 5)

6-Month Return

P/E Ratio

Dividend Yield

Abbott Labs (NYSE:ABT)

****

(16.2%)

13.2

3.5%

AT&T (NYSE:T)

****

8.3%

12.6

6.4%

Campbell Soup (NYSE:CPB)

****

3.8%

14.5

3.3%

ExxonMobil (NYSE:XOM)

****

(3.7%)

11.1

2.4%

McDonald's (NYSE:MCD)

****

2.9%

15.0

3.6%

SYSCO (NYSE:SYY)

*****

8.6%

13.9

3.9%

Waste Management (NYSE:WM)

****

4.5%

15.9

3.9%

Source: Motley Fool CAPS. As of Aug. 20.

What's wrong with these well-known, widely held stocks? None of them are particularly expensive. They're all well-regarded by the Motley Fool CAPS investor community. And they all pay fairly high dividends. In many ways, these companies have a little of everything to investors. So why aren't they skyrocketing with the rest of the market?

The answer is simple: Most investors just follow the herd.

Everybody loves a winner
One of the toughest things for investors to do is to stick to their convictions when the market moves against them. No matter how much research you do, and no matter how convinced you may be that you've found great long-term stocks, there's nothing more discouraging than seeing the stocks you've just bought fall in value, or fail to keep up in a booming market.

Conversely, many investors see the market as validation that they've been smart with their stock choices. Even now, you can hear lots of people gloat about having picked up junk stocks this spring, reaping huge profits. It makes you wonder whether they've convinced themselves that their picks are actually good long-term investments, rather than just an opportunistic trade that happened to go their way.

Regardless, my main point here isn't to put down those who've made money from the rally. Instead, the many good stocks that got left behind spell great news for those who've been sitting on the sidelines. There are still good opportunities if you're looking for a way to get back into the market.

Stay on target
More importantly, though, it's vital that you not expect the big gains that many of the more speculative stocks in the market have enjoyed to repeat themselves. Although riding a stock from $1 to $10 may have proved to be worth the risk this time around, there's little reason to expect that stock to go from $10 to $100 anytime soon.

Even if we have seen the beginning of the next bull market, long stock advances typically see their leaders rotate over time, as leaders fall back and laggards catch up. The crowd may be pumping up the market's best recent performers, but if you're trying to get your portfolio back on track, some of the great stocks that missed the rally are more likely to give you the results you want over the long run.