Investing in agricultural machinery company AGCO Corporation (AGCO 0.42%) doesn't appear to be rocket science to many investors. In common, with rivals like Deere & Company (DE 0.94%), the stock's direction is usually dictated by movements in key farming commodity prices. At the same time, investors should be open-minded to buying when others think prospects are gloomy. So, with the stock in negative territory over the last year, is now the time to buy AGCO?

Near-term risks remain
Simply put, no one likes buying a stock with deteriorating earnings, and analyst forecasts are for AGCO's earnings to decline over the next two years.

Moreover, there are three reasons why AGCO faces near-term risk.

First, despite weakening market conditions, AGCO kept its outlook unchanged in the first quarter. This raises the fear that it will miss estimates going forward. Its full-year revenue guidance of $10.8 billion-$11 billion, and full-year EPS guidance of $6.00 was left unchanged, even while there has been some weakness in South America (19% of sales in 2013). Its South American sales declined 9.3% on a constant currency basis in the first quarter, and its rival Deere & Company also saw weakness that caused it to lower its full-year guidance for South America and the CIS countries.

When pushed on the subject of maintaining guidance in the recent conference call, CFO Andrew Beck replied:

We have pulled down our expectation from South American market. I'd say everything else is pretty much the same. And the offsets to maintain the $6 target are in some operating expense reductions that we have initiated, a little more on the margin improvements ... being a little more aggressive on share repurchases than we originally anticipated.

Increased share repurchases are fine, but they can mask worsening performance. In addition, margin improvements are usually a lot harder to push through if an end market is weakening. The last point is worth considering, because AGCO has a 2% increase from pricing baked into its full-year guidance. Interestingly, Deere also has a 2% increase in pricing in its full-year guidance, which it kept unchanged from the previous quarter. Will both companies be disappointed?

Second, commodity prices appear to have worsened. For example, Deere lowered its forecasts for corn, wheat, soybean, and cotton in its last quarterly results, and fears of extreme weather have abated, causing prices to fall. Fools already know about Deere's changing prospects.

Third, the near-term emerging market weakness could weaken even further. In fact, a recent article in The Wall Street Journal outlined that signs of financial stress in China had extended to soft commodity importers. 

AGCO takes action, has long-term prospects
On a more positive note, AGCO's management is doing what it can, and actively taking action to generate productivity improvements. Indeed, AGCO expects to generate "100 basis points improvement" in its overall margins in its key Europe, Africa, and Middle East segment (51% of sales in 2013).

Moreover, 2014 is set to be a year of investment for the company, as capital expenditures are forecast to ramp up to $400 million-$425 million from $392 million in 2013. A large part of the expenditures is to expand presence in the CIS region, China and Africa, in order to support long-term growth.

The bottom line
It promises to be a difficult year for Deere and AGCO. The near-term risks highlighted for AGCO are significant, but investing isn't always about buying stocks with great momentum. Sometimes, it's a case of stomaching some near-term risk if the long-term upside justifies buying a stock at this level.

For example, If AGCO hits its $6.00 EPS target for 2014, then the stock will trade on a P/E ratio of around nine times earnings. Moreover, in a year's time, if the outlook for grain prices improves going into 2016, then the market will start pricing this into the stock. AGCO is well worth a look for long-term investors.