Grab publicly available weather data
Project description
riweather
Grab publicly available weather data with riweather. See the full documentation.
Installation
Install with pip:
pip install riweather
To create interactive maps of weather station locations, install the package along with its optional dependencies:
pip install riweather[plots]
Usage
Given a latitude and longitude, get a list of weather stations sorted from nearest to farthest from that location.
>>> import riweather
>>> station_rank = riweather.rank_stations(39.98, -105.13, max_distance_m=20000)
Select the top station (or a different station):
>>> station = riweather.select_station(station_rank, rank=0)
View information about that station:
>>> station.name, station.usaf_id
('ERIE MUNICIPAL AIRPORT', '720534')
And pull weather data from that station for a certain year.
>>> station.fetch_data(2024, "air_temperature", period="h", temp_scale="F", tz="US/Mountain")
air_temperature.temperature_f
2023-12-31 18:00:00-07:00 33.176848
2023-12-31 19:00:00-07:00 29.726000
2023-12-31 20:00:00-07:00 25.415750
2023-12-31 21:00:00-07:00 22.736750
2023-12-31 22:00:00-07:00 20.876750
... ...
2024-12-31 13:00:00-07:00 34.328000
2024-12-31 14:00:00-07:00 35.445500
2024-12-31 15:00:00-07:00 35.640500
2024-12-31 16:00:00-07:00 34.249250
2024-12-31 17:00:00-07:00 31.057455
[8784 rows x 1 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
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 riweather-1.0.2.tar.gz.
File metadata
- Download URL: riweather-1.0.2.tar.gz
- Upload date:
- Size: 3.8 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dff3dfaa2dda660d644e44324e04eab97cc320e9f67dc46620bf4adfabdc730d
|
|
| MD5 |
67a686c8ca186c5abdcd9c46ef01ba58
|
|
| BLAKE2b-256 |
13bf2212f41c062e5ae3084c1c867e40fbf3898962797ed7349312978b1d00ce
|
Provenance
The following attestation bundles were made for riweather-1.0.2.tar.gz:
Publisher:
release.yml on ensley-nexant/riweather
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
riweather-1.0.2.tar.gz -
Subject digest:
dff3dfaa2dda660d644e44324e04eab97cc320e9f67dc46620bf4adfabdc730d - Sigstore transparency entry: 240873871
- Sigstore integration time:
-
Permalink:
ensley-nexant/riweather@02fc38ffb9513e6754e9da54a5bff16e14df29cd -
Branch / Tag:
refs/tags/v1.0.2 - Owner: https://github.com/ensley-nexant
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@02fc38ffb9513e6754e9da54a5bff16e14df29cd -
Trigger Event:
push
-
Statement type:
File details
Details for the file riweather-1.0.2-py3-none-any.whl.
File metadata
- Download URL: riweather-1.0.2-py3-none-any.whl
- Upload date:
- Size: 2.4 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
83454bd23742c0e73383f51b6feed52ed8a4b9251a15db53254b6465bb310b0f
|
|
| MD5 |
39fcdba33a8cb20d5d5e4dcf82e2deab
|
|
| BLAKE2b-256 |
92538786ce6bc2b5cb0b464bedf05312c039a0b834f41ee5d4a67d3f9f56f4c1
|
Provenance
The following attestation bundles were made for riweather-1.0.2-py3-none-any.whl:
Publisher:
release.yml on ensley-nexant/riweather
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
riweather-1.0.2-py3-none-any.whl -
Subject digest:
83454bd23742c0e73383f51b6feed52ed8a4b9251a15db53254b6465bb310b0f - Sigstore transparency entry: 240873875
- Sigstore integration time:
-
Permalink:
ensley-nexant/riweather@02fc38ffb9513e6754e9da54a5bff16e14df29cd -
Branch / Tag:
refs/tags/v1.0.2 - Owner: https://github.com/ensley-nexant
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@02fc38ffb9513e6754e9da54a5bff16e14df29cd -
Trigger Event:
push
-
Statement type: