On Thursday, Union Pacific (NYSE: UNP) will release its latest quarterly results. The key to making smart investment decisions on stocks reporting earnings is to anticipate how they'll do before they announce results, leaving you fully prepared to respond quickly to whatever inevitable surprises arise. That way, you'll be less likely to make an uninformed knee-jerk reaction to news that turns out to be exactly the wrong move.

Union Pacific has benefited from the cost advantage that railroads have during periods of high energy prices, but the devastation in the commodities markets recently has had a negative impact on shipping volume. Nevertheless, the railroad giant has managed to turn to alternative revenue sources. Let's take an early look at what's been happening with Union Pacific over the past quarter and what we're likely to see in its quarterly report.

Stats on Union Pacific

Analyst EPS Estimate

$1.96

Change From Year-Ago EPS

9.5%

Revenue Estimate

$5.22 billion

Change From Year-Ago Revenue

2.1%

Earnings Beats in Past 4 Quarters

4

Source: Yahoo! Finance.

Can Union Pacific keep on rolling this quarter?
Analysts have reined in their expectations for Union Pacific over the past few months, reducing their earnings-per-share calls for both the first quarter and the full 2013 year by $0.09. The stock hasn't fallen as a result, but its gains of about 7% since early January have been somewhat muted.

In recent years, railroads have lived by commodity demand, and some of them have been slowly dying by commodity demand. In particular, low coal prices have been a big hit to the industry, especially for CSX (NYSE: CSX) and Norfolk Southern (NYSE: NSC), whose focus on the coal-rich Appalachian region has given them above-average exposure to the market. Yet yesterday, CSX managed to report record profits despite coal volumes that fell 10%.

Union Pacific, though, has benefited from a couple of points in its favor. First, it has never relied on coal to the same extent as Norfolk or CSX. But more importantly, Union Pacific has also moved aggressively to cash in on the potential in moving oil and other energy products by rail, especially in hard to reach areas like the Bakken Shale play.

But despite Union Pacific's strong competitive position, it has to be prepared for rivals to disrupt the industry. Back in March, Berkshire Hathaway's (NYSE: BRK-A) (NYSE: BRK-B) Burlington Northern Santa Fe Railway division said it would look at potentially converting its locomotives to use liquefied natural gas rather than diesel fuel. With a potential cost savings of up to 90%, the impact could be huge if BNSF can successfully make the conversion, and Union Pacific would need to respond quickly in order to avoid an income-destroying profit margin squeeze.

In Union Pacific's earnings report, look to see whether the company reports the same strength in chemicals for use by the energy industry that CSX reported yesterday, as well as volumes of fertilizers and phosphates. If Union Pacific can keep its volume of oil high, then it should be able to outperform its peers.

As strong as Union Pacific is, CSX remains a big rival. Still, CSX continues to face difficult obstacles due to a domestic surplus of natural gas and coal's declining popularity. To help investors better understand how CSX can deal with these challenges, The Motley Fool has released a brand-new premium research report authored by Isaac Pino, industrials analyst and transportation expert. Isaac provides an in-depth look at CSX's competitive advantages, risk areas, and prospects for the future. Simply click here now to access your copy of this invaluable investor's resource.

Click here to add Union Pacific to My Watchlist, which can find all of our Foolish analysis on it and all your other stocks.

Motley Fool contributor Dan Caplinger owns shares of Berkshire Hathaway. You can follow him on Twitter @DanCaplinger. The Motley Fool recommends Berkshire Hathaway. The Motley Fool owns shares of Berkshire Hathaway. Try any of our Foolish newsletter services free for 30 days. We Fools may not all hold the same opinions, but we all believe that considering a diverse range of insights makes us better investors. The Motley Fool has a disclosure policy.