Railroad companies are probably not at the top of most investors’ wish list, but these stocks have performed superbly this year and likely represent a solid long-term investment theme.

That was underscored last year when the world’s most respected equity investor, Warren Buffet, plunked down $34-billion in cash and stock for Burlington Northern Santa Fe Co.

For example, shares of freight transporter Canadian Pacific Railway Ltd. (NYSE: CP) are up more than 19 percent year-to-date, while Canadian National Railway Co. (NYSE CNI), has risen 17.4 percent. Norfolk Southern Corp. (NYSE: NSC) has appreciated 16 percent; CSX Corp. (NYSE: CSX) has jumped more than 23 percent; while Union Pacific Corp. (NYSE: UNP) has done even better, rising almost 39 percent this year. Meanwhile, Kansas City Southern (NYSE: KSU) has skyrocketed almost 42 percent.

Some companies that service the industry have also prospered.

Trinity Industries (NYSE: TRN), a manufacturer of railway cars (among other products) has surged almost 32 percent year-to-date; while shares of American Railcar Industries (NASDAQL: ARII), another railcar maker, have soared almost 40 percent.

On the whole, the iShares Dow Jones Transportation Average (NYSE: IYT) -- which includes several railroad names among its top components -- has climbed nearly 20 percent year-to-date, while the broader market (S&P 500 index) has edged up only about 5.7 percent.

So, what gives? Why have railroads – one of the ‘oldest’ of the ‘old economies’ -- flourished this year, amidst widespread concerns about the economic recovery and global debt crises?

Don Hodges, chairman of Hodges Capital Investment in Dallas,Tex., suggests that the success of the railway stocks underscores two things: the economy in the U.S. may actually be getting better than many pessimists would have us believe; and locomotives are still the cheapest, most efficient way to move large amounts of goods across the nation and extremely crucial to commerce.

Indeed, according to the Association of American Railroads (AAR), for the first 46 weeks of 2010, U.S. railroads reported cumulative volume of 13,207,976 carloads, up 7.2 percent from last year, and 10,064,446 trailers or containers, up 14.4 percent from 2009.

However, railroads were greatly hurt during the worst of the economic downturn, as demand for the transport of goods waned. In reaction to the crisis, many companies cut costs and rationalized operations. Thus, a slimmer and trimmer organization allowed railways to capitalize when the economy started to recover and the demand for freight transportation returned; hence a mushrooming of sales and earnings growth this year.

“Freight volume is picking up,” Hodges said. “Thus, there’s greater demand to move commodities, grains, coal, as well as imports from Asia.”

Moreover, train transport is very competitive with trucking. In fact, in the event that fuel prices again rise significantly, railways would be less hurt than their trucking rivals, given the increased cost-efficiency of the trains.

Hodges estimates trains are about 3.5-times more fuel-efficient than trucks.

“It costs more to move merchandise by truck than trains,” he said. “Trucks do more short-haul transport; for long-haul, the rails are the best way to go. Railways are a great long-term investment opportunity for an investor looking for sound returns.”

Hodges is particularly bullish on Kansas City Southern, which he holds in his small-cap portfolio. He said it would make an attractive takeover candidate for a larger railway seeking to add market share and new territories.

Despite the surge in share prices this year, Hodges points out that railroad stocks remain attractively valued, with many issues trading at a forward P/E of 15 or below. Part of this is due to the fact that Wall Street does not give the sector much attention.

“Buffet’s stake in Burlington Northern certainly attracted some new attention to the railroads, it gave the industry a vote of confidence,” he said.

“But it remains an under-followed, under-covered sector of the market, therefore the modest valuations.”