Investors showed renewed confidence in the railroad industry on Tuesday, sending the Dow Jones U.S. Railroads Index soaring up more than 150 basis points. Railroads outperformed even the unusually strong Dow Jones Industrial Average, which gained a none-too-shabby 95 basis points on industrial production figures that were better than expected.

The sector has been troubled over the past month after major Class I carrier Norfolk Southern (NSC -3.83%) lowered its earnings outlook, with railroads losing between 5% and 10%. However, earnings reported by CSX (CSX -2.90%) after the closing bell confirmed suspicions that this sell-off was overly pessimistic, and railroad stocks could be seeing a rally.

In mid-September, Norfolk Southern projected that its third quarter earnings would come in between $1.18 and $1.25 per share, blaming lower volumes for coal shipments, which historically provide nearly a third of revenue for both Norfolk Southern and CSX. This earnings figure was 24%-“28% below consensus analyst estimates of $1.68 per share. Such a significant underperformance caused several major ratings firms to downgrade an entire slew of railroads, as observers assumed Norfolk Southern's problems were endemic to the industry.

Because Norfolk Southern and CSX share similar geographies, markets, and volume compositions, if Norfolk's estimates were representative of all railroads, CSX should have seen similar declines. Instead, CSX saw revenue decline only 2% on similarly weak coal volumes, virtually flat with analyst expectations of a 1.7% decline. Despite this slight loss, CSX's cost-cutting measures and successful share buyback program actually allowed the company to beat analyst expectations on earnings per share, delivering $0.44 compares to consensus estimates of $0.43.

"CSX continues to respond well to moderating economic conditions and challenges in our domestic coal business," said Michael J. Ward, CSX chairman, president, and chief executive officer. "The company is driving strong safety, customer service and productivity results while building its capabilities for the long term."

While shares of CSX closed at $21.63, a 0.8% gain, after-hours trading has pushed the stock up as high as $22, representing a 2% gain from its opening price. Norfolk Southern's shares were relatively still, up 0.2% in Tuesday's trading, but CSX's earnings put Norfolk Southern's gloomy outlook under a spotlight. How shares open on Wednesday should indicate whether investors believe Norfolk Southern was too pessimistic and trying to downplay expectations, or whether the company really is underperforming because of poor execution.

Leading the Dow Jones Railroad Index were carriers less reliant on coal. The best performer in the index was Providence & Worcester (NASDAQ: PWX). The New England-based railroad climbed more than 4%. Strong industrial output numbers may have boosted the small regional carrier as it relies more heavily on automobile and other manufactured goods than larger railroads.

Out of big Class I operators, the two best performers were the two railroads reporting earnings next: Kansas City Southern (KSU) and Union Pacific (UNP -1.94%), up 3.5% and 2%, respectively. With both railroads deriving more than a quarter of revenue from industrial products and automobiles, the day's strong manufacturing output numbers may have helped them. Investors will get to see how the two have actually performed when they report earnings Thursday. Good results could trigger (or sustain) a strong rally throughout the sector.

If you want to build a position in the dependable, dividend-paying railroad industry before the earnings season gets into full swing, you can learn more about the near-term threats and long-term advantages of the railroads industry for free by clicking here. Besides shedding some light on the dynamics of the industry-at-large, we'll also give you the name of 1 railroad stock poised to deliver.