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

Multiple seasonal periods? #2

Closed
CoteDave opened this issue Nov 16, 2021 · 2 comments
Closed

Multiple seasonal periods? #2

CoteDave opened this issue Nov 16, 2021 · 2 comments

Comments

@CoteDave
Copy link

Hi,

Suppose I have a daily time serie with weekly, monthly and yearly seasonnalities.

Is it possible to mix the 3 seasonalities together ?

Because if we write seasonal_period=[7, 30, 365] in the boosted_model.optimize, it will choose the best of the 3... however, the best one is the combination of the 3 seasonalities!

Thanks!

@CoteDave
Copy link
Author

I think i found the way:

seasonal_period=[[7, 30, 365]] seems to do the job!

However, can we extract each seasonalities compound individually ? Because when we do boosted_model.plot_components(output), it only plot the combined seasonalities ?

Thanks!

@tblume1992
Copy link
Owner

Yep, when using optimize or ensemble you must pass all the standard arguments as a list where each element would belong to a single fit.
The ability to view each individual seasonality is definitely a good idea and I'll add it to the TODO list. It isn't currently built out but you can gain access to each round's seasonality (or trend/exogenous as well). Think this should work:

seasonality_rounds = boosted_model.booster_obj.seasonalities
weekly = seasonality_rounds[::3]
monthly = seasonality_rounds[1::3]
yearly = seasonality_rounds[2::3]

Then just sum up each piece.

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