What happened

Shares of Pioneer Natural Resources (PXD 0.16%), Plains All American Pipeline, L.P. (PAA 0.43%), and Baytex Energy Corp (BTE -7.54%) sold off in October, each slumping double-digits for the month, according to data provided by S&P Global Market Intelligence. Driving that downdraft was a sell-off in the stock and oil markets, which took this trio down with them.

So what

Global markets took a nasty spill in October as investors started worrying about a variety of risks. The S&P 500 lost more than 7% for the month, which wiped out its gains for the year, while crude prices slumped more than 10%. That dive in the oil market weighted on most oil stocks since it affect impact their profitability going forward.

A oil pump at sunset with snow on the ground.

Image source: Getty Images.

Baytex Energy took last month's sell-off in the oil market on the chin, plunging 33% on the month. That's because the Canadian oil company is still trying to get back on solid ground after the last oil market downturn, which has made it highly sensitive to movements in crude prices. However, while lower oil prices will cut into the company's cash flow, it did have some positive news for its investors in November when it reported solid third-quarter results, fueled by its recent acquisition of Raging River Exploration. That deal enabled it to generate some free cash flow during the quarter to bolster its balance sheet, and it positions the company to produce even more in 2019. On top of that, the company announced a significant oil discovery in the Duvernay shale in Western Canada that increases its excitement about what lies ahead.

Fellow oil producer Pioneer Natural Resources also slumped last month due to the sell-off in the oil market, falling 17% on the month. However, the company has started clawing its way back in November, rebounding nearly 8% after reporting strong third-quarter results. Pioneer's production came in at the top end of its guidance range due to strong drilling results during the quarter. On top of that, the company noted that it was able to sidestep the pipeline issues plaguing peers in the Permian Basin by proactively signing firm transportation contracts for capacity on existing lines. That enabled it to earn an incremental $200 million in cash flow during the quarter, while also positioning it to continue growing production at a high rate in 2019.

Finally, oil pipeline giant Plains All American lost about 15% of its value last month amid the market downdraft. However, like Pioneer, it started bouncing back in November, rallying nearly 5% so far, thanks to its excellent third-quarter report. Because its results came in better than expected, the company was able to boost its full-year outlook. Further, given the improving oil market fundamentals and the expansion projects it has coming down the pipeline, the company provided a bullish glimpse at 2019, where it sees earnings rising another 10%. That's worth noting considering how cheap the pipeline stock is these days. With Plains All American on pace to generate $2.25 per unit in cash flow this year, it currently sells for around 10.5 times cash flow after last month's sell-off, which is well below the 12 times average of its peer group. That makes it an even more compelling stock to consider buying, especially for investors seeking a high-yielding income stream since Plains currently pays more than 5%.

Now what

Investors punished oil stocks last month because oil prices tumbled. However, while that sell-off made sense in theory for producers like Baytex Energy and Pioneer Natural Resources, it was a head-scratcher for oil pipeline giant Plains All American Pipelines because long-term contracts supply more than 90% of its cash flow, so it has limited exposure to the recent volatility in oil prices. That's why Plains' sell-off last month makes it look like an even more compelling buy, especially considering the growth it has coming down the pipeline.