Unformatted text preview:

Classical Decomposition Approach to Univariate Time Series Vladas Pipiras STOR UNC CH January 18 2022 What is this all about Suppose given a univariate time series data xt t 1 T where t refers to time and T to the sample size We would like to have a statistical probability model Xt t Z for the series where Xt s are random variables This is reverse engineering of what we did in the previous topic whereas we started with a model and generated data from it we now start with data and would like to t a model to it Having a statistical model we can use it for forecasting prediction which is one of the basic tasks of time series analysis This topic is about a classical approach to time series modeling based on the decomposition possibly after a preliminary transformation Xt mt St Yt t Z where mt t Z is a typically deterministic model for trend St t Z is a typically deterministic periodic model for seasonal variations and Yt t Z is a stationary time series model Motivating example Lake Huron data Annual measurements of the level in feet of Lake Huron 1875 1972 data LakeHuron ts LakeHuron ts Time Series Start 1875 End 1972 Frequency 1 1 580 38 581 86 580 97 580 80 579 79 580 39 580 42 580 82 581 40 581 32 11 581 44 581 68 581 17 580 53 580 01 579 91 579 14 579 16 579 55 579 67 21 578 44 578 24 579 10 579 09 579 35 578 82 579 32 579 01 579 00 579 80 31 579 83 579 72 579 89 580 01 579 37 578 69 578 19 578 67 579 55 578 92 41 578 09 579 37 580 13 580 14 579 51 579 24 578 66 578 86 578 05 577 79 51 576 75 576 75 577 82 578 64 580 58 579 48 577 38 576 90 576 94 576 24 61 576 84 576 85 576 90 577 79 578 18 577 51 577 23 578 42 579 61 579 05 71 579 26 579 22 579 38 579 10 577 95 578 12 579 75 580 85 580 41 579 96 81 579 61 578 76 578 18 577 21 577 13 579 10 578 25 577 91 576 89 575 96 91 576 80 577 68 578 38 578 52 579 74 579 31 579 89 579 96 par mfrow c 1 2 plot ts ts ylab Depth in Feet xlab Year lts length ts plot y ts 2 lts x ts 1 lts 1 ylab Depth in feet xlab Previous Depth in Feet 1 cor ts 2 lts ts 1 lts 1 1 0 8388905 A possibility is also to remove a linear trend years time LakeHuron lm LakeHuron lm LakeHuron years summary lm LakeHuron 1Q Min Max 2 53565 3Q 0 74402 Call lm formula LakeHuron years Residuals Median 2 50997 0 72726 0 00083 Coefficients Intercept 625 554918 years 0 024201 Signif codes 0 0 001 0 01 0 05 0 1 1 Residual standard error 1 13 on 96 degrees of freedom Multiple R squared 0 2725 Adjusted R squared F statistic 35 95 on 1 and 96 DF 80 568 2e 16 5 996 3 55e 08 Estimate Std Error t value Pr t p value 3 545e 08 7 764293 0 004036 0 2649 ts2 resid lm LakeHuron ts2 ts ts2 start c 1875 end c 1972 frequency 1 par mfrow c 1 2 plot ts2 ylab Feet xlab Year 2 YearDepth in Feet188019201960576577578579580581582576578580582576577578579580581582Previous Depth in FeetDepth in feet lts2 length ts2 plot y ts2 2 lts2 x ts2 1 lts2 1 ylab Depth in feet xlab Previous Depth in Feet cor ts2 2 lts2 ts2 1 lts2 1 1 0 7763291 lm LakeHuron2 lm ts2 2 lts2 ts2 1 lts2 1 summary lm LakeHuron2 1Q Min 3Q 0 41780 Max 1 89561 Call lm formula ts2 2 lts2 ts2 1 lts2 1 Residuals Median 1 95881 0 49932 0 00171 Coefficients Intercept 0 01529 ts2 1 lts2 1 0 79112 Signif codes 0 0 001 0 01 0 05 0 1 1 Residual standard error 0 7161 on 95 degrees of freedom 0 5985 Multiple R squared 0 6027 Adjusted R squared F statistic 144 1 on 1 and 95 DF Estimate Std Error t value Pr t 0 834 p value 2 2e 16 0 07272 0 06590 0 21 12 00 2e 16 ts3 resid lm LakeHuron2 par mfrow c 1 2 plot ts3 type l 3 YearFeet188019201960 2 1012 2 1012 2 1012Previous Depth in FeetDepth in feet lts3 length ts3 plot y ts3 2 lts3 x ts3 1 lts3 1 ylab ts3 current xlab ts3 previous cor ts3 2 lts3 ts3 1 lts3 1 1 0 2183583 Possible conclusion Use the model Xt a Xt 1 Zt or Xt a bt Yt with Yt Yt 1 Zt where Zt s are uncorrelated across time t Data Theory goals of the topic In fact after tting a linear trend Xt a bt Yt we will choose the model Yt 1Yt 1 2Yt 2 Zt for the residuals and use it in forecasting to arrive at the following forecasting plot 4 020406080100 2 1012Indexts3 2 1012 2 1012ts3 previousts3 current By the end of the topic you should understand how the model is tted and where such a forecasting plot comes from On the way a number of important notions of time series analysis such as stationarity some stationary models ACF partial ACF and others will also be introduced and discussed Note The material of this topic is most important For example it lays foundation for whatever will be done later in the course Even when dealing with multivariate or high dimensional or time series the univariate series modeling based on the introduced models is always the baseline that is to be improved upon General discussion on classical decomposition Estimating Removing trends and seasonality Several methods Fitting a curve e g a linear trend Moving average Filtering smoothing Di erencing later Fitting a curve In absence of seasonality one could use least squares to t a linear trend or a quadratic trend mt a bt mt a bt ct2 or In absence of trend one could use least squares to t a seasonal periodic model St a0 X aj cos jt bj sin jt j 2 j s j with period s where the sum P j combination when both trend and seasonality are present could be over j 1 K or selective j like harmonics Use a Example US accidental deaths 1973 1978 5 Timets188019001920194019601980576577578579580581582Forecasts for the time series library itsmr y1 hr deaths 12 y2 hr deaths c 12 6 3 par mfrow c 1 2 plotc deaths y1 plotc deaths y2 Moving average Filtering In the ansence of seasonality a moving average estimate of e g a trend is de ned as bmt X j ajxt j a 2xt 2 a 1xt 1 a0xt a1xt 1 a2xt 2 with a lter a aj Often aj a j symmetric and …


View Full Document

CUHK- Shenzhen STOR 556 - Classical Decomposition Approach to Univariate Time Series

Documents in this Course
Load more
Download Classical Decomposition Approach to Univariate Time Series
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Classical Decomposition Approach to Univariate Time Series and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Classical Decomposition Approach to Univariate Time Series and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?