The party fought off a strong Scottish Nationalist challenge in Livingston in a key test of the Government's popularity.
Labour had been defending a majority of 13,000 in the seat where Mr Cook picked up more than half the vote in the May general election. But with turnout down from 58 per cent to 39, the margin dropped by three-quarters as Labour lost 10,000 votes.Jim Devine, Mr Cook's agent and a close family friend, was selected to fight the constituency.
The Scottish Nationalists poured resources into the contest and believed damaging publicity over Walter Wolfgang's removal from the Labour conference eroded the Government's vote.
Mr Cook died from a heart attack while mountain walking last month.