Federer's h2h with top rivals
Below is a selection of Federer's head to head records against several of his past and current rivals.
His opponent's strongest surface is underlined and weakest surface is in bold. Total matches on each surface is in brackets.
Nadal: 2-11  on clay, 6-5  other surfaces (grass, hard, carpet).
Djokovic: 11-8  on hard, 2-1  on clay.
Murray: 6-8  on hard, 0-0 on clay.
Roddick: 19-2  on grass, hard, and carpet, 1-0 on clay.
Hewitt: 13-6  on hard/carpet, 3-2  on grass. 1-0 on clay
Agassi: 8-3  on hard.
Sampras: 1-0 on grass.
kuerten: 1-1  clay, 0-1 hard.
coria: 2-0 on clay, 1-0 on other surfaces.
henman: 7-6  on carpet, hard, and grass, 0-0 on clay.
Against most of his biggest rivals, Federer has played a strikingly high percentage of matches on his opponent's strongest playing surface. While this might at first glance seem like bad luck, I think it's more reflective of the fact that Federer has had similar success for a very long time on all the playing surfaces. It also suggests that it might be easier to have a positive head to head when your career is relatively short or when you dominate only one surface. If you dominate a particular surface, you can accumulate victories on that surface over good but slightly lesser players. And then on your weaker surfaces, where you fail to progress deep into tournaments with the same consistency, your losses are spread around to many other players, not just those same "good but lesser" players you were beating on your dominant surface. This phenomenon is especially evident in the H2Hs with Nadal, Murry, and Henman. Federer has been unable to balance out the losses to Nadal on clay, Murray on hard, and Henman on fast surfaces, with victories on grass or hard against Nadal, and clay against Murray and Henman. This is because there are few tournaments played on grass and because those players did not consistently progress deep into tournaments in which Federer was waiting.
It's doubtless that Nadal has become Federer's equal or better on grass, but if there were as many tournaments played on grass as on clay, it's likely Federer would have racked up a handful more victories over Nadal - especially between 2004 and 2008 - when Nadal was the 2nd best player in the world.