cnparser is a parser library of Corporate Number Publication Site data.
Project description
cnparser
cnparser is a python library for loading and enrichment Corporate Number Publication Site data that is provided from National Tax Agency Japan. cnparser only support to parse latest data now.
Installation
cnparser is available on pip installation.
$ python -m pip install cnparser
GitHub Install
Installing the latest version from GitHub:
$ git clone https://github.com/new-village/cnparser
$ cd cnparser
$ python setup.py install
Usage
Many properties are available once the cnparser object is created.
Collect basic information (基本3情報)
>>> import cnparser
>>> cndata = cnparser.bulk_load("Shimane")
>>> print(cndata)
[{'sequence_number': '1', 'corporate_number': '1000013050246', ..., 'hihyoji': '0'}, {...}]
Enrich information from bulk_load
result
>>> import cnparser
>>> enriched = cnparser.bulk_enrich(cndata)
>>> print(enriched)
[{'sequence_number': '1', ..., 'lat': 34.978982, 'lng': 132.525163, 'level': 3}, {...}]
Enrich information from downloaded CSV File
>>> import cnparser
>>> enriched = cnparser.bulk_enrich("path/to/data.csv")
>>> print(enriched)
[{'sequence_number': '1', ..., 'lat': 34.978982, 'lng': 132.525163, 'level': 3}, {...}]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
cnparser-1.3.1.tar.gz
(10.4 kB
view hashes)
Built Distribution
cnparser-1.3.1-py3-none-any.whl
(11.9 kB
view hashes)