pysurfline.core.SpotForecasts

class pysurfline.core.SpotForecasts(spotId: str, details: SpotDetails, waves: SpotForecastsWave, winds: SpotForecastsWind, tides: SpotForecastsTides, sunlightTimes: SpotForecastsSunlightTimes, weather: SpotForecastsWeather)

Bases: object

spot forecasts data model

Composite data model of all the spot forecasts data, - wave - condition (TODO) - wind - tides - weather and sunrise and sunset times

TODO: add associated data and improve utcOffset

Methods

__init__(spotId, details, waves, winds, ...)

get_dataframe([attr])

pandas dataframe of selected attribute

Attributes

name

get_dataframe(attr='surf') DataFrame

pandas dataframe of selected attribute

Use default to get the pandas dataframe of surf data, or of the selected attribute attr: - waves - wind - tides - weather - sunlightTimes

Parameters

attr (str, optional) – attribute to get dataframe from. Defaults to “surf”.

Raises

ValueError – if attr is not a valid attribute