the point here is that there is a false concept that dogs are "nice". Dogs are carnivorous, predatory animals. Their normal behaviour is to hunt and kill a live prey, and they readily do this when abandoned or when they go wild.
On the other hand, dogs which are properly reared, through affection, regular feeding, training, because of their genetic pack mentality, see the owner as their master and see themselves as part of their family. Dogs are nice ONLY when properly raised. Hell, all animals can be friendly, orcas, lion seals, polar bears, wolves. They will still kill you if their instinct tell them to.
Pitbulls may be medium sized, but they have a formidable muscular structure. They were bred for fighting, and will exhibit a minutely larger tendency to attack. The problem is that you give these dogs to people who A) do not know how to raise them, and B) actually try to make the dog more aggressive. Generally, they are aggressive and allround bad people themselves, and my source for that statement is: i lived in the London ghettos, where everyone has a pitbull for the specific reason to use them to attack people. And finally, BECAUSE of this, the last 20'years worth of statistics have been made completely useless, it's practically all outliers.
If you train equal numbers of different breeds, professionally, or even just in "a reasonable way", you will see that german sheperds are the ones who cause the most hospital visits; cockers are the most likely to turn on their owners. Small dogs do not even figure in the statistics, but even small dogs will bite, they just don't cause injuries.