Canadian National Railway Co. named Tracy Robinson as its new chief executive officer and said it has reached a settlement with activist investor TCI Fund Management Ltd.

Robinson, who will be the first woman to run the Montreal-based railway, spent almost three decades at rival Canadian Pacific Railway Ltd., according to a statement. She’s currently head of natural gas pipelines at TC Energy Corp. 

The country’s largest railway will also grant TCI two seats on the board as part of a settlement that prevents a proxy fight, the company said, confirming an earlier report by Bloomberg News. 

The announcements come three months after Jean-Jacques Ruest resigned amid pressure from TCI, a surprise announcement that happened less than four years after he took the job. 

TCI, which is run by billionaire Chris Hohn and is CN’s second-largest holder, has been pushing for changes at the railway and had nominated four directors to its board. TCI also called on the company to replace Ruest with Jim Vena, but Vena told the board in December that he’s no longer interested in becoming CEO. 

The company beat expectations for its fourth quarter earnings Tuesday, making C$1.71 per share on an adjusted basis compared with estimates of C$1.53. The railway was hit by flooding in British Columbia in the fourth quarter, which temporarily cut rail access to Canada’s biggest port in late 2021. The disruption came during one of the busiest times for grain shipping and as global supply chains are already strained with congestion and backlogs.