You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ie,eg: seasonal_cycle = df.index.dayofweek.values => we know: dayofweek gives 0,1,2,3,4,5,6 max_cycle=np.max(seasonal_cycle) => it takes 6 -- this is wrong
it should take 7 as the max_cycle (-- the period in FourierSeries)
eg:
For a comparison of a simple ex
using 7 clearly fits better than using 6.
eg:
For a comparison of a the textbook energy_consumption data:
(this is not so obvious)
(but you can see, if use 6, there are always 2 days sticks to the same level,, in each period)
The text was updated successfully, but these errors were encountered:
Good catch! It definitely should be 7 and not 6. I'll add it to the errata and correct in the next edition. Can you help me with the chapter number and page number?
Good catch! It definitely should be 7 and not 6. I'll add it to the errata and correct in the next edition. Can you help me with the chapter number and page number?
Chapter 03 > Decomposing a time series > Fourier decomposition
page 67 stl = FourierDecomposition(seasonality_period="hour", model = "additive", n_fourier_terms=5)
Figure 3.16 - Decomposition using Fourier terms (zoomed-in for a month)
Figure 3.17 - Multiple seasonality decomposition using Fourier terms
Figure 3.18 - Multiple seasonality decomposition using Fourier terms (zoomed-in for a month)
For the Textbook's implementation of Seasonal Decompose (STL) with FourierSeries & RidgeCV.
(if I understood correctly)
In
.\src\decomposition\seasonal.py
max_cycle=np.max(seasonal_cycle)
is wrongie,eg:
seasonal_cycle = df.index.dayofweek.values
=> we know: dayofweek gives 0,1,2,3,4,5,6max_cycle=np.max(seasonal_cycle)
=> it takes 6 -- this is wrongit should take
7
as themax_cycle
(-- the period in FourierSeries)eg:
For a comparison of a simple ex
using 7 clearly fits better than using 6.
eg:
For a comparison of a the textbook energy_consumption data:
(this is not so obvious)
(but you can see, if use 6, there are always 2 days sticks to the same level,, in each period)
The text was updated successfully, but these errors were encountered: