Does anybody know whether the location of the datacenter affects the SEO value of a given website? In other words a site which has 100% of visitors coming from USA has to be hosted in USA for better SEO or no problem if it is hosted outside the USA. I know that it has to be hosted in USA because of some performance like in server ping and data transfer. thanks.
That would only affect local (country specific) search (and only be a very minor factor). It would have no effect in google.com searches. But you should do it anyway for the speed benefits you mentioned which can also have an affect on your rankings. Google has indicated that slower web pages may see a negative effect on their rankings.
It is true that your datacenter location will affect only local searches. But, last summer Google made a change and all users are now forced to see local results even if they go to google.com . To se the original worldwide results you have to type google.com/ncr in your browser, so my bet is that 98% of the users will never do this.
Local results are more targeted to the users, this is why google is placing more and more serious about this. When the change was applied I've seen a change in the traffic, some sites went down, other sites went up. I think SEO right now is more about marketing it local. If you win loca, then you will have a lot of searches. The global orientated strategy does not work anymore.