Hi All,

I have question relate the Centered windows Smoothing in Statistical Forecasting on Synthetic Data Lab.

For Ex: To get the smooth data point at `t=1000`

(i.e. start of the validation set), it will average the measurements at `t=995`

to `t=1005`

.

Here is the code in lab:

## Smooth the original series before adding the time differenced moving average

diff_moving_avg_plus_smooth_past = moving_average_forecast(series[split_time - 370:-359], 11) + diff_moving_avg

I know that we shift 365 so the split_time - 365, and due to the window_size is 11, so we need to increase 5 more, so it becomes split_time - 370, that’s make sense.

For the last: -359, due to shift 365, so at first it will be -365. But the window_size is 11, so we need to increase 5 more. It should be -360.

Why the code is -359 here?

Please explain more for this case.

Thanks in advance,

Dat