See also http://paulgraham.com/maybe.html, http://paulgraham.com/cities.html, http://paulgraham.com/hubs.html.
Investors and start-up culture sound like the missing ingredient more than any shortage of technical know-how.
I believe Peopleware covers this pretty well.
In New York, for example, junior developers tend be around $75-95k while senior (5-10 years) are $140-200k (wide range). In the Valley, I'd guess that those numbers are $90-110k and $130-150k. The low end is higher and the high end is lower, in the Valley.
One thing New York has that the Valley doesn't (unless you're a nationally-known entity, like Jeff Dean) is people making $250k+ just writing code. That does mean you're probably in finance, but it's better than having to go into management if that's not what you want to do.
I'm coming up to ten years as a senior dev and I earn way less than the lower band of that Junior salary.
edit: I am Canadian for reference and just Googling around a bit suggests anecdotaly that salaries are in the $50k-$100k range for most developers.
NY and SV are good places to build your career, but most people who are intent on being lifelong programmers (as opposed to being managers or founders by 40) get out after a decade or so. The cost of living is annoying but bearable; the culture it creates, however, sucks because everyone is competing to be a manager or founder before being judged "too old". The cultural effects of high rent (much less purchase prices at 30-50 years) are even more of a travesty than those high rents are standing alone.