KUALA LUMPUR (Reuters) - Chinese investments into Malaysia halved to $1.7 billion in the first nine months of the year from a year ago, though U.S. investments soared seven times to $5.9 billion - reflecting a diversion of funds due to the Beijing-Washington trade clashes.

Data provided by the Malaysian Investment Development Authority (MIDA) to Reuters on Friday showed that China, traditionally the Southeast Asian country’s biggest investor, has now slipped to third position behind the United States and Japan.

Foreign direct investment (FDI) from Japan, with whom Malaysian Prime Minister Mahathir Mohamad is trying to strengthen ties, jumped more than four times to 11.81 billion ringgit ($2.83 billion) in the January-September period.

Total approved FDI into Malaysia rose 6.5% to 66.3 billion ringgit, MIDA said, adding it was “actively negotiating” on 682 other projects with proposed investments of 37.6 billion ringgit.

Trade hostilities between the world’s biggest two economies have pushed mostly U.S. companies to look for factories outside China to escape tit-for-tat tariffs.

For Malaysia, the biggest investments have come in the electrical and electronics industry, with one of the driving factors being that many semiconductor and other electronics products from the country do not attract U.S. tariffs, unlike the 25% rate for China.

U.S. companies such as chipmaker Micron Technology (MU.O) and iPhone supplier Jabil Inc (JBL.N) are already building new factories in Malaysia.

Reporting by Krishna N. Das; Editing by Alex Richardson