Simply put because one level of your categorical feature (here location) become the reference group during dummy encoding for regression and is redundant. I am quoting form here "A categorical variable of K categories, or levels, usually enters a regression as a sequence of K-1 dummy variables. This amounts to a linear hypothesis on the level means."
This is already discussed at this very nice stats.stackexchange answer.
I was told there is an advanced course by Yandex in Coursera that covers this subject in more details if you still have doubts, see here. Note you can always audit the course content for free. ;-)
Another nice post if you want a thorough explanation with lots of examples with statistical perspective and not being limited to only dummy coding, see this from UCLA (in R)
Note that if you using pandas.get_dummies
, there is a parameter i.e. drop_first
so that whether to get k-1 dummies out of k categorical levels by removing the first level. Please note default = False
, meaning that the reference is not dropped and k dummies created out of k categorical levels!