# Seasonal time series prediction formula

I've got this prediction problem for daily data across several years. My data has both yearly and weekly seasonality. It's also stationary.

I tried using the following recurrence:(which I just came up with, from nowhere if you like) xn = 1/4(xn-738 + xn-364 + xn-7 + 1/6(xn-1+xn-2+xn-3+xn-4+xn-5+xn-6)

Basically, I am taking into consideration some of the previous days in the week before the day I am trying to predict and also the corresponding day a year and two years earlier. I am doing an average over them.

I got the following histogram of residuals:

Why or Why not would such a formula be a good idea and can I improve this FOR example by adding some terms sampled from a distribution or in another way? Thanks!

• Stationary series can't be seasonal. Please double check your data. Jun 14, 2018 at 16:30
• Yeah, I didn’t realise that stationarity had such a technical definition...I didn’t really check the stationarity But maybe people could help me regardless of that condition? Thanks! Jun 14, 2018 at 20:34

$X_n = a_1 X_{n-1} + a_2 X_{n-2} + a_3 X_{n-3} + ... a_p X_{n-p}$.