SNP MP Tommy Sheppard has dramatically ruled himself out of the race to be the party's deputy leader.

Sheppard had been tipped as the frontrunner to succeed Angus Robertson, who was one of 21 SNP casualties in last year's general election.

Writing exclusively in today's Sunday Herald, Sheppard reveals why he had decided not to stand to replace Robertson.

Tommy Shepphard MP: Why I am not running as deputy leader of the SNP

Sheppard said the contest would not help the SNP overcome setbacks the party had faced, and added that the deputy leadership race must not be used to decide when the next independence referendum will be held.

However, he warned that the SNP had to be a "lot better prepared than we are" for a second referendum.

Sheppard said that a vote "could present at any time" due to Brexit "volatility".

The Edinburgh East MP said that rather than stand for deputy leader he wanted to focus on the "wider campaign for independence".

Tommy Shepphard MP: Why I am not running as deputy leader of the SNP

However, he said the SNP should only hold a second referendum when there is a "reasonable expectation of winning it".

Sheppard said: "Resolving differences are for our internal democratic structures and as in any large organisation that sort of change takes time. Maybe sometimes political differences can be resolved – or in any case fought out so there’s a winner – by a leadership contest. But not when electing a number two."

Sheppard, who is on the left of the SNP, added: "Nor is this contest about when the next independence referendum will be. That’s not a decision that can be deputised. We should hold another referendum when there is evidence that a significant number of people have changed their minds from last time – and when there is a reasonable expectation of winning it. Given the volatility of UK politics at the moment that opportunity could present at any time. Whenever the referendum is we need to be a lot better prepared than we are."

He said being deputy leader would also restrict his ability to intervene in debates about the SNP's future policy direction.

Sheppard finished in second place behind Robertson in the SNP's last deputy leadership election in 2016.

Tommy Shepphard MP: Why I am not running as deputy leader of the SNP

However, he said the latest contest should not be used to vent frustration about plans for a second independence referendum being placed on hold.

He said: "In recent weeks some have suggested that this internal election offers an opportunity for the SNP to review its strategy and policy direction.

"This implies that there’s some underlying tension within the party which can be resolved by electing a new depute leader. That argument doesn’t really hold up. Yes there are differences of opinion within the SNP as there are in any party. And yes the current Brexit induced political chaos and inertia is creating a lot of frustration and impatience. But these differences are not existential."

Sheppard said he had also opted not to stand due to "a range of personal factors". He cited a "work life balance" and said he wanted to get on with his job at Westminster, adding: "There are a range of personal factors that have influenced my decision. We are all of us very good at talking about a work-life balance but often do little about it. I’m content where that balance is for me at the moment and for now I’ve no desire to alter it."

Tommy Shepphard MP: Why I am not running as deputy leader of the SNP

Sheppard was touted as the bookies' favourite for deputy leader after the party's Westminster leader Ian Blackford said he would not stand. Glasgow MSP James Dornan and high profile party activist Julie Hepburn are the only confirmed candidates so far.

However, SNP MPs Hannah Bardell, Joanna Cherry and Philippa Whitford and MSP Ivan McKee have been tipped to stand. A timetable has yet to be set for the election, but there is widespread speculation the winner will be announced at the next SNP conference in Aberdeen in June.