Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Holiday as dummy? #76

Closed
fedemendez1 opened this issue May 5, 2021 · 4 comments
Closed

Holiday as dummy? #76

fedemendez1 opened this issue May 5, 2021 · 4 comments

Comments

@fedemendez1
Copy link

Hi guys, even after including the holidays file you supplied, I am still having big underpredictions in xmas week (xmas peaks are quite noticeable).

I tried adding a dummy variable in xmas week in the baseline group of variables but the model drops it (coef=0).
What is the correct way to add a dummy variable? or, is there a way to make the prophet holiday capture these peaks?

Thanks very much,

F

@gufengzhou
Copy link
Contributor

How many years of data do you have? Are you using trend, season and holiday from Prophet? In case of More than one Xmas included in the data (and there is repeating pattern of course), season from prophet should be able to capture that. If not, and in case you are expecting peaks in for example Dec.24-31, one idea might be manually adding all days Dec.24-31 into the holiday csv, so that this will be also captured by the holiday variable from prophet.

@fedemendez1
Copy link
Author

@gufengzhou thank you! Apparently I needed to have the exact observed dates in the holidays file. Now the prophet holiday variable is capturing the peaks.

@fedemendez1
Copy link
Author

Any idea why the holiday variable is driving volume in all weeks? Even weeks I don't have a holiday in holidays.csv ?

image

@gufengzhou
Copy link
Contributor

Hi, first of all please check prophet's documentation for more customised ways of using holidays, for example using lower_windows and upper_windows in the holidays.csv to account for holiday periods. Regarding volumes in non-holiday weeks, it's actually just me linearly transformed the original holiday variable to positive to avoid potential difficulty in decomposition and interpretation later. The variance of holiday won't change by this transformation and the latitude will be adjusted by the beta coefficient anyway.
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants