MOORESVILLE, N.C. (AP) — Lowe’s swung to a loss in its fourth quarter, weighed down sizeable one-time charges and a lethargic housing market.

The home improvement company lost $824 million, or $1.03 per share. That includes $1.6 billion in charges, most from a $952 million goodwill impairment charge. Stripping out the charges, earnings were 80 cents per share, a penny better than analysts polled by FactSet had expected.

A year ago the Mooresville, North Carolina, company earned $554 million, or 67 cents per share.

Revenue rose to $15.65 billion from $15.5 billion, short of Wall Street expectations.

Sales at stores open at least a year increased 1.7 percent, and 2.4 percent in the U.S.

Lowe’s Cos. on Wednesday projected earnings between $6 and $6.10 for this year. Analysts had been expecting $6.04 per share.