As Doctor Who celebrates its 50th, it's time to study the numbers and settle this once and for all. Well, maybe

For the 50th anniversary of Doctor Who, I thought I'd take a look at which doctors were associated with the highest rated episodes, and which season has been rated the most highly by viewers.

Since people have already ranked all the episodes by actual viewing figures and polled people for their favourite doctor, I tried something different. Using IMDb, I compiled a list of every episode (excluding telemovies and prequels), along with user ratings, which doctor appeared in it, and the director. I wanted to include writers as well, but this was difficult due to the way writers are credited on IMDb.

I then grouped the episodes by doctor, season, and director to get the mean user rating of each. As the old series has far fewer user ratings overall per episode (the mean is 76 reviews per episode, compared with 1,659 for the new series), I've separated the two from direct comparison. Because of the higher number of ratings, the figures for the newer series are probably more reliable.

For the old series, the doctor appearing in the highest-rated episodes was the fourth: Tom Baker.

The new series was topped by Matt Smith, the newest Doctor.

As for seasons, in the newest series, season four, starring David Tennant, had the highest mean rating. Season 13 was the highest in the older series, with Tom Baker.

Here are the top 10 for user ratings grouped by directors:

This table is, unfortunately, vulnerable to skewing by low numbers – a director who has directed a single, well-received show is more likely to be placed higher than someone who has directed more.

David Maloney stands out in the older series, having directed the second-highest number of episodes and yet maintaining the highest average rating.

Hettie Macdonald's top position was due to directing the highest-rated episode overall: Blink, which introduced the memorable new Doctor Who enemy the Weeping Angels.

Here are the top episodes by mean rating:

Please keep in mind this is based only on the sample of IMDb users, and in the case of the older series the average number of ratings is rather low, so it should all be taken with a grain of salt. It's still a bit of fun. Who do you think was the best Doctor? Which are your favourite episodes? © Guardian News and Media 2013