In recent months, the stock market has rallied sharply on optimism that the economy can experience a soft landing. The S&P 500 is less than 5% below its all-time high after being down more than 20% from its peak.

While that rally means there are fewer bargains these days, value-conscious investors still have some compelling opportunities. Enterprise Products Partners (EPD 0.45%), Brookfield Renewable (BEP 0.19%) (BEPC 0.09%), and Kinder Morgan (KMI -0.64%) stand out to a few Fool.com contributors as bargains. Their lower valuations are a big reason they offer such attractive dividend yields. Here's why they believe that makes them great places to invest $1,000 right now.

Plenty of room

Reuben Gregg Brewer (Enterprise Products Partners): The 7.3% distribution yield on offer from Enterprise Products Partners today is on the high side of the midstream master limited partnership's (MLP's) historical yield range. That suggests the stock is relatively cheap right now, especially compared to 2015, when the yield was closer to 4%.

But here's the interesting part: That high yield is backed by 25 consecutive annual distribution increases. And the MLP's distributable cash flow covered the distribution by a generous 1.9 times in the first quarter. Meanwhile, Enterprise has an investment-grade rated balance sheet and a largely fee-based business supported by vital, hard-to-replace energy infrastructure. The yield is high, but it looks very well supported.

That said, growth prospects in the midstream sector aren't as robust as they once were. So the yield will likely represent the lion's share of your return. For investors looking to maximize the income their portfolios generate, that probably won't be much of a problem.

Yet, given the distribution history, unitholders are still likely to benefit from low- to mid-single-digit distribution growth over time. That should be enough to keep the buying power of your distributions on pace with, or slightly ahead of, the long-term impact of inflation.

Attractive returns potential

Neha Chamaria (Brookfield Renewable): A good dividend stock doesn't necessarily have a high yield. Instead, a stock that pays dividends regularly and grows them over time alongside cash flows is the real winner in the making.

Case in point: Brookfield Renewable, a clean energy giant that has grown its dividend at a compound annual rate of 6% over the past couple of decades or so and is aiming for 5% to 9% growth in the long term. To be sure, shares of Brookfield Renewable, both the partnership and the corporate entity, also yield an attractive 4%-plus right now.

The biggest argument in favor of investing in Brookfield Renewable is the opportunities ahead of the company, which it should be able to exploit in shareholders' favor. Brookfield Renewable is a massive clean energy company specializing in hydropower, wind, and solar, and it has a pipeline of more than 4 times the company's current operational capacity. To put a number to that, Brookfield Renewable has a capacity pipeline of nearly 132 gigawatts.

So far, management has executed well on its growth plans, so it's safe to expect Brookfield Renewable to make the most of the growth opportunities in clean energy. It already has a strong international presence and plans to invest $6 billion to $7 billion over the next five years to expand its global asset base and footprint.

This investment and its efforts to boost margins and make acquisitions opportunistically could potentially drive Brookfield Renewable's funds from operations (FFO) per share by 10% annually through 2027. As its FFO grows, so should dividends. Add its dividend yield, and buying Brookfield Renewable stock now could earn you double-digit returns annually.

A dirt cheap cash-flow machine

Matt DiLallo (Kinder Morgan): Kinder Morgan generates tremendous cash flow. The natural gas pipeline giant produced nearly $2.5 billion in cash during the year's first half. That kept it on track to achieve its full-year forecast of generating $4.8 billion in cash, or $2.13 per share, even though oil and gas prices are below its expectations.

With shares recently trading hands at around $18 apiece, Kinder Morgan sells at less than 9 times earnings. That's a bargain valuation. The S&P 500 trades at a forward price-to-earnings (PE) ratio of more than 20 times for comparison.

Kinder Morgan's dirt cheap valuation is why it offers such a high dividend yield. At 6.3%, it's one of the 10 highest in the S&P 500, where the average is 1.5%. It could turn a $1,000 investment into $63 of annual dividend income at that rate. That compares to $15 of yearly dividend income from a similar investment in an S&P 500 index fund.

The company generates plenty of cash to cover its big-time dividend. Kinder Morgan's payout ratio will be around 53% this year. That will enable it to retain all the money needed to fund its expansion projects ($2.1 billion this year) with room to spare.

The company has been using that excess free cash to strengthen its balance sheet (leverage will end the year around 4.0 times, well below its 4.5 times target) and to repurchase shares. Kinder Morgan has opportunistically repurchased $330 million of its dirt cheap shares already this year.

The company's expansion-related investments should grow its cash flow in the future. It ended the second quarter with $3.7 billion of high-return capital projects in its backlog, giving it the fuel to grow for the next few years. That should enable it to continue increasing its already attractive dividend, as it has done for the last six years. Kinder Morgan's bargain valuation and attractive income stream make it an excellent stock to buy right now.