Forecasting with Prophet
Instruction: Detail the process of creating a forecast model using Facebook's Prophet library for a hypothetical time series dataset. Include considerations for incorporating holidays and handling outliers.
Updated
Example Answer
I would first define the forecast horizon and prepare a table with dates in ds and the target in y. I would check duplicates, units, missing periods, and how much history supports each seasonal pattern. Then I would fit Prophet and compare it with a simple baseline on rolling forecast cutoffs.
For retail demand, I would include relevant holidays and planned events, then test whether those terms help on later periods. Adding a holiday is not a guaranteed improvement. For suspected outliers, I would distinguish recording errors from real demand spikes. A confirmed bad observation can be marked missing while keeping its date; a genuine promotion may need an event term. I would report horizon-specific errors and interval coverage, especially around those events.
Make it your own
Specify the target, event calendar, forecast horizon, and what qualifies as a data error.
Why this works
It connects configuration choices to evaluation rather than promised accuracy.
Follow-up to practice
What would you do with a genuine event that occurs only once?