Created
June 1, 2019 16:32
-
-
Save jetnew/25370668843d15f589c6981adf25abab to your computer and use it in GitHub Desktop.
Holt Winters additive using statsmodels
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from statsmodels.tsa.holtwinters import ExponentialSmoothing | |
fit = ExponentialSmoothing(data, seasonal_periods=periodicity, trend='add', seasonal='add').fit(use_boxcox=True) | |
fit.fittedvalues.plot(color='blue') | |
fit.forecast(5).plot(color='green') | |
plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment