2017 winners and losers: Amazon, Boeing soared; GE plunged

It was a strong year for the stock market, but 2017 was a great year if you made airplanes (think Boeing), were an online juggernaut (Amazon) or built homes (KB Homes). It was a year to forget if you were an energy company (Chesapeake) made Barbie dolls (Mattel) or if you were a storied industrial conglomerate about to go on a radical slim-down program (General Electric).

The stock market had a banner year overall, but there were plenty of big winners, and big losers, among individual U.S. companies. Here's a look at a few of them.

THE WINNERS

— THE MIGHTY AMAZON:

Amazon's gain of 56 percent in 2017 was hardly shabby, but that number only begins to tell of the enormous effect the company had on the broader market. No other company struck as much fear in its rivals, or potential rivals.

Department stores and mall-based retailers continued to plunge as Americans did more of their shopping at Amazon, while other companies like Walmart raced to build up their own online offerings. And when Amazon snapped up Whole Foods in June, investors dumped the stocks of supermarket companies, certain they'd take a shellacking from their new competitor.

Blue Apron, a startup that went public in June, took a dive when Amazon got into the meal kit business. And in the fall, a number of drugstore companies tanked at the prospect that Amazon was thinking of getting into drug distribution.

— BOEING TAKES FLIGHT:

Boeing soared 89 percent, one of its best years on record. The aerospace giant has benefited greatly as the global economy kicked into a higher gear, increasing demand for airplanes. The U.S. economy continued to grow, while major regions like Europe and Japan did better than they had in recent years.

At the same time, military spending in the U.S. is expanding again. It had been declining as combat operations in Iraq and Afghanistan wound down. Late in the year, Boeing became the highest-price stock on the Dow Jones industrial average, giving it more influence on the blue-chip index than any other company.

— BREAKING GROUND:

Homebuilders made huge gains for the year as housing prices continued to rise. There are relatively few homes on the market, but demand is strong thanks to the growing economy, solid hiring, and low mortgages rates. Late in the year, sales of new homes reached a 10-year high, and many economists think the trend will continue in 2018.

The companies dramatically outperformed the market. NVR and KB Home both doubled, and PulteGroup and D.R. Horton rose almost as much. Without a lot of houses for sale, people also spent more money on home improvement. That was good for Home Depot and Lowe's.

THE LOSERS

— GE'S DIMMING FORTUNES:

The icon of U.S. industry saw its stock price slump 45 percent as investors wondered what its future will look like. GE health care executive John Flannery replaced Jeffrey Immelt as chairman and CEO as Immelt's 16-year tenure came to an end. Soon after he took over, Flannery said GE will shed about $20 billion in businesses over the next few years. He said 2018 will be a "reset" for GE as the company narrows its focus down to aviation, health care and energy. GE slashed its dividend for the first time in decades, its chief financial officer and two vice chairs departed, and its board will shrink from 18 to 12.

— FLAGGING ENERGY:

Crude oil spent most of 2017 trading in circles, and energy companies faded after a big gain the year before. While oil prices are stronger than they were and energy companies have cut spending, it's hard to see what would make oil prices go higher and stay there. U.S. crude rallied late in the year, and on Dec. 29 it settled above $60 a barrel for the first time in two and a half years, but analysts think that if prices did peek above their current levels, companies — especially shale oil firms in the U.S. — would start producing more oil, which would knock prices down again.

Among energy companies, Baker Hughes dropped 51 percent. Hess fell 24 percent and Exxon Mobil lost 7 percent.

— FADED FUN:

Mattel didn't have much fun in 2017 either. Rival toy maker Hasbro continued to benefit from a partnership with Disney, as Hasbro's quarterly sales topped Mattel's at least twice. Mattel had outsold Hasbro every quarter for 17 years. In September retailer Toys R Us filed for Chapter 11 bankruptcy protection, which hurt both companies. But even with those problems and growing numbers of kids picking tablets over toys, Hasbro had a strong year and rose 17 percent. But Mattel plunged 44 percent. Its only real bright spot came in November, when the Wall Street Journal reported that Hasbro made an offer to buy Mattel. But those gains faded as Mattel reportedly rejected that overture.