MCPcopy Create free account
hub / github.com/MacHu-GWU/uszipcode-project / by_population

Method by_population

uszipcode/search.py:714–729  ·  view source on GitHub ↗

Search zipcode information by population range.

(self,
                      lower=-1,
                      upper=2 ** 31,
                      zipcode_type=ZipcodeType.Standard,
                      sort_by=SimpleZipcode.population.name,
                      ascending=False,
                      returns=DEFAULT_LIMIT)

Source from the content-addressed store, hash-verified

712 )
713
714 def by_population(self,
715 lower=-1,
716 upper=2 ** 31,
717 zipcode_type=ZipcodeType.Standard,
718 sort_by=SimpleZipcode.population.name,
719 ascending=False,
720 returns=DEFAULT_LIMIT):
721 """
722 Search zipcode information by population range.
723 """
724 return self.query(
725 population_lower=lower,
726 population_upper=upper,
727 sort_by=sort_by, zipcode_type=zipcode_type,
728 ascending=ascending, returns=returns,
729 )
730
731 def by_population_density(self,
732 lower=-1,

Callers 1

test_edge_caseMethod · 0.80

Calls 1

queryMethod · 0.95

Tested by 1

test_edge_caseMethod · 0.64