Shares of Rex Energy Corp. fell on Wednesday after its fourth-quarter loss came in larger than analysts had been expecting as oil and gas prices fell.

The company's shares were down 89 cents, or 6 percent, to $13.65 in afternoon trading.

The company said late Tuesday that it lost almost $4.6 million, or 12 cents per share, during the quarter that ended Dec. 31. During the same period a year earlier it lost $40.3 million, or $1.10 per share, which included a loss of 21 cents per share from discontinued operations.

Revenue rose 15 percent to $15.3 million, from $13.3 million a year earlier.

Rex said its adjusted loss was $2.6 million, which works out to a loss of 7 cents per share. Analysts surveyed by Thomson Reuters had been expecting a loss of 2 cents per share on revenue of $15.6 million.

KeyBanc Capital Markets analyst Jack N. Aydin affirmed his "Buy" rating on the stock and price target of $18 per share. He wrote in a note on Wednesday that Rex's bigger-than-expected loss was due in part to higher administrative expenses as the company increases production. Rex went public in July 2007.

He wrote that the company has a good position in the Marcellus Shale, no debt, and $50 million in cash. "We expect (the company) to be able to significantly increase production, proved reserves and shareholder value," he wrote.