The world's investors rethought the concept of risk in 2007, and the result was a vast divergence in performance among financial markets.
Suddenly, to some people Indian stocks looked safer than the U.S. housing market, long considered a pillar of security.
Speculators shied away from American junk bonds and small-company stocks but remained ravenous for commodities such as wheat, gold and cotton.
On Wall Street, as the sub-prime mortgage debacle fueled deep concerns about the long-term effects on the U.S. economy and banking system, many investors showed a new respect for blue-chip companies that appeared financially strong enough to weather whatever lay ahead.
Microsoft Corp. shares surged 19% for the year, their best calendar-year performance since 2001. Coca-Cola Co. shares jumped 27%, their best advance since 1996.
The best-known U.S. blue-chip stock indexes, however, managed only middling gains in 2007. They were weighed down by the steep losses suffered by housing- and financial-related issues.
The Dow Jones industrial average, which dipped 101.05 points, or 0.8%, to 13,264.82 on Monday, was up 801.67 points, or 6.4%, for the year.
Including dividends, the Dow's "total return" was 8.9% -- short of the double-digit gain that many Wall Street pros had expected a year ago.
The Standard & Poor's 500 index had a 3.5% price gain and was up 5.5% with dividends. That wasn't much better than what investors could have earned in a money market mutual fund.
Of course, some buy-and-hold stock investors may be glad just to have come through the year with a positive return, given what took place in the housing market and banking system.
Wall Street suffered sharp pullbacks in August and again in the fourth quarter as the housing mess worsened, losses ballooned on mortgage-backed securities, and banks and brokerages became reluctant to lend to one another.
Stocks rebounded after the Federal Reserve on Sept. 18 began to cut short-term interest rates to bolster the financial system. But the rally soon faded.
From its record high of 14,164.53 on Oct. 9 the Dow plunged to 12,743.44 on Nov. 26. That 10% decline was the index's worst slump in more than four years.
The market has rebounded again in recent weeks, but key indexes still were down sharply in the fourth quarter. The Dow lost 4.5% in the three months; the S&P 500 slid 3.8%.
Among the few market sectors rising in the fourth quarter: utility stocks. The Dow utility index rose 6.2% in the three months and 16.6% for the year. Utilities are a classic "defensive" play because they are expected to be profitable even if the economy heads south.
Investors also have continued to seek haven in U.S. Treasury securities. The 10-year T-note yield ended Monday at 4.03%, down from 4.7% a year ago. As bond prices rise the yields on the securities fall.
Now, what? Some analysts say battered investors are so poised for disappointment in 2008 that the stock market is more likely to rally than fall further.
"Even a recession really wouldn't surprise people here," said Paul Hickey, a principal at investment research firm Bespoke Investment Group in Harrison, N.Y.
He thinks stocks are relatively cheap. The S&P 500 index, at 1,468.36 on Monday, trades at about 14 times estimated 2008 earnings per share, according to data tracker Thomson Financial.
But many big investors remain cautious, fearful that the housing market crash and tight credit will drag down the U.S. economy, corporate earnings and global investors' perceptions of the prospects for American stocks.
"We want to be pretty defensive in the first half of the year," said Jack Ablin, who oversees $55 billion as chief investment officer at Harris Private Bank in Chicago. "I think there are better bargains ahead."
Here's a closer look at the performance of U.S. and foreign stocks in 2007:
* U.S. stocks: Surging market volatility and rising worries about the economy put an end to the performance edge that small-company stocks have held over big-name shares for most of this decade.
Two closely watched small-stock indexes lost ground in 2007. The Russell 2,000 was down 2.7% and a Standard & Poor's index of 600 small companies dipped 1.2% -- their first calendar-year losses since 2002.
Investors moved away from smaller stocks and toward bigger names in part because larger companies can provide a refuge amid uncertainty, analysts said.
But another factor also spurred the shift: If the U.S. economy continues to slow, multinational companies provide a way to cash in on growth overseas. And the dollar's decline against other major currencies in 2007 has helped make U.S. exports less expensive for foreign consumers.
The hunt for growth investments also drew investors to the technology sector. The Nasdaq composite index, which is dominated by big tech companies, lost 22.18 points, or 0.8%, to 2,652.28 on Monday, but was up 9.8% for the year -- its best gain for any year since it rocketed 50% in 2003, the first full year of the current bull market.