Athenahealth, a Watertown, Massachusetts-based electronic medical billing company with offices in Belfast, announced Monday that it would be acquired by private equity firm Veritas Capital and Evergreen Coast Capital for roughly $5.7 billion cash.

Evergreen is an affiliate of Elliott Management, a hedge fund run by billionaire activist investor Paul Singer, who set the sale in motion in May when he criticized the management of athenahealth and claimed he could make the company more profitable under private ownership.

Singer, through Elliott Management, offered to buy the company $160 per share, but athenahealth turned him down. The deal announced on Monday is for $137 per share, which is 12 percent more than the trading price at the time of Singer's initial offer.

Veritas and Evergreen plan to merge athenahealth with Veritas-owned Virence Health. The combined company would operate in Watertown under the athenahealth name and the leadership of Virence Chairman and Chief Executive Officer Bob Segert and a team of executives from both companies.

Jeff Imelt, executive chairman of athenahealth, on Monday said the combination of the two companies would "create new opportunities for collaboration and growth," adding that operating as a private company under Veritas would give athenahealth "increased flexibility to achieve our purpose of unleashing our collective potential to transform health care."

Athenahealth's Belfast offices, where roughly 950 people are employed, were closed on Monday for the federal holiday. Two workers reached by The Republican Journal on Monday, who asked that their names not be disclosed, said the impending sale has created a sense of uncertainty in Belfast.

One worker said there was noticeable tension after the company pushed back its third-quarter earnings call earlier this month. The call, which was rescheduled for Nov. 12, according to the statement from athenahealth, was cancelled with Monday's announcement of the sale.

The other worker raised the question of redundancies at Virence and athenahealth, and how those would be handled by the new owner, but was optimistic after reading about Virence.

The sale is expected to close in the first quarter of 2019, subject to approval by owners of a majority of athenahealth's outstanding shares.