Stocks gain for week, inch toward all-time highs

U.S. stocks ended higher Friday after a report showed that the nation's manufacturing activity picked up more than expected in February.

The Institute for Supply Management's manufacturing index rose to 54.2, a surprise improvement from January's 53.1 and the best reading since June 2011.

The Dow Jones industrial average and Nasdaq rose 0.3%, while the S&P 500 edged up 0.2%, recovering from nearly 1% declines earlier in the day. The Dow is now less than 1% away from its all-time high reached in 2007, and the S&P is off less than 4%.

The day's gains helped all three indexes finish the week with modest gains. The Dow rose 0.6%, while the S&P 500 edged up 0.2%. The Nasdaq ticked up 0.3%.

The strong manufacturing report "takes a little bit of the sting away from the sharp decline in personal income in January," said Jim Baird, chief investment strategist for Plante Moran Financial Advisors.

The Commerce Department reported that personal income fell 3.6% in January, which was the steepest month-to-month drop in 20 years and much worse than economists were expecting. Personal spending notched up 0.2%, as expected.

In other economic news, the University of Michigan's final edition of consumer sentiment for February came in better than expected at 77.6. A government report showed that construction spending declined 2.1% in January.

Best Buy also announced that founder Dick Schulze will not buy out the retailer. Schulze, who owns about 20% of Best Buy's shares, was leading a group that wanted to take the company private. The company had given him until Thursday to present a qualified offer, but CEO Hubert Joly said the deadline passed without an offer.

Groupon(GRPN) shares rallied after the daily deals site announced that embattled CEO Andrew Mason would be replaced.