diff options
-rw-r--r-- | windy/point_forecast.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/windy/point_forecast.py b/windy/point_forecast.py index 938d30e..0132751 100644 --- a/windy/point_forecast.py +++ b/windy/point_forecast.py @@ -120,6 +120,17 @@ class Prediction: def timestamp(self) -> datetime: return self._response.timestamps[self._index] + @property + def parameters(self) -> tuple: + return self._response.parameters + + @property + def levels(self) -> tuple: + return self._response.levels + + def __iter__(self): + return iter(self.parameters) + def __getitem__(self, key): return self._response.samples[key][self._index] |