The Dow, S&P 500, Nasdaq and Russell 2000 each hit new all-time highs Monday.

Investors are giddy with excitement and they clearly believe that both big blue chip multinationals and smaller companies that do most of their business in the U.S. will continue to thrive.

So is this the Donald Trump rally? Or the Janet Yellen rally?

Some strategists believe Trump's stimulus plans and talk of killing many burdensome regulations are the reasons stocks are soaring.

Or perhaps this is better characterized as a continuation of the Barack Obama rally instead?

You could argue that POTUS 44 has dealt POTUS 45 a pretty good hand.

The solid job market and overall economy that Trump inherited may be the reason consumers and businesses are so confident.

But investors (and financial journalists) are often quick to give the president more credit -- and blame -- than they probably deserve for the performance of the stock market.

RBC strategist Jonathan Golub pointed this out in a report on Monday, one that was aptly titled "Message to Market: It's Not All About Donald."

Related: Trump isn't killing the bull market

Golub noted that the S&P 500 rose nearly 7% from late June through Election Day -- a time when most polls were predicting that Hillary Clinton would be the next president.

But stocks have continued to rally since then, rising another 8% since Trump pulled off the upset (at least to the mainstream media and Wall Street) victory.

You can't have it both ways. It makes no logical sense to suggest that stocks rallied because investors believed Trump would lose and that they continued to rally because Trump didn't lose.

Bond yields have also been rising since Trump won, a phenomenon that many investors have attributed to the likelihood of stimulus from the president and Republican Congress.

Yet Golub points out that the yield on the 10-year U.S. Treasury was going up during the late summer as well.

Of course, many investors were expecting stimulus from Clinton too.

Yet once again, many investors are claiming that Trump is the catalyst for something that not only was going on before he was elected, but was happening because many thought he would lose.

Related: Stocks have avoided a 1% dive for an unusually long period of time

So it's odd that Trump is being cited as the main reason for a market rally that began months before anyone felt he could win.

What's really going on? The one constant during the past few months is the Federal Reserve.

Yes. the markets are reacting to Washington. But they are paying closer attention to Janet Yellen, not the White House.

The Fed made it crystal clear before the election that it would probably raise interest rates in December and do so a few more times in 2017 regardless of who won the race for president.

The good news for investors is that the U.S. economy seems to be growing steadily, but does not appear to be at risk of overheating.

Related: Here's why the world's largest money manager is worried

The most recent jobs report showed that wages grew at a decent rate of 2.5% annually. But that's not nearly high enough to spark fears of runaway inflation and lead the Fed to aggressively raise rates.

Even if Yellen and the Fed hike rates three times this year, they are likely to do so by just a quarter point every time. That would push the Fed's key short-term rate to a range of 1.25% to 1.5%.

That's still extremely low. At those levels, stocks would still be more attractive than bonds. Corporate earnings should be able to keep rising at a healthy clip. And consumers would probably keep spending.

So investors would be wise to keep a close eye on Yellen and not just have a myopic focus on the president,

With that in mind, Yellen is set to testify in front of Congress on Tuesday and Wednesday. And what she says about the timing and magnitude of future rate hikes could wind up keeping the rally going full steam ahead -- or stopping it dead in its tracks.