Skip to content

Commit 05717fe

Browse files
authored
Version 1.4.0 (#51)
* Refactor Normals interface * Fix normals point * Rework normals interface * Linting * Finalize normals interface
1 parent 3d0eabc commit 05717fe

File tree

12 files changed

+241
-66
lines changed

12 files changed

+241
-66
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,8 @@ If you want to support the project financially, you can make a donation via [Pay
6464

6565
## Data License
6666

67-
Meteorological data is provided under the terms of the [Creative Commons Attribution-NonCommercial 4.0 International Public License](https://creativecommons.org/licenses/by-nc/4.0/legalcode). You are not allowed to redistribute Meteostat data "as-is" for commercial purposes.
67+
Meteorological data is provided under the terms of the [Creative Commons Attribution-NonCommercial 4.0 International Public License (CC BY-NC 4.0)](https://creativecommons.org/licenses/by-nc/4.0/legalcode). You may build upon the material
68+
for any purpose, even commercially. However, you are not allowed to redistribute Meteostat data "as-is" for commercial purposes.
6869

6970
By using the Meteostat Python library you agree to our [terms of service](https://dev.meteostat.net/docs/terms.html). All meteorological data sources used by the Meteostat project are listed [here](https://dev.meteostat.net/docs/sources.html).
7071

examples/normals/point.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
vancouver = Point(49.2497, -123.1193, 70)
1616

1717
# Get normals
18-
data = Normals(vancouver, 1961, 1990)
18+
data = Normals(vancouver, (1961, 1990))
1919
data = data.fetch()
2020

2121
# Plot chart

examples/normals/simple.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
from meteostat import Normals
1313

1414
# Get normals
15-
data = Normals('10637', 1961, 1990)
15+
data = Normals('10637')
1616
data = data.fetch()
1717

1818
# Plot chart

meteostat/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"""
1313

1414
__appname__ = 'meteostat'
15-
__version__ = '1.3.5'
15+
__version__ = '1.4.0'
1616

1717
from .interface.stations import Stations
1818
from .interface.point import Point

meteostat/interface/daily.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ class Daily(Base):
6666
# Index of first meteorological column
6767
_first_met_col = 1
6868

69-
# Data tapes
69+
# Data types
7070
_types: dict = {
7171
'tavg': 'float64',
7272
'tmin': 'float64',
@@ -245,7 +245,7 @@ def __init__(
245245
if isinstance(loc, pd.DataFrame):
246246
self._stations = loc.index
247247
elif isinstance(loc, Point):
248-
stations = loc.get_stations('hourly', start, end)
248+
stations = loc.get_stations('daily', start, end)
249249
self._stations = stations.index
250250
else:
251251
if not isinstance(loc, list):

meteostat/interface/hourly.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ class Hourly(Base):
7676
# Index of first meteorological column
7777
_first_met_col = 2
7878

79-
# Processed data columns with types
79+
# Data types
8080
_types: dict = {
8181
'temp': 'float64',
8282
'dwpt': 'float64',

meteostat/interface/monthly.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ class Monthly(Base):
6767
# Index of first meteorological column
6868
_first_met_col = 2
6969

70-
# Data tapes
70+
# Data types
7171
_types: dict = {
7272
'tavg': 'float64',
7373
'tmin': 'float64',
@@ -246,7 +246,7 @@ def __init__(
246246
if isinstance(loc, pd.DataFrame):
247247
self._stations = loc.index
248248
elif isinstance(loc, Point):
249-
stations = loc.get_stations('hourly', start, end)
249+
stations = loc.get_stations('monthly', start, end)
250250
self._stations = stations.index
251251
else:
252252
if not isinstance(loc, list):

0 commit comments

Comments
 (0)