Select weather station data
station_name
SELECT date, name, temp as min_temp, max as max_temp, gust as max_gust
FROM demo_db.public.ny_weather
WHERE country = 'US' and name = {{ station_name }}
and date > '2015-12-31'
ORDER BY date DESC
Predict weather data
Select the weather feature to predict
feature
weather_subset=weather[['date', feature]]
weather_subset.columns=['ds', 'y']
m = Prophet()
m.fit(weather_subset)
future = m.make_future_dataframe(periods=365)
forecast = m.predict(future)
Plot weather forecast
my_plot=plot_plotly(m, forecast)
my_plot
my_comps=plot_components_plotly(m, forecast)
my_comps.layout.update({'title': 'Trends grouped by time units (e.g., daily, yearly, weekly'})
my_comps