LONDON (Reuters) - Hedge funds which bet on mergers and acquisitions were hurt by the collapse of a $160 billion tie-up between pharmaceutical companies Pfizer (>> Pfizer Inc.) and Allergan (>> Allergan, Inc.) - although the effects could have been even worse.

The deal was pulled after the U.S. Treasury drafted new rules to deter companies from moving their headquarters to countries with a more favorable tax regime, so called 'tax inversions', echoing the failed merger between Shire (>> Shire PLC) and ABBVie (>> AbbVie Inc) in 2014 which hurt many funds.

Shares in Allergan fell 15 percent on Tuesday after Reuters reported the mega-deal had likely fallen through, while Pfizer rose 2 percent. The companies confirmed the deal was off on Wednesday.

While few funds came through unscathed, with large U.S. funds such as Paulson & Co among the worst hit, a mix of optimism the deal would go ahead and a reluctance to super-size positions had helped many trim their losses.

"For managers doing risk-arb, it was super-consensual. But most people who were trading that specific spread were lightly hedged or were long Pfizer as well, which helped," said a London-based fund of hedge funds manager.

"If you were purely trading the spread, you'd have been killed. Everyone got hurt, but most got hurt just on the Allergan leg, which is unusual."

Merger arbitrage funds often aim to make money by buying shares in a company that is the target of a takeover bid in the hope they will rise towards the offer price. They also bet that the share price of the company making the bid will fall and they can make a return from the spread between the two prices.

If they think the opposite, they can reverse the trade, although data from industry tracker Markit showed less than half a percent of Allergan stock was out on loan heading into the news.

The strategy is also used by funds with a broader event-driven investing remit, which aims to take advantage of share price differences that may occur in the run up to a corporate sale, or merger or other corporate event.

PRESSURE

One investment consultant said the deal had cost the 12 hedge funds he tracks between 25 basis points and 70 basis points of performance.

Lyxor Asset Management senior analyst Jean Baptiste Berthon said 16 funds, mostly located in the United States, had lost up to 1 percent of their fund's value after the deal fell through, although many had lost "hardly anything" by buying both stocks.

Some had also hedged their exposure by placing a short position on other firms engaged in tax inversions, effectively a bet that the share price will fall, while others had kept position sizes small after being burnt by the Shire/Abbvie hit.

Given there were relatively fewer tax inversion deals in play as a result of growing political pressure in the United States to curb them, there was much less risk of contagion across a merger-arb hedge fund's portfolio.

"The situation seems quite different from last year where you could see several major deals with a tax inversion embedded in it, which had a very large ripple effect on these funds ... we are not seeing such contagion today," Berthon said.

Fourteen tax inversion deals were announced in 2015 for a combined $183.7 billion, Thomson Reuters data showed, with Pfizer/Allergan representing the bulk. This year there have been just two tax-driven deals, valued at $33.8 billion.

After making 8.4 percent during a bumper year for deal-making in 2015, merger arb funds had enjoyed a positive start to the year, data from Hedge Fund Research showed, with the HFRX Merger Arbitrage Index up 1.75 percent to end-March.

The broader HFRX Event Driven Index, meanwhile, was down 1.13 percent in the year to end-March, HFR data showed, adding to a fall of 6.94 percent in 2015 and HFR President Kenneth Heinz said it could face a 20 basis points hit from Allergan.

Given the solid month for many funds in March, the impact of the deal collapse would likely not weigh on year-end performance, said Anthony Lawler, Head of Portfolio Management at GAM Alternative Investments Solutions.

"It hurts ... event driven investors will dislike this Allergan news, but it will not alone badly impact year-to-date numbers except for the very concentrated event managers."

(Additional reporting by Pamela Barbaglia in London, editing by David Evans)

By Simon Jessop and Maiya Keidan

Stocks treated in this article : Allergan, Inc., Shire PLC, AbbVie Inc, Allergan plc, Pfizer Inc.