NEW YORK (AP) _ The dollar rose in light trading Wednesday, but analysts warned that the impending release of U.S. trade figures posed another major test for the currency.

Gold prices rose slightly. Republic National Bank in New York quoted a bid for a troy ounce of gold of $461.40 as of 4 p.m. EST, up from $460.90 late Tuesday.

The dollar continued to draw strength from President Reagan's statement Tuesday that he did not want the currency to decline further, said Jack Barbanel, a first vice president with Gruntal & Co. Inc.

But there also was caution in the market in advance of Thursday's release of merchandise trade deficit figures for September, said Alfred Driever, vice president of foreign exchange at Salomon Brothers Inc.

''It's difficult to assess if the numbers we're seeing here are real, whether it's posturing or positioning before tomorrow,'' Barbanel said.

He called the dollar's firmness encouraging, but said the trade numbers were ''the big test.''

Trade figures have become catalysts for the dollar's declines since the Reagan administration said it would allow the dollar to fall to help shrink the U.S. trade deficit. When the dollar is lower, U.S. goods are cheaper overseas and foreign imports become more expensive.

Analysts said trading was thin Wednesday because of the Veterans Day holiday.

In earlier European trading, the dollar rose against nearly all key currencies in light activity, pushed higher by technical factors ahead of the trade deficit report. Currency markets were closed in France and Belgium for national holidays.

Dealers in Frankfurt, West Germany, said the market was expecting the trade deficit to narrow to $15 billion from a $15.7 billion shortfall in August. But the dollar was expected to continue to fall if the deficit was wider than $14 billion, they said.

The dollar has fallen sharply in the last week, hitting postwar lows Tuesday against the Japanese yen, the Swiss franc and the Dutch guilder, a six-year low against the French franc and a 5-year low against the Italian lire.

But after falling to record lows for five consecutive trading days, the dollar rose in Tokyo to a closing 134.35 Japanese yen, up from 133.65 yen at Tuesday's close. Later, in London, the dollar rose further to 135.10 yen and in New York, the dollar rose to 135.05 yen from 134.55 yen late Tuesday.

In London, the British pound fell to $1.7795 from $1.7905 late Tuesday. In later New York trading, the pound fell to $1.78025 from $1.7859.

Gold prices rose on short-covering in active European trading and on improved stock market prices, bullion dealers said.

In London, the metal rose to a late bid of $462 a troy ounce from $458.75 bid late Tuesday.

In Zurich, it jumped to $462.50 bid from $458.50 bid late Tuesday.

On the Commodity Exchange in New York, a troy ounce of gold cost $461.90, up from $461 late Tuesday.

Earlier, in Hong Kong, gold rose to a closing bid of $462.60 from $461.43 bid at Tuesday's close.