US Treasury Secretary Janet Yellen during an armchair discussion at the Rotman School of Management in Toronto, Ontario, Canada on Monday, June 20, 2022.US Treasury Secretary Janet Yellen during an armchair discussion at the Rotman School of Management in Toronto, Ontario, Canada on Monday, June 20, 2022.

The U.S. economy is doing well, as rising energy prices, Covid-19 variant and Russia's war withUkraine have caught global markets in a vice grip.

In an interview with CNBC's Sara Eisen Tuesday, Janet Yellen said that the United States is doing well. The Treasury Secretary is in Washington, D.C. for the annual meetings of the World Bank and the International Monetary Fund.

The economy was expected to slow after a very strong recovery, but a recent jobs report showed a very resilient economy. The Bureau of Labor Statistics reported Friday that the unemployment rate fell to 3.5% in September and non-farm payrolls increased by 263,000.

Consumers, however, have been somewhat constrained by prices rising at close to their fastest pace in more than four decades.

The level peaked at 6.8% in June and has been coming down ever since the central bank instituted a series of rate hikes. Markets expect the Fed to keep raising rates until they bring inflation down.

The Biden administration wants to lower inflation because it's too high. She said there's a way to do that while keeping the labor market healthy.

Even with rising interest rates, firms have manageable debts. The Treasury is not seeing signs of deleveraging in an environment of tighter monetary policy, she said.

There are no signs that the decision to reduce oil output by the Organization of the Petroleum Exporting Countries and Russia's continued war against Ukraine are serious concerns. She said that there are different paces of monetary tightening in the U.S.

Capital flows into our safe markets can be experienced when times are uncertain because of the dollar's safe haven status. All of those things are pushing the dollar up.

Jeff Cox worked for CNBC.