The income necessary to be considered among the middle class varies across the country, a new study shows.