A package for interacting with the UK Office for National Statistics' Beta API.
Project description
Installation
You can install this package using pip.
pip install onsapi
Example usage
You can get a list of all datasets available on the ONS API.
from onsapi import OnsApiClient
client = OnsApiClient()
datasets = client.list_datasets()
Information about each dataset can be pretty printed to the command line.
selection = datasets[0]
print(selection)
You can load a dataset as a dataframe.
selection.download_csv()
df = selection.load_as_df()
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
onsapi-0.2.2.tar.gz
(8.6 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file onsapi-0.2.2.tar.gz.
File metadata
- Download URL: onsapi-0.2.2.tar.gz
- Upload date:
- Size: 8.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f59acd00149c5246382d19168dfc6b9cc81e0eb3ad47635c550ed6939ae34cf8
|
|
| MD5 |
14c80ba3376c8d2d26dc0ec0cbdeed56
|
|
| BLAKE2b-256 |
3c1c39ec81c0acf06ba7eff3af3ffcdda9134c5fb10e7dc15a5dc1543e547b47
|
File details
Details for the file onsapi-0.2.2-py3-none-any.whl.
File metadata
- Download URL: onsapi-0.2.2-py3-none-any.whl
- Upload date:
- Size: 7.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
25df443070885630f53faa3d37a5a319b34c05021ea2b77fdd137d6fc545a8bd
|
|
| MD5 |
e51c7a3763e8c4452469449d208619d7
|
|
| BLAKE2b-256 |
f85aaa3feb23e8fdd0a2deed1836be599f4231b06e4290354b122234c8496b4d
|