August 13/Chicago/Reuters -- Dean Foods Co said it would speed up the closure of up to 15% of its factories in the face of increasing competition and falling volumes, as it reported a quarterly loss and warned of more tough times ahead.

Shares of Dallas-based Dean, known for its Meadow Gold and Dean's milk, fell as much as 9% after it said that the current quarter would be the most challenging this year.

Dean lost a large Wal-Mart Stores contract earlier this year, and an analyst warned that price pressure from retailers and competitors will not go away anytime soon.

"Commodity costs remain volatile and competitive pressures are quite intense and shows no sign of easing," Erin Lash of Morningstar Inc. told Reuters.

The company, which has divested many of its own food brands to focus on milk, lost a "significant" amount of business from Wal-Mart to a cheaper rival, although it still sells milk to the chain.

It said in February that the contract loss would lead to a small decline in 2013 milk volumes but the situation has since grown worse.

Chief Executive Gregg Tanner said the fluid milk category volume this year will likely be a bit softer than the company had previously anticipated.

"We have accelerated the severance (costs) including our plans to close 10 to 15 percent of our plants...we expect these efforts to offset the volume deleverage," chief executive Gregg Tanner said on a conference call with analysts.

The company said it planned to close eight to 12 of its factories by the middle of next year.

Dean Foods sold Morningstar, which sells coffee creamers, ice cream mixes and other dairy products, to Canadian dairy products maker Saputo Inc in January.

The company last month divested of the last of its stake in WhiteWave Foods Co , which owns brands such as Silk soy milk, International Delight and Land O Lakes coffee creamers.

Dean Foods is the largest processor and distributor of milk in the country. It says it is about five times the size of its next largest competitor.