Search code examples
pythontime-seriesforecastingfacebook-prophet

fbprophet yearly seasonality values too high


I have recently started using fbprophet package in python. I have monthly data for last 2 years and forecasting for next 9 months. Since, I have monthly data I have only included yearly seasonality (Prophet(yearly_seasonality = True)). When I plot components, trend values seem to be fine however, Yearly seasonality values are too high, I don't understand why? Seasonality is showing 300 increase or -200 decrease. However, in actual graph it is not happening in any months in the past - what I can do to correct? Overall Forecast

Trend

Seasonality

Code Used is as follows:

m = Prophet(yearly_seasonality = True)
m.fit(df_bu_country1)
future = m.make_future_dataframe(periods=9, freq='M')
forecast = m.predict(future)
m.plot(forecast)
m.plot_components(forecast)

Solution

  • There is no seasonality at all in your data. For there to be yearly seasonality, you should have a pattern that repeats year after year, but the shape of your time series from 10/2015 to 10/2016 is completely different from the shape between 10/2016 to 10/2017. So forcing a yearly seasonality is going to give you strange results, you should switch it off (i.e. just use Prophet's default settings).