NEW YORK, July 26 (Reuters) - Investors in U.S. funds traded international equities for domestic stocks during the latest week as earnings beat expectations while trade tensions simmered, Lipper data showed on Thursday.

The withdrawals were driven in large part by investors leaving non-domestic equity funds, which saw $1.1 billion in withdrawals.

U.S.-based domestic equity funds, by contrast, attracted $474 million and a second straight week of inflows, Lipper said.

The strong performance by domestic equity funds came as 83.9 percent of S&P 500 companies have reported second-quarter profits that beat analyst expectations so far, according to Thomson Reuters I/B/E/S.

"When we get back to the brass tacks, we really had a good beginning to the earnings season," said Tom Roseen, head of research services at Thomson Reuters Lipper.

Yet trade tensions kept investors on edge, with U.S. President Donald Trump saying during the week that he is ready to impose tariffs on all $500 billion of imported goods from China.

Fund investors deposited $1.4 billion into U.S.-based taxable-bond funds, a third straight week netting cash. Their municipal bond counterparts took in $550 million, according to Lipper.

U.S.-based precious metals commodities funds ended a streak of outflows that began in early May, attracting $211 million for the period.

Dollar-denominated metals, such as gold, became more affordable for investors abroad after Trump criticized the greenback's strength in an interview aired on Friday and sent the currency lower. (Reporting by James Thorne; Editing by Trevor Hunnicutt and Lisa Shumaker)