A data access layer for environmental time series datasets
Project description
air-db
air-db is a data access layer (DAL) to easily query environmental time series datasets from various sources. air-db does not include any database. It is required to install corresponding database to work air-db properly.
To install sample database:
from airdb import Database
Database.install_sample()
A database query can be implemented as follows:
from airdb import Database
db = Database('samp', return_as='df')
q = db.query(param=['so2', 'pm10'], city='istanbul', date=['>2010-05-10', '<2012-10-07'], month=5)
print(q)
del db # close connection to database
and the output is:
param reg city sta date value
0 pm10 marmara istanbul çatladıkapı 2010-05-10 00:00:00 0.798218
1 pm10 marmara istanbul çatladıkapı 2010-05-10 01:00:00 0.946180
2 pm10 marmara istanbul çatladıkapı 2010-05-10 02:00:00 0.884385
3 pm10 marmara istanbul çatladıkapı 2010-05-10 03:00:00 0.537993
4 pm10 marmara istanbul çatladıkapı 2010-05-10 04:00:00 0.136689
... ... ... ... ... ... ...
16123 so2 marmara istanbul şirinevler mthm 2012-05-31 19:00:00 0.697663
16124 so2 marmara istanbul şirinevler mthm 2012-05-31 20:00:00 0.615755
16125 so2 marmara istanbul şirinevler mthm 2012-05-31 21:00:00 0.489289
16126 so2 marmara istanbul şirinevler mthm 2012-05-31 22:00:00 0.385102
16127 so2 marmara istanbul şirinevler mthm 2012-05-31 23:00:00 0.039451
[16128 rows x 6 columns]
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
air-db-0.0.1.tar.gz
(21.8 kB
view details)
Built Distribution
air_db-0.0.1-py3-none-any.whl
(20.3 kB
view details)
File details
Details for the file air-db-0.0.1.tar.gz
.
File metadata
- Download URL: air-db-0.0.1.tar.gz
- Upload date:
- Size: 21.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.0 setuptools/51.3.3 requests-toolbelt/0.9.1 tqdm/4.54.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc80ca04594b7501b810642b16b8ceb224fa5c2f40ac06c54cf829af2d6fde7a |
|
MD5 | d4e66ab9eb2235b42a3f0e2b31291a6c |
|
BLAKE2b-256 | 5979f4ced7270ada2f10207b821d19f307b55258c7effe27466bba1e32cdcd28 |
File details
Details for the file air_db-0.0.1-py3-none-any.whl
.
File metadata
- Download URL: air_db-0.0.1-py3-none-any.whl
- Upload date:
- Size: 20.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.0 setuptools/51.3.3 requests-toolbelt/0.9.1 tqdm/4.54.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 54aeef82a7a68015bdf5aed89aaeba10f3d4855b50fa4ad0bca3e72f33f0ab68 |
|
MD5 | 11d4789fa7cd19b42cbeecf567749803 |
|
BLAKE2b-256 | ddc48281e9c10886baca030c16936c54e7e42eea1f202cf20761e92daba2a93a |