It goes without saying that last quarter was rough on energy companies. The collapse in oil prices severely compressed fourth-quarter earnings, particularly on the upstream end of the oil and gas industry. These companies, such as Occidental Petroleum (NYSE:OXY) focus on discovery, exploration, and production. For these companies, falling oil prices are disastrous because the business model is highly dependent on supportive commodity prices, and Occidental was certainly not immune.

Not surprisingly, the fallout in the energy sector hit Occidental extremely hard. But while Occidental's earnings report contained a lot of bad news, the company had a few positive things to say as well. Some progress was made last quarter, including the eagerly awaited spinoff of California Resources Corporation. In addition, the company took the necessary steps to keep its profits afloat as much as possible until broader operating conditions improve.

Here's why Occidental Petroleum is down, but not out.

Battening down the hatches
It was clear Occidental's earnings report was going to be ugly. Indeed, Occidental lost $3.4 billion last quarter, compared to a $1.6 billion profit in the same quarter of 2013. Of course, the oil crash was the primary culprit. Worldwide realized crude oil prices declined by 28% year over year, from $99 per barrel to $71 per barrel. Things aren't going to get much better for Occidental in the first quarter, since oil prices continued to fall and are now much lower than last quarter's realized price.

The strain on Occidental is magnified further because the company is not cutting production. Last quarter, domestic oil production increased by 19,000 barrels per day year over year, due mostly to 42% growth in oil production from its Permian Basin operations. The company now has a well-stocked reserve. Year-end reserves totaled 2.82 billion barrels of oil equivalent, up 3% for the year, and now represent 174% of the company's 2014 production. Occidental isn't laying off the gas pedal anytime soon: 2015 production is set to grow 6%-10% from 2014 levels.

However, increasing production at a loss will wreak havoc on Occidental's cash flow, so the company will significantly reduce capital expenditures this year. The $5.8 billion in planned capital spending represents a 33% reduction from last year. While this will hurt Occidental's future production, it is a necessary step in light of the total carnage that swept through the oil and gas markets late last year.

Comfortable cash position
The company also raised cash through a number of different initiatives to help strengthen the balance sheet. Occidental spun off California Resources, sold its interest in the BridgeTex Pipeline, and monetized its position in Plains GP Holdings L.P. This all left Occidental's year-end cash balance at $7.8 billion, which exceeded its $6.8 billion of total debt. Occidental's debt-to-capitalization ratio was a comfortable 19%.

With such a healthy level of cash and a modest amount of debt, Occidental will be set up very well to capitalize on the current downturn by buying a significant amount of assets on the cheap (if it so chooses). The company could also leverage its cash-stuffed balance sheet to buy back stock, which would be advantageous given that the price of shares declined by 18% in the past six months.

Will oil recover?
Whether the stock is a buy now is largely dependent on the answer to this question. The stock is cheap at its current level -- just four times enterprise value to EBITDA -- and offers a 3.6% dividend yield, but further downside is possible if oil does not recover. Occidental's realized oil price last quarter was well above where oil sits today, which means its fundamentals are likely to be ugly once again for the first quarter.

But for brave Fools willing to buy when there's blood in the streets, Occidental is a best-in-breed operator with a strong balance sheet, a cheap stock, and pays a high dividend.