* Euro posts best week vs dollar since late December
* Currencies tracks volatile stocks
* U.S. trade gap narrows, U.S. consumer sentiment rises (Recasts; updates prices)
By Nick Olivari
NEW YORK, March 13 (Reuters) - The dollar gave up its gains against the euro on Friday in volatile trade as U.S. stocks closed the week in positive territory, prompting investors to take on more risk.
The U.S. currency had swung between gains and losses for most of the day, following trends in the stock market amid better-than-expected economic data and signs the banking sector may be stabilizing.
"Sentiment has turned in fits and starts," said Brian Dolan, chief currency strategist at Forex.com in Bedminster, New Jersey.
"All that is happening right now is a reality check and investors are asking whether this is really the bottom here. But conviction is really low and that is why we're seeing perpetual setbacks like this," he added.
In late afternoon trading, the euro edged up 0.1 percent against the dollar to $1.2919 <EUR=>. For the week, the single currency rose 1.9 percent, its best weekly gain since the week ended Dec. 21.
Wall Street stocks on Friday wrapped up their best week since November as Citigroup (C.N: Quote, Profile, Research, Stock Buzz) announced it did not need any more government aid. For details, see [ID:nN13459141]
Sterling gained 0.4 percent to $1.3984 <GBP=>.
The yen fell against both the dollar and euro, with the euro at its highest in more than two months at 127.65 yen <EURJPY=EBS>. It last traded at 126.70 yen, up 0.4 percent.
The dollar traded up 0.3 percent at 98.03 yen <JPY=>. The yen was pressured by concerns the Bank of Japan may intervene to weaken its currency a day after the Swiss National Bank sold the franc and bought dollars and euros to combat Switzerland's worst recession in three decades.
Against the Swiss franc, the dollar was little changed at 1.1858 francs <CHF=>. The euro also rose against the Swiss franc to 1.5324 <EURCHF=>.
MOOD MORE UPBEAT
Overall, the mood was a little more upbeat than in previous sessions, with more positive news about the U.S. banking system prompting investors to pare long positions on the dollar.
Bank of America (BAC.N: Quote, Profile, Research, Stock Buzz) said on Thursday it had been profitable in the first two months of this year and should be able to ride out the recession without any additional help from U.S. taxpayers.
The comments echoed statements by Citigroup Chairman Richard Parsons, who told Reuters the bank does not need any more government capital injections and expressed confidence Citi would remain in private hands. [ID:nN13426253]
The dollar had been seen as a safe haven in recent weeks and demand has waxed and waned in response to daily stock market moves.
U.S. economic data, meanwhile, was more or less positive, which made investors a little more comfortable adding riskier currencies to their portfolios.
Data on Friday showed the U.S. trade deficit shrank to $36.0 billion in January, its smallest since October 2002, while another report showed U.S. consumer sentiment improved unexpectedly.
But market participants were still hesitant to call a bottom in the economy and most think positive economic news does not mean a recovery is underway.
The data "says nothing about the degree of recovery or the timing of recovery," said Joseph Trevisani, chief market analyst at FX Solutions in Saddle River, New Jersey. "I still think with continuing job losses and (the) low level of consumer spending, it'll be difficult for the economy to generate a recovery yet."