Giter Club home page Giter Club logo

china-zip-code-latitude-and-longitude's Introduction

**地区邮编经纬度/工具(Python 版)

pypi python_vesion

根据省市区获取**经纬度和邮编

关于

特性

  1. 根据省市区获取经纬度和邮编。

安装

$ pip install china-region

依赖库

pandas>=0.23.4

升级

$ pip install -U china-region

使用示例

    # 获取满足条件的所有地址
    >>> import china_region
    >>> china_region.search_all(county='华安')
    [{'province': '福建省', 'city': '漳州市', 'county': '华安县', 'longitude': 117.53, 'latitude': 25.02, 'zipCode': '363800'}]
    >>> china_region.search_all(province='福建省',city='华安')
    [{'province': '福建省', 'city': '漳州市', 'county': '华安县', 'longitude': 117.53, 'latitude': 25.02, 'zipCode': '363800'}]
    >>> china_region.search_all(province='贵州',city='贵阳',county='白云')
    [{'province': '贵州省', 'city': '贵阳市', 'county': '白云区', 'longitude': 106.65, 'latitude': 26.68, 'zipCode': '550014'}]

    # 获取满足条件的第一个地址
    >>> china_region.search('辽宁 铁岭')
    {'province': '辽宁省', 'city': '铁岭市', 'county': '铁岭市', 'longitude': 123.83, 'latitude': 42.28, 'zipCode': '112000'}
    
    # 获取一个随机的地址
    >>> china_region.sample()
    {'province': '山西省', 'city': '临汾市', 'county': '洪洞县', 'longitude': 111.67, 'latitude': 36.25, 'zipCode': '041600'}

资源文件

北京市	北京市	北京市	116.4	39.9	100000
北京市	北京市	东城区	116.42	39.93	100010
北京市	北京市	西城区	116.37	39.92	100032
北京市	北京市	崇文区	116.43	39.88	100000
北京市	北京市	宣武区	116.35	39.87	100000
北京市	北京市	朝阳区	116.43	39.92	100020
北京市	北京市	丰台区	116.28	39.85	100071

相似项目: https://github.com/radiocontroller/china-location

Lincese

MIT License

Copyright (c) 2019  Thunder Bouble

china-zip-code-latitude-and-longitude's People

Contributors

sfyc23 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.