(Reuters) - Morgan Stanley MS.N reported a higher-than-expected profit on Thursday, bolstered by strength in bond trading and M&A advisory, but executives were careful not to sound too optimistic about the rest of the year.

FILE PHOTO: A sign is displayed on the Morgan Stanley building in New York U.S., July 16, 2018. REUTERS/Lucas Jackson/File Photo

Like other big banks, Morgan Stanley had to navigate falling interest rates, volatile markets and recession signals during the third quarter, and fared relatively well. Its overall profit rose 3%, topping Wall Street expectations by a healthy margin.

However, the factors that created such a difficult operating environment during the quarter have not gone away, Chief Executive James Gorman and Chief Financial Officer Jonathan Pruzan said on a call to discuss earnings.

They suggested the trade dispute between the United States and China, further central bank easing, an unknown Brexit outcome and other geopolitical tensions could pressure results further. Although Gorman said the fourth quarter was “off to a good start,” that could change.

“We remain cautious today as trade talks swirl and interest rates continue to be debated,” Gorman said.

Although Pruzan said CEO confidence has remained high, it is unclear whether companies that are planning initial public offerings will proceed. Morgan Stanley led some of this year’s biggest IPOs, but signs of a possible downturn have slowed activity.

“Conversion from pipeline to realized remains highly dependent on market conditions,” he said.

During the quarter, Morgan Stanley swallowed heavy losses from stakes in companies that went public. Investment revenue plummeted to $33 million from $340 million.

Nonetheless, Morgan Stanley shares were up 2.7% in afternoon trading, with analysts celebrating the results. The bank beat KBW’s revenue forecasts in each business line, analyst Brian Kleinhanzl wrote in a note to clients.

Overall, Morgan Stanley’s profit rose to $2.2 billion, or $1.27 per share, from $2.1 billion, or $1.17 per share in the year-ago quarter. Net revenue inched up to $10 billion from $9.9 billion.

Analysts were expecting a profit of $1.11 per share on revenue of $9.6 billion, according to IBES data from Refinitiv.

The sixth-largest U.S. bank capped three days of results from Wall Street heavyweights. JPMorgan Chase & Co JPM.N, Bank of America Corp BAC.N and Citigroup Inc C.N also topped expectations, while Goldman Sachs Group Inc GS.N and Wells Fargo & Co WFC.N disappointed.

Sales and trading revenue rose 10% to $3.5 billion. Gains came from a 21% jump in bond trading as equities trading fell slightly compared to a year ago. Morgan Stanley typically ranks No. 1 in equities trading, but after years of market-share gains it has been facing tougher competition lately.

Its investment banking business, which includes advising on deals and helping corporations raise money, posted a 5% rise in revenue to $1.5 billion.

Wealth management’s $4.4 billion in revenue was down 1% from a year ago. That business has been a stabilizing force for Morgan Stanley during volatile times.

The business is trying to add new clients in Asia and lend to them more, Gorman said. Morgan Stanley’s loan book grew 8% rise in the third quarter, but net interest income stayed flat due to declining rates.

In investment management, its smallest business, Morgan Stanley reported a 17% rise in revenue, to $764 million.

Gorman complimented Morgan Stanley’s trading and investment banking businesses for being resilient in a shaky quarter, and said management is focused on keeping the bank stable and prosperous over the long term.

“There remains tremendous upside here,” he said.