LONDON (Reuters) - Alliance Trust (>> Alliance Trust PLC), one of Britain's oldest investment managers, agreed on Friday to buy back shares held by a U.S. activist hedge fund, bringing an end to a campaign that has forced it to reform how it is run.

Dundee-based Alliance, which traces its roots to the late 19th century and loans to farmers across the British Empire, said it would buy back a 19.75 percent stake held by U.S. billionaire Paul Singer's Elliott Management.

It marks an end to an at times bitter five-year campaign on the part of Elliott to force the Scottish asset manager to improve its performance, including through a radical overhaul of both the board and the firm's investment process.

Casualties along the way included former chief executive Katherine Garrett-Cox, one of the City of London's highest profile businesswomen, who was forced to step down from the group's board in October 2015.

Sustained pressure from Elliott also resulted in Alliance changing the way it invested, moving to outsource its equity stock-picks and management to an external advisor and group of fund managers at other companies.

"Elliott has done quite nicely out of its stake in Alliance, and has instigated wholesale change at the investment trust, though it still remains to be seen whether that is to the long term benefit of shareholders," said Laith Khalaf, senior analyst at investment advisor Hargreaves Lansdown.

"The withdrawal of Elliott from the shareholder register should lead to more stability for the trust, which now needs to focus on making sure the new investment strategy delivers."

Elliott's stake is worth around 632 million pounds, based on Alliance's current market value of 3.2 billion pounds ($4 billion). While Elliott declined to say how much is profit, Alliance stock is up 92 percent since the end of December 2011.

EXIT ROUTE

As a 'closed ended' investment trust company, Alliance raises money from investors in exchange for shares in the firm, which then trade at a discount or premium to the value of its investment portfolio.

The launch of a share buyback follows agitation from Elliott for an exit route after the gap between the share price and the value of Alliance Trust's assets closed to less than 5 percent from as wide as 15 percent.

"Elliott welcomes the opportunity to participate in the offer being made to all other shareholders under the buyback programme," a spokeswoman for the activist investor said in an emailed statement.

The repurchase, at a 4.75 percent discount to the value of the shares, requires approval by Alliance's independent shareholders, Alliance Trust said in a statement.

"Hedge funds tend to have a reputation as disruptive short term investors. In this case, however... we believe its activism has resulted in a far more attractive vehicle for all shareholders," analysts at Numis said in a note to clients.

"It is encouraging that the agreement with Elliott is broadly in-line with the discount level of previous repurchases, and also that the Board has committed to further buybacks at the same level."

Alliance Trust shares were up 0.4 percent at 1045 GMT, narrowly outpacing the FTSE All Share index <.FTAS>.

The firm ended up more than 23 percent in 2016, outperforming peers including RIT Capital Partners (>> RIT Capital Partners plc), the investment trust run by financier Jacob Rothschild, which had mulled a takeover bid for Alliance.

($1 = 0.7962 pounds)

(Editing by Keith Weir)

By Lawrence White and Simon Jessop

Stocks treated in this article : Alliance Trust PLC, RIT Capital Partners plc