From 4a989b569350b3dbf233b770117231673b9b76e1 Mon Sep 17 00:00:00 2001 From: Ben Letham Date: Wed, 19 Aug 2020 14:27:20 -0700 Subject: [PATCH] Describe the use of extra regressors for seasonality with monthly data --- notebooks/non-daily_data.ipynb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/notebooks/non-daily_data.ipynb b/notebooks/non-daily_data.ipynb index 3a98be3..a000a22 100644 --- a/notebooks/non-daily_data.ipynb +++ b/notebooks/non-daily_data.ipynb @@ -588,7 +588,9 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "In Python, the frequency can be anything from the pandas list of frequency strings here: https://pandas.pydata.org/pandas-docs/stable/user_guide/timeseries.html#timeseries-offset-aliases . Note that `MS` used here is month-start, meaning the data point is placed on the start of each month." + "In Python, the frequency can be anything from the pandas list of frequency strings here: https://pandas.pydata.org/pandas-docs/stable/user_guide/timeseries.html#timeseries-offset-aliases . Note that `MS` used here is month-start, meaning the data point is placed on the start of each month.\n", + "\n", + "In monthly data, yearly seasonality can also be modeled with binary extra regressors. In particular, the model can use 12 extra regressors like `is_jan`, `is_feb`, etc. where `is_jan` is 1 if the date is in Jan and 0 otherwise. This approach would avoid the within-month unidentifiability seen above. Be sure to use `yearly_seasonality=False` if monthly extra regressors are being added." ] }, {