NEW YORK/LONDON - The dollar gained slightly on Friday and remained on track for its largest weekly gain in over a month as investors eyed rising bond yields and continued to make bets on the U.S. Federal Reserve's interest rate hiking path.

The U.S. currency gained steam as the session wore on and was up against the euro and the yen but was down slightly against sterling, which regained some lost ground after a volatile session on Thursday following Britain's latest budget.

In the United States on Thursday, investors had reacted to hawkish policy maker comments with St. Louis Fed President James Bullard saying that even under a "generous" analysis of monetary policy, the Fed needs to keep raising rates as its tightening so far "had only limited effects on observed inflation."

The euro was down 0.34% against the dollar at $1.0329 after earlier rising as much as 0.29%.

The pound pared gains against the greenback and was last up 0.22% after rising as much as 0.70% earlier.

Both the euro and sterling had hit multi-month highs against the dollar earlier this week after inflation data showed an easing in U.S. price pressures.

Joseph Trevisani, senior analyst at FXStreet, pointed to hawkish remarks from Fed officials such as Bullard which "helped to thwart speculation that the Fed was nearing a pause" in its campaign against inflation, and set the stage for gains in the dollar along with U.S. Treasury yields.

"A two-day recovery in U.S. Treasury rates has given the dollar a modest improvement after last week's sharp inflation driven sell-off," said Trevisani.

Some analysts also suggested that investors may be positioning for the year-end after the dollar's strong run for the year to date.

Societe Generale macro strategist Kit Juckes wrote that "it may well be that the process of reducing positions ahead of year-end has started in earnest."

"2022 was a near perfect storm favouring the dollar, which rose on stronger growth, higher rates, terms of trade and geopolitical concerns. Liquidity conditions are deteriorating, and positions being cut back," he said.

In international politics, an explosion in Poland had created market volatility earlier in the week but Ukraine's prime minister, Denys Shmyhal, said on Friday that Russian missile strikes had crippled almost half of Ukraine's energy system as heavy fighting raged in areas in the east and south.

A top diplomat said on Friday that Russia is open to more high-level talks with the United States, but the Kremlin dismissed the idea of a summit between President Vladimir Putin and U.S. President Joe Biden as "out of the question" for now.

Against the yen, the dollar was up 0.8% at 140.32 yen.

Still, the dollar index, which measures the greenback against a basket of major currencies, was up 0.19% at 106.90 after falling 0.33% earlier in the day.

The index was recently up about 0.58% week-to-date, in its biggest gain since early October and representing a partial recouping of last week's 4% losses when U.S. inflation data triggered the index's sharpest weekly drop since March 2020.

Treasury yields were up for a second day in a row with the 10-year yield last at 3.825% after rising to 3.827%.

Earlier this week, stronger than expected U.S. retail sales data also dented speculation about easing interest rate hikes.

The Australian dollar was down 0.21% at $0.6672, below a two-month high reached earlier this week.

The New Zealand dollar, meanwhile, was up 0.28% and headed for its fifth straight weekly gain, ahead of next week's central bank meeting, at which rates could rise by as much as 75 basis points. .

(Reporting by Sinéad Carew and Chuck Mikolajczak in New York, Amanda Cooper in London and Tom Westbrook in Singapore; Editing by David Goodman and Matthew Lewis)