New York (CNN Business) The New York Mets have agreed to be sold to hedge fund billionaire Steve Cohen, in a deal that will take five years to complete, the team announced Wednesday evening.

During that time the current owner, Fred Wilpon, 83, will continue to serve as the team's chairman. He bought half the team along with Nelson Doubleday in 1980, and the other half in 2002. Wilpon's son, Jeff Wilpon, who is the team's chief operating officer, will remain in that job for five years.

The Mets have struggled to compete against the more popular New York Yankees, and it shows in the team's financial fortunes as well as their middling success on the field. The team's fans have often focused their anger and disappointment on the Wilpons for their decisions on whether or not to sign players.

Just earlier in the day Wednesday the Mets lost one of their best pitchers, Zack Wheeler, to the rival Philadelphia Phillies when he signed a five-year, $118 million deal with them.

The Mets had 2018 revenue of $340 million and a valuation of $2.3 billion, according to Forbes, a leading source of information on team finances. The Yankees had revenue of $668 million and a valuation of $4.6 billion, making them by far the most valuable team in the sport according to Forbes.

Read More