# Time series model of intraday data on weekdays and weekends

I would like to model intraday data of energy load. The data show strong seasonality within the day (which is clear and well known) and a different pattern on weekdays and weekends. I use the time series packages of R (package ts and then a decomposition in seasonality, level and trend). I get good results when I just concatenate the data ignoring the day of the week and estimate an aggregate model. But I would like to improve the quality on weekends.

How can I formulate a time series model that distinguishes between weekdays and weekends?

Check out the discussion on http://www.analyticbridge.com/forum/topics/vector-time-series-analysis. The whole idea is to seamlessly integrate daily predictions and hourly predictions into one. This is done while detecting and incorporating multiple level shifts, multiple time trends , the window of response around individual holidays while incorporating weather effects, all while isolating unusual values. You could search for a mixed-frequency suite of software as you have both intra and inter day effects.

• Thank you for your answer and the linke. In the meanwhile I continued my research and I found quite an easy way that might provide a good model. I will post this as an "answer" by myself (then people will more probably see it and discuss it). – Ric Nov 12 '12 at 8:10

One possibility is a 2-step model.

1. Find a trend/Cycle/seasonality model for the data ignoring businessdays/weekedays
2. Then perform a time series regression with dummy variables indicating the issues above (business days, holidays, ...).

Step 2 can be extended to include more predictors. This model is "easy" and I will test its performance.

• The problem with Step 1 is that if tou need Step 2, your results from Step 1 are probably useless. Furthermore Step 1 requires you to specifiy 1) how many trends there are ; 2) How many Step shifts there are ; 3) that the seasonality is fixed ( dummies_) or autoprojective ; 4) the errors from the model have constant variance etc. etc. etc. If your goal is to develop a useful model, this may not be served by doing what's wrong/insufficient first. Ease of use and speed are of interest but should take second place ( a distant second place !) to good analytics. – IrishStat Nov 12 '12 at 14:50
• Thanks for your comments. I will keep this in mind and work through the link that you privided. – Ric Nov 12 '12 at 15:33

if I get you right, I think all you want to do is to estimate a whole model by using weekdays and weekends as well as holidays. For forecasting intraday time series, exponential smoothing is mostly used. This kind of data sets can contain more than seasonal patterns. In these days, e.g. public holidays, the energy demand data (I consider, for example, your univariate time series is all about demand.) can differ greatly from the regular seasonal pattern. In the literature, I have run into with many methods to overcome this problem. One of them, which I think it's a good solution, is to smooth out these values using simple averaging procedures.