The difference between doctors and lawyers vs coders is portability. Computer code is not strongly tied to geography (duh ... outsourcing can work). Where's it's hard for your doc to do a physical exam if he's across the country. The point is, as a coder you compete on a bigger playing field and that bigger playing field places more downward pressure on fiscal rewards.
While it is true that computer code isn't tied to a particular geographical area, outsourcing comes with its share of problems which usually don't make it a very interesting proposition, at least for short term projects. For example, this article on CIO illustrates some of the costs which are frequently overlooked when outsourcing.
I do believe, however, that the perception that "it's cheaper to do it overseas" does put a downwards pressure on wages.