Crude prices ended 2017 on a high note, closing above $60 a barrel, which is its best level in more than two-and-a-half years. Fueling that improved pricing was a combination of factors, including OPEC's decision to keep a lid on its production through 2018 and supply disruptions from both Libya and the North Sea. Meanwhile, crude has continued to run higher in early 2018 due to unrest in Iran, which has the potential of boiling over to the point where it could disrupt supplies from that country.

That said, most analysts see these supply concerns quickly fading. Add that to the belief that oil producers will pump out more crude than the market needs through the first half of the year, and many analysts see oil falling this year, including those at Moody's who expect crude to trade between $40 to $60 a barrel. While they might be right, there's also the potential that they might be a bit too bearish on crude. Here's a closer look at the dueling views on oil, and which oil stocks can win no matter what happens.

Oil Pumps at Dusk.

Image source: Getty Images.

The bear case for oil

Several factors drive Moody's currently bearish view on oil. First, its analysts anticipate that oil production in the U.S. will continue recovering in 2018. That's not all that surprising since most domestic producers are planning to boost output this year. For example, Anadarko Petroleum (APC) expects to grow its oil production 14%, while many others anticipate growing at an even faster pace.

In addition to rising shale output, Moody's doesn't believe OPEC's compliance rate will be quite as high in 2018. Through November of last year, member nations were 91% compliant with their pledged output reductions, which was a historically high level. However, several members have routinely missed the mark, and more could join them this year, especially since oil prices are higher, which means there is less of an incentive to hold oil back from the market.

Two green oil wells sitting under a dark stormy grey sky.

Image source: Getty Images.

One thing most oil bears seem to be missing

Thanks to OPEC's production reduction agreement, the oil market drained off 500,000 barrels per day of excess supply last year because demand exceeded production. However, many analysts see that trend reversing in early 2018, with the expectation that supplies will outpace demand by 200,000 barrels per day due in part to surging shale output. That overabundance of oil would then begin refilling oil storage depots, which would likely weigh on crude prices.

That said, this estimate assumes that oil supplies around the world continue flowing as expected. While that could happen, unexpected supply disruptions have a knack for ruining forecasts. They can come out of nowhere and from a variety of issues. For example, at the end of last year, a crucial oil pipeline in the North Sea needed to be shut down for repairs, taking roughly 450,000 barrels of oil per day offline. Before that, major supply disruptions over the past few years have occurred due to wildfires in Canada, hurricanes in the Gulf of Mexico, and political unrest in Libya, Venezuela, and Nigeria. While it's anyone's guess when and where the next one will occur, the oil market currently has a watchful eye on the unrest in Iran because an escalation of violence in that country could disrupt its crude exports, causing oil prices to spike. However, that's just one of the many scenarios that could unexpectedly send oil soaring this year.

Oil pumps working the the background near a drilling rig.

Image source: Getty Images.

These oil stocks should win either way

That said, even if analysts are correct that crude tumbles this year, that doesn't mean its game over for oil stocks. While some need oil to stay above $60 a barrel to get back up on their feet, others would be just fine if crude took another tumble. Anadarko Petroleum, for example, only needs oil to average $50 a barrel to fuel its 2018 plan, and it could trim some spending if crude fell to $45 and still stay on track. Furthermore, the company has a huge cash hoard, which it's currently using to repurchase $2.5 billion in stock. Because of these factors, Anadarko can easily handle lower oil prices this year.

However, it's not alone. EOG Resources (EOG -3.90%), for example, has a vast inventory of drilling locations that can earn a 30% return at $40 oil. Because of that, EOG Resources believes it can grow oil production at a 15% annual rate through 2020 even if crude only averages $50 a barrel. Marathon Oil (MRO -0.83%), Encana (OVV -0.63%), and ConocoPhillips (COP -0.63%), likewise, can all grow just fine at $50 oil. In Marathon's case, it can increase its oil equivalent output at a 10% to 12% compound annual rate through 2021 even if oil is in the low $50's. ConocoPhillips and Encana, on the other hand, expect to grow cash flow by a compound annual rate of 10% and 25%, respectively, over the next several years, generating significant excess cash in the process.

Because of those projections, these oil stocks should significantly outperform their rivals if the analysts are correct that oil prices are about to turn over. Meanwhile, they can produce an even greater gusher of excess cash flow if they're wrong. That optionality makes them the ones investors should consider buying since they can handle anything the oil market throws their way.