Commodities have been looking better since January. Oil, gold and silver and numerous other high-profile materials have waged double-digit recoveries. While that may be faint praise given the incredible beating commodities investors took in the previous three years, consider the alternative.

Stocks have been staggering downward from their record high this summer, and there is little talk of the market staging a long rally. Indeed, the S&P 500 Index is up a mere 4% for the year, and the second-longest bull market in history has analysts shouting about its vulnerability.

To be sure, investing in commodities is highly risky. Trading corn, copper, lumber, natural gas or heating oil futures requires a Zen-like tolerance for volatility and loads of ready cash to meet the potential margin calls that loom in the background.

Nor is their long-term prognosis necessarily good. Many experts see the past as a better indicator of their prospects than the present because they anticipate a long-term glut across the commodities spectrum.

Still, diligent investors are not without opportunities to invest profitably in commodities. Their best bets are in buying mutual funds or ETFs that have portfolios of natural resources companies or by investing in the individual companies that produce the commodities that are having the strongest recoveries.

TheStreet Recommends

While commodities trade at whatever price the market assigns them, companies can build on the price rebound to increase their profitability by investing in their company, making acquisitions, grabbing market and becoming more efficient. As might be expected, stocks of companies that get the biggest bounce often produce the commodities with the biggest price gains.

The results can be impressive. For example, the returns of the Goldman Sachs S&P Natural Resources Index ETF (IGE) - Get iShares North American Natural Resources ETF Report , which tracks the companies that produce commodities, are double those of the Goldman Sachs Connect S&P Enhanced Commodity Total (GSC) - Get GS Connect S&P GSCI Enhanced Commodity TR Strategy ETN Report , which tracks commodities, this year.

A number of funds have picked impressively from the huge supply of natural resources companies. Among the stand-outs are the VanEck Global Hard Assets Fund Class A (GHAAX) - Get Van Eck Global Hard Assets A Report and GMO Resources Class III (GOFIX) - Get GMO Resources III Report . They are up 38% and 31%, respectively, this year.

However, both are heavily front-loaded (i.e. 5% plus) and have expense ratios over 1%. Investors looking for lower costs, reasonably good gains that could likely hold up better over the years might want to invest in Vanguard Materials Index Fund Admiral Shares (VMIAX) - Get Vanguard Materials Index Adm Report . It's up 10 percent this year, but has no load and a rock bottom expense ratio of 0.1%.

Among the commodities that have stood out this year is zinc, tin and lumber. So too have some companies that produce them. Teck Resources (TCK) , a zinc producer, has gained a staggering 382% this year. It may not be done yet either since it would need to gain nearly as much again to reach its high.

Silver Standard Resources (SSRI) , a tin producer, is also a triple-digit gainer, while Universal Forest Products (UFPI) - Get Universal Forest Products, Inc. Report , a wood producer, is up a mere 43%. Safe to say that should the coming years be anywhere as good as the present year, investors will be happy with these investments.

This article is commentary by an independent contributor. At the time of publication, the author held no positions in the stocks mentioned.