Module 7 Estimation and Diagnostic Checking for ARMA and ARIMA Models Class notes for Statistics 451: Applied Time Series Iowa State University Copyright 2015 W. Q. Meeker. February 6, 2016 18h 50min ARMA/ARIMA Estimation Methods 7-1 For a specified ARMA(p, q) model and data, (Z1, Z2, . . . , Zn), we “fit” the model by estimating the parameters φ1, . . . , φp and θ1, . . . , θq . • Method of moments: Compute ρb1, ρb2, . . . , ρbp+q , substitute into the “true” ACF equations ρ1 = · · · , ρ2 = · · · , . . . , ρp+q = · · · and solve for φb1, . . . , φbp, θb1, . . . , θbq . SSQ = n X t=1 b t2 = a (Zt − Zbt)2 t=1 n X • Nonlinear least squares: Find φb1, . . . , φbp, θb1, . . . , θbq to minimize • • • • • • • •• • • • • • • •• • • • • • • •• • • • • • • • • •• • • • • • • Simulated Time Series #C • • •• • • • • • • • • • • • • • • • • • • 40 • • • 50 • • • • • • 7-3 60 • • • • •• •• • •• • • • • • • • • • • • •• • • • • • • •• • • • • • •• • • • • • • • • • • • • •• • • • • • • • • • •• • • • •• • • • • •• • • • •• • • Time Series Plot of Simulated Series C • •• • • •• •• • • • • • • • • • • • • • • • • •• • •• • • • • • • • • • 30 Module 7 Segment 1 Introduction to Time Series Model Estimation 1 7-2 Nonlinear Least Squares and Maximum Likelihood n X t=1 b t2 = a n X (Zt − Zbt)2 t=1 b t−1 )]2 [Zt − (Zt−1 − θ1a b t−1 )2 (Wt + θ1a t=1 n X t=1 n X b t−1 Zbt = Zt−1 − θ1a SSQ(θ) = Example: Nonlinear Least Squares for IMA(1,1) Minimize: IMA(1,1) forecast: SSQ(θ) = = b b t−2 . b t−1 = Zt−1 − Z where Wt = Zt −Zt−1 and a t−1 = Wt−1 +θ1a θb is the value of θ that minimizes SSQ(θ). b recursively. • Need to compute a Mean 30 45 Range-Mean Plot 40 50 w= Sales time 40 0 0 10 10 Simulated Time Series #C 55 50 ACF 20 Lag PACF 20 Lag 30 30 7-6 60 7-4 b 0?). • Need some way to start the recursion (i.e., what is a 35 Function iden Output for Simulated Series C [iden(simnsc.tsd)] • Nonlinear optimization needed in general. 20 30 1.0 0.5 60 where Zbt is the one-step-ahead forecast for Zt. Sales • Maximum Likelihood: Find values of the parameters that maximize the probability of the data. Log(likelihood)≈ −n log(SSQ). 20 Time 7-5 ACF Partial ACF 0.0 -1.0 1.0 0.5 0.0 -1.0 w Range 50 40 30 20 30 25 20 15 60 50 40 30 20 10 0.6 30 ACF 20 Lag 30 40 time 0 Simulated Time Series #C w= (1-B)^ 1 Sales 0.7 ma(1) 0.8 10 50 PACF 20 Lag 0.9 30 Plot of IMA(1,1) Model Log-likelihood for Simulated Series C Zt = Zt−1 − θ1at−1 + at • • • • • • • • • •• • • • • • • • • • • • • • • • • • • • • • • • •• • •• • • • • • •• • • • • •• • • • • • • • Simulated Time Series #C Model: Component 1 :: ndiff= 1 ma: 1 on w= Sales • • • • • • • • • • • • •• • • • • • •• • • •• • • • • • •• • • • • • • •• • • • • • 10 • •• • • • • • • • • • • • • 20 • • • • • • • 50 • • Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * • • 40 Index Normal Probability Plot Residuals 0 • • •• •• •• ••• ••• •••• ••••• •• • •• ••• • •• •• •••••• ••• ••••• ••• •• ••••• ••• •••• ••• •••• •••• ••• •• •• •••• ••• ••• •• •• -10 • • • • • • • • • •• • • • • •• • • •• • • • • • • • • • • • • • • • • • •• • 60 7-7 7-9 • • •••••••••••••••••••••••• •• • 60 -1350 -1400 -1450 • • •• • • • •• • • •• • • 0.0 ma(1) 0.5 Plot of IMA(1,1) Model Log-likelihood for Simulated Series C Zt = Zt−1 − θ1at−1 + at -0.5 • • • • • • • • • • • • • •• • • • • •• • • • • • • • • 30 • • • 45 • • •• • • • •• ••• • • • • 50 • • • • • • • • • • • •• • • • ••• • • • Residuals vs. Fitted Values • • • • • • • • • • •• • •• • • • • • • • • • •• • • • •• •• • • •• • • •• •• • • • • • • • • • •• • • • • • • • •• ••• • • • • • • •• • • • 40 • • • Simulated Time Series #C • • • • • • • • • Time 40 Residuals vs. Time • • •• • • • • • 60 0 Model: Component 1 :: ndiff= 1 ma: 1 on w= Sales • • 55 10 50 Residual ACF 20 Lag 30 1.0 Function esti Output for Simulated Series C IMA(1,1) Model—Part 1 [esti(simnsc.tsd, model=model.pdq(d=1, q=1))] • • 35 Fitted Values Module 7 Segment 2 7-8 60 7 - 10 7 - 12 Device Inventory Modeling, Graphical Outputs from Function esti and Diagnostic Checking Introduction to Time Series Model Estimation 2 30 • •• 20 -1500 Function iden Output for the First Differences of Simulated Series C [iden(simnsc.tsd, d=1)] • • • • • • • • • • • ACF 20 0 • • • • • • • • -20 7 - 11 1.0 0.5 0.0 -0.5 -1.0 20 10 0 -10 -20 20 10 0 log-ikelihood Residuals Residuals Partial ACF Function esti Output for for Simulated Series C IMA(1,1) Model—Part 2 • • • • • 30 Normal Scores -10 -20 1.0 0.0 -1.0 0 10 -20 1.0 0.0 -1.0 -1315 w ACF log-ikelihood Sales -1320 -1325 -1330 -1335 20 3 2 1 0 -1 -2 -3 60 50 40 30 20 10 • Year 1989 1990 1991 1992 1993 • • •• • • • • • • •• •• • • ••• ••• ••• ••• ••• • • •• • • • •• •• •• • • • • • •• •• • •• • • •• • • • •• • • • • • •• • 1988 7 - 13 1995 • • •• •••• •••• •• 1994 • • • Time Series Plot of the Device Inventory Data (negative inventory indicates number of units that have been back-ordered) Device Inventory 1984-1994 1987 •• • •• • •• ••• • •• 1986 • ••• • • • • • • • • • •• •• • • ••• •• •• • 1985 1986 ACF 20 Lag 1987 30 1990 time 1989 1991 Device Inventory 1984-1994 w= (1-B)^ 1 Number of Devices 1988 0 1992 10 1993 PACF 20 Lag 1994 30 1995 1984 1985 1986 1987 Range-Mean Plot 10 Mean 15 time 10 1990 w= Number of Devices 1989 0 10 1991 Device Inventory 1984-1994 1988 0 1992 Lag 20 PACF Lag 20 ACF 1993 30 30 1994 7 - 14 1995 Function iden Output for The Device Inventory Data w 1984 0 0.80 1985 10 1986 ACF 20 Lag 1987 0.85 1989 1990 time 0 1991 Device Inventory 1984-1994 w= (1-B)^ 2 Number of Devices 1988 0.90 ar(1) 1992 10 1993 Lag 20 PACF 0.95 1994 30 7 - 16 1995 1.00 7 - 18 Plot of AR(1) Model Log-likelihood for the Device Inventory Data Zt = θ0 + φ1Zt−1 + at 30 Function iden Output for the Second Differences of the Device Inventory Data 5 1.0 0.5 0.0 -1.0 1.0 0.5 0.0 -1.0 20 15 10 5 0 -5 12 10 8 6 4 2 ACF Partial ACF Partial ACF 1984 1985 10 7 - 15 1.0 0.0 -1.0 2 0 Function iden Output for the First Differences of the Device Inventory Data 1984 0 • Normal probability (Q-Q) plot of the residuals 7 - 17 • Plot showing original data, fitted values, forecasts, and forecast intervals • Plot of ACF of the residuals • Plot of residuals versus fitted values • Plot of residuals versus time Graphical Outputs From the esti command Partial ACF -2 -4 1.0 20 15 10 5 0 -5 2 Range w ACF log-ikelihood 1.0 0.0 -1.0 0.0 -1.0 -450 -500 -550 Hundreds of Devices w ACF 0 -2 1.0 0.0 -1.0 • • • 1985 0.975 1986 • • • 1987 Fitted Values 10 • • • •• • • • • • • • ••• • • •• • •• • ••• • • • • • •• • •• • • •• • • • •• • • • • • • • • • • • • • • • • • Residuals vs. Fitted Values • • • • • • • •• • •• • • • • • • • • • • • • • •• • • • • • • 0.980 • • 1989 • • • 0.985 ar(1) • • Time • 1990 1991 0.990 0.995 1993 Lag 20 Residual ACF 1994 1.000 1995 Commands for Making Plots of ARMA Model Log-likelihoods arima.likelihood.plot(device.inventory.tsd, model = model.pdq(p = 1), list(1, seq(.8, .999, length = 50))) #this is the zoom-in of the AR(1); arima.likelihood.plot(device.inventory.tsd, model = model.pdq(p = 1), list(1, seq(.97, .999, length = 50))) • • • •• 1984 -5 •• • • • ••• • • • •••••• 1985 • • • • •• • • ••• • 1986 • • • • • • 1986 • • • • • • • • • • • •• • ••• • • • • • • ••••• 1987 • Fitted Values 10 • ••• 1988 • ••• Residuals vs. Fitted Values • • •• • 5 • • • • •• • • • • • • • • •• • • • • • • • • • • • • • • •• • • • • • • • • • •• • • • • •• • • • • • • ••• • • • • • • • • • •• • • • • • •• • • • 0 • ••• Device Inventory 1984-1994 ••• • • -2 2 • • • • • • •• •• • •• • •• •• • •• • •• Index Residuals 0 •• •• •• ••• ••• ••• ••• ••• ••• •••• ••• •••• ••• ••• •• •••• ••• •••• ••• •••• ••• ••• •• •• • •• •• • • • Normal Probability Plot 1990 •• • •••• •••• • • ••• •• 1992 • Device Inventory 1984-1994 • • • • • • • • 1989 • • • • • Time 1990 Residuals vs. Time • • •• 20 0 • •• •• 1991 Model: Component 1 :: ar: 1 2 on w= Number of Devices • • • 1988 • • 15 • • • • • • • • • • • • 1992 10 • • • •• •••• 1994 ••••• 1993 • 1996 7 - 22 ••••••••••••••••••••••••• Residual ACF 20 Lag 1994 30 7 - 24 1995 Function esti Output for the Device Inventory Data AR(2) Model—Part 1 1984 Model: Component 1 :: ar: 1 on w= Number of Devices • • • • •• • 10 Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * • • • • • • 20 0 Residuals vs. Time Device Inventory 1984-1994 1988 • 15 (1,1,1) 1 Normal Scores 10 Model: Component 1 :: ar: 1 on w= Number of Devices 1992 30 7 - 20 • • • 5 7 - 21 ARIMA(p, d, q) Model (2,0,0) (3,0,0) (1,1,0) 0 0 1 1.06 387.08 383.08 2.73 2 1 0 -1 -2 1984 • • 0 20 7 - 19 • -5 (1,0,0) 0 .18 (.84) .55 (3.0) — — .98 (55.4) — 1.37 (17.2) -.4 (-5.1) — 1.35 (15.4) -.24 (-1.7) -.11 (-1.2) — — 1.06 386.13 384.13 3.49 — — — — 386.35 380.35 2.17 — — — 1.04 1, 2 1.14 385.13 381.13 1.06 2 .39 (4.9) — Comparison of Models for the Device Inventory Data d (# differences) φ1 φ2 φ3 θ1 b) Sig. ρbk (a 409.05 407.05 4.35 ACF ACF 0 -10 2 1 0 1.0 0.5 0.0 -0.5 -1.0 30.26 7 - 23 1.0 0.5 0.0 -0.5 -1.0 Residuals Residuals -1 -2 -3 -4 2 1 0 -1 -2 -3 -4 S AICc −2 log(Likelihood) 2 Ljung-Box χ6 Number of Devices Function esti Output for the Device Inventory Data AR(1) Model—Part 2 0.970 Plot of AR(1) Model Log-likelihood for the Device Inventory Data Zt = θ0 + φ1zt−1 + at -407.5 -408.0 -408.5 -409.0 -409.5 -410.0 Function esti Output for the Device Inventory Data AR(1) Model—Part 1 log-ikelihood Residuals Residuals 2 0 -2 2 0 -2 • • ••• • • • • •• • ••• • • • • • • • •• ••• • • • • ••••• • • • • • • • • • • • • • • • •• •••• ••••• • •• •••••••• •••••••• ••••••• • •• • ••• • • • • •• • ••• • • • • • • • •• ••• • • • • ••••• • ••• ••• ••• ••• -2 2 • • • • • • •• •• • •• • •• •• • •• • •• Index Residuals 0 •• •• •• ••• ••• ••• ••• ••• ••• •••• ••• •••• ••• ••• •• •••• ••• •••• ••• •••• ••• ••• •• •• • •• •• • • • Normal Probability Plot 1990 •• • •••• •••• • • ••• •• 1992 • • •• •• • • • • • • • • • • • • • • •• •••• 1994 • ••••• • 1996 7 - 26 ••••••••••••••••••••••••• Function esti Output for the Device Inventory Data AR(1) Model—Part 2 • •• •••••• 1988 • • Device Inventory 1984-1994 • •• •• • Model: Component 1 :: ar: 1 on w= Number of Devices ••• •• 1992 • 1986 Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * • 2 • •• •• • • • •• •• • •• • •• •• • •• • •• 1 1984 Device Inventory 1984-1994 •• • •••• •••• • Index 0 1996 Model: Component 1 :: ar: 1 2 on w= Number of Devices ••• ••• ••• • 1990 -1 Residuals 1994 Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * ••• 1988 -2 • ••• •• ••• •• •••• ••• •••• •••• ••• •••• •••• •• ••• ••• ••• •••• ••• •• ••• •• • •• •• •• •• Normal Probability Plot • • Number of Devices Function esti Output for the Device Inventory Data AR(2) Model—Part 2 • •• •••••• 1986 -3 7 - 25 20 10 0 -10 • Table of Ljung-Box statistics • Table of ACF of the residuals, SE’s and t-ratios • Table of forecasts and prediction intervals Correlation matrix ar(1) ar(2) ar(1) 1.0000000 -0.9801033 ar(2) -0.9801033 1.0000000 Ljung-Box Statistics dof Ljung-Box p-value 4 3.360982 0.4993286 5 4.143612 0.5289303 6 4.358709 0.6282547 . . . 36 31.849559 0.6663509 7 - 30 Tabular esti Output for the Device Inventory Data (not shown by default) 7 - 28 • Variance-covariance and correlation matrices of the estimated parameters. • Constant term estimate, SE, and t-ratio • Table giving MLEs, SE of MLEs, t-ratio, and approximate confidence intervals for each estimated parameter. b a , and the Akaike Information Criterion • Log likelihood, S = σ AICc = −2 log(Likelihood) + 2M where M is the number of estimated parameters in the structural model (usually M = p + q). AICc is one, of many, “model-choice” criteria (see Section 7.7 of Wei for discussion of others). Tabular Outputs From the esti Command Normal Scores •• 1984 • -4 Module 7 Segment 3 7 - 27 Tabular Outputs from Function esti and More Diagnostic Checking Device Inventory Modeling Continued Normal Scores Tabular esti Output for the Device Inventory Data Number of Devices > esti(device.inventory.tsd, model=model.pdq(p=2),y.range =c(-12,22)) + + Estimation/Forecasting Output for Device Inventory 1984-1994 ARIMA estimation results: Model: Component 1 :: ar: 1 2 AICc: 385.1348 -2(Log Likelihood): 381.1348 S: 1.048085 Parameter Estimation Results MLE se t.ratio 95% lower 95% upper ar(1) 1.3780133 0.08015244 17.192406 1.2209145 1.5351121 ar(2) -0.4059878 0.08015244 -5.065196 -0.5630866 -0.2488891 Constant term: 6.193324 Standard error: 0.09192312 t-ratio: 67.37504 7 - 29 2 1 0 -1 -2 2 1 0 -1 -2 20 10 0 -10 7 - 31 Tabular esti Output for the Device Inventory Data (not shown by default) Residual ACF Lag ACF se t-ratio 1 1 -0.054279383 0.08770580 -0.61888019 2 2 0.132883340 0.08796383 1.51065894 3 3 -0.035326410 0.08949467 -0.39473200 . . . 38 38 -0.065383330 0.10392757 -0.62912398 Forecasts Lower Forecast Upper 1 1.59811508 3.652324 5.706532 2 -0.02084244 3.476698 6.974238 . . . Other Diagnostic Checks • Overfitting (add parameters to model looking for improvement) • Make sure that the forecasts are reasonable; compare forecasts from different candidate models. • Split the realization to see if the model and parameters agree on both sides (check for a change in the process). • If there are outliers, do sensitivity analysis by moving outliers into the data • If there is an indication of estimation problems, look at the likelihood (or sum of squares) surface -1200 -500 -500 -500 -500 -1100 -1000 -900 -800 -700 -600 -500 -400 -400 -400 -400 -400 -400 -400 -400 1 2 Diagnostic Checks Based on Residuals • Need to check the assumption at ∼ nid(0, σ 2) b t versus time • Plot of the residuals “time series” a b ) of the residuals • ACF function ρbk (a To judge H0 : ρk (a) = 0, be suspicious of values of the asb )/Sρb (b sociated t-like-ratio tk = ρbk (a that are outside ±1.5. k a) b) (n − k)−1 ρbk2(a • Ljung-Box test for H0 : ρ1(a) = ρ2(a) = . . . = ρK (a) = 0 K X k=1 Q = n(n + 2) 2 Be suspicious if Q > χ(1−α;K−p−q) • Plot of residuals versus fitted values 7 - 32 • Normal probability (Q-Q) plot of residuals to check normality assumption Module 7 Segment 4 Device Inventory Modeling Continued AR(2) Likelihood and Comparison with an AR(3) Model -700 1.2 -650 1.3 -600 1.4 -550 -500 ar(1) 1.5 -450 -400 1.6 -700 -650 -600 -550 -500 -450 -400 1.7 1.8 7 - 34 -1250 0 ar(1) 7 - 36 7 - 33 -1280 -1 ar(2) Plot of AR(2) Model Log-likelihood Surface for the Device Inventory Data ar(2) Plot of AR(2) Model Log-likelihood Surface for the Device Inventory Data -2 7 - 35 -0.3 -0.4 -0.5 -0.6 1.0 0.5 0.0 -0.5 -1.0 1984 • • •• ••• • • • • • •• •• • • • • •• • 1985 • • • • 0 • • • • 1986 • • • • • • • 1987 • Fitted Values 10 • Residuals vs. Fitted Values • 5 • • • • • • • • • •• • •• • •• •• • • • • • • • • ••• • • •• • • • • • •• • •• • • •• • • • •• • • • • • •• • • • • • • •• • • •• • ••• • • • • • • • •• ••• • • • • ••••• • -383 ar(1) 1.385 -382.8 -382.6 1.390 1992 1993 1994 -384.8 -384.6 -384.4 -384.2 -384 -383.8 -383.4 -383.6 -383 -383.2 -382.8 -382.6 30 • • • • 1989 • • Time • • • 1990 1991 Lag 20 Residual ACF 1995 Index -1 0 Residuals 1 • 2 • •• •• • • • •• •• • •• • •• •• • •• • •• 1990 •• • •••• •••• • -2 • ••• •• ••• •• •••• ••• •••• •••• ••• •••• •••• •• ••• ••• ••• •••• ••• •• ••• •• • •• •• •• •• Normal Probability Plot • • ••• •• 1992 • • •• •• • • • • • • • • • • • • • • • •• •••• 1994 ••••• • •• •••••••• •••••••• 1996 ••••••• Commands for making Log-likelihood Surface Contour Plots arima.contour(device.inventory.tsd, model = model.pdq(p = 2), list(1, seq(-1.9, 1.9, length = 50)), list(2, seq(-.99, .99, length = 50))) arima.contour(device.inventory.tsd, model = model.pdq(p = 2), list(1, seq(1.377, 1.394, length = 40)), list(2, seq(-0.406, -0.390, length = 40))) • • •• •• • ••• • •••••• • • • •• • ••• • 1986 • • • • • • •• ••• • • • • ••••• • ••• 1988 ••• ••• Device Inventory 1984-1994 • ••• -4 • • • • -2 •• 1 2 • • •• •• • • • •• •• • •• • •• •• • •• • •• Index 0 Residuals -1 • •• ••• •• • ••• •• ••• •••• ••• •••• ••• ••• •••• ••• ••• •••• •••• ••• •••• ••• •• •• ••• ••• Normal Probability Plot 1990 •• • •••• •••• • -3 Module 7 ••• •• • 1992 Segment 5 • •• •• • • • • • • • • • • • • • • • •• •••• 1994 ••••• • • ••• 1996 ••••••••••••••••• Device Inventory Modeling Continued •••• 7 - 40 7 - 42 Using a Model with a Unit Root and Trying an Overfit 1984 Model: Component 1 :: ar: 1 2 3 on w= Number of Devices • • • • • • 10 Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * • 0 7 - 39 Residuals vs. Time Device Inventory 1984-1994 • 20 Device Inventory 1984-1994 Model: Component 1 :: ar: 1 2 on w= Number of Devices • -3 Normal Scores 10 0 -10 1 Model: Component 1 :: ar: 1 2 3 on w= Number of Devices • • • 1988 • • 15 ACF Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * • ••••• • ••• ••• • -4 7 - 41 2 1 0 -1 • • • 20 7 - 38 • -5 •• 1988 Number of Devices 7 - 37 1.380 -384.6 -384.4 -384.2-384-383.8-383.6-383.4 -383.2 -384.8 Plot of AR(2) Model Log-likelihood Surface for the Device Inventory Data Close-up View -0.390 -0.395 -0.400 -0.405 Function esti Output for the Device Inventory Data AR(3) Model—Part 2 Number of Devices Function esti Output for the Device Inventory Data AR(2) Model—Part 2 • •••••• 1986 Normal Scores • 1984 2 1 0 -1 -2 -2 1.0 0.5 0.0 -0.5 -1.0 2 Function esti Output for the Device Inventory Data AR(3) Model—Part 1 ar(2) Residuals Residuals 0 -1 -2 -3 -4 2 1 0 -1 -2 -3 -4 20 10 0 -10 1984 • • • • ••• • • • • 1986 • • • • • • • • • • • • • 1987 • Fitted Values 10 • Residuals vs. Fitted Values • • •• • 5 • • •• • • • • • • • • • •• • • • • • • • • • •• • • • • •• • •• • •• • • • • • • •• •• • • • • • •• • • • • • • • • • •• •• • • • • • •• • 1985 • • • 0 •••••• • • • • • • •• •• • ••• • • ••• • • • • • • • • • • • • • •• •• ••• • • • ••• • • • • • ••••• • • ••• • • •• • • • • • 1989 • •• • • Time • • 1990 1991 1992 10 1993 1994 30 Lag 20 Residual ACF 1995 • Index 1 • •• ••• •• • ••• ••• ••• •••• ••• •••• ••• ••• •••• ••• ••• •••• •••• ••• •••• ••• •• •• ••• ••• 0 Residuals -1 2 • • •• •• • • • •• •• • •• • •• •• • •• • •• 1990 •• • •••• •••• • -2 •• Normal Probability Plot • • • 2 ••• •• • 1992 ••• •• 1992 • • •• •• • •• •• • • • • • • • • • • • • • • • • • • • • • • • • • • •• •••• 1994 • •• •••• 1994 ••••• ••••• • • • • ••• ••••••••••••••••• 1996 •••• 7 - 45 ••• ••••••••••••••••••••• 1996 • • •• •• • ••• • •••••• • • • •• • ••• • 1986 • • • • • • •• ••• • • • • ••••• • ••• 1988 ••• ••• Device Inventory 1984-1994 • ••• -4 • -2 •• •• • • • • • • • •• •• • •• • •• •• • •• • •• Index 0 Residuals -1 1 2 • • •• •• •• ••• •• • ••• ••• ••• ••• ••• ••• •••• ••• •••• ••• ••• •••• •••• ••• ••• •• ••• ••• ••• ••• Normal Probability Plot 1990 •• • •••• •••• • -3 ••• •• 1992 • • •• •• • • • • • • • • • • • • • • •• •••• 1994 • ••••• • •• 1996 7 - 44 ••••••••••••••••••••••• Function esti Output for the Device Inventory Data ARIMA(1,1,0) Model—Part 2 • 1984 -5 • • • •• 1984 • •• • • • ••• • • • •• •• • • • • •• • • • 1985 • • • • 0 •••••• • • • • 1986 • •• • • • • • • • • • • • • • • 1987 • •• Fitted Values • 10 • • • • Device Inventory 1984-1994 • • • 1988 • • 15 • • • • • • • • 1989 • • • • • Time 1990 Residuals vs. Time • • • • 20 0 1991 Model: Component 1 :: ndiff= 1 ma: 1 ar: 1 on w= Number of Devices Residuals vs. Fitted Values • 5 • • • • • •• • • •• • • •• •• • • • • • ••• • • • • • •• • • • • • ••• • • • ••• • •• • • • •• • • • •• • ••• • 1986 • • • • • • •• ••• • • • • ••••• • ••• Device Inventory 1984-1994 Model: Component 1 :: ndiff= 1 ar: 1 on w= Number of Devices ••• ••• • • -3 -2 •• •• • • • • • • • •• •• • •• • •• •• • •• • •• Index 0 Residuals -1 1 2 • • •• •• •• ••• •• • ••• ••• ••• ••• ••• ••• •••• ••• •••• ••• ••• •••• •••• ••• ••• •• ••• ••• ••• ••• Normal Probability Plot 1990 •• • •••• •••• • ••• •• 1992 • • •• •• • • • Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * ••• 1988 -4 • • • 1992 10 • • • • • • • • 1993 Lag 20 Residual ACF •• •••• 1994 • ••••• • •• 1994 1996 1995 7 - 46 7 - 48 ••••••••••••••••••••••• Function esti Output for the Device Inventory Data ARIMA(1,1,0) Model—Part 2 30 Function esti Output for the Device Inventory Data ARIMA(1,1,1) Model—Part 1 1984 Model: Component 1 :: ndiff= 1 ar: 1 on w= Number of Devices • 0 Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * • 20 7 - 43 Residuals vs. Time Device Inventory 1984-1994 • • ••• -3 Device Inventory 1984-1994 Model: Component 1 :: ndiff= 1 ma: 1 ar: 1 on w= Number of Devices 1 • Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * ••• ••• • • • •• •• • •• • •• •• • •• • •• Index 0 10 Model: Component 1 :: ndiff= 1 ar: 1 on w= Number of Devices • 1988 • • 15 Device Inventory 1984-1994 Model: Component 1 :: ar: 1 2 3 on w= Number of Devices ••• • • Actual Values * * * Fitted Values * * * Future Values * * 95 % Prediction Interval * * ••• 1988 ••••• ••• 20 Function esti Output for the Device Inventory Data ARIMA(1,1,0) Model—Part 1 • -5 • • 1986 -4 • Function esti Output for the Device Inventory Data AR(3) Model—Part 2 • •• • •• • •••• •••• • 1990 -1 Residuals • • •• •• •• ••• Normal Probability Plot -2 •• •••• •• ••• ••• •••• ••• ••• •••• •••• ••• •••• •••• •••• ••• ••• ••• ••• ••• ••• •• •• • • • • ACF •• 1984 ••• ••• • -3 1.0 0.5 0.0 -0.5 -1.0 2 1 Function esti Output for the Device Inventory Data ARIMA(1,1,1) Model—Part 2 • • 1988 • Normal Scores Normal Scores • •• •••••• 1986 -4 7 - 47 2 1 0 -1 -2 2 1 0 -1 -2 •• 1984 Number of Devices Residuals ACF 0 -10 2 1 0 -1 -2 -3 -4 2 1 0 -1 -2 -3 -4 20 Normal Scores Normal Scores 10 Number of Devices Number of Devices Residuals Number of Devices 2 1 0 -1 -2 2 1 0 -1 -2 0 -10 1.0 0.5 0.0 -0.5 -1.0 Residuals Residuals 0 -1 -2 -3 -4 2 1 0 -1 -2 -3 -4 20 10 0 -10 20 10 0 -10 -800 -0.5 -500 -700 0.0 ar(1) -600 -600 0.5 -500 -385 -400 7 - 49 Plot of ARIMA(1,1,1) Model Log-likelihood Surface for the Device Inventory Data -480 0.2 -390 -460 d (# differences) φ1 φ2 φ3 θ1 b) Sig. ρbk (a S AICc −2 log(Likelihood) 2 Ljung-Box χ6 -440 -395 0.4 -400 -420 0.6 -383.2 ar(1) -400 -395 -384 -420 -390 -385 0.8 -440 1, 2 — — 1.04 2 — 1.37 (17.2) -.4 (-5.1) — 386.35 380.35 1.06 — 1.35 (15.4) -.24 (-1.7) -.11 (-1.2) — 3.49 386.13 384.13 1.06 — — — .39 (4.9) — ARIMA(p, d, q) Model (2,0,0) (3,0,0) (1,1,0) 0 0 1 2.73 387.08 383.08 1.06 — .18 (.84) — .55 (3.0) — (1,1,1) 1 (1,0,0) 0 1.14 385.13 381.13 2.17 .98 (55.4) — 409.05 407.05 4.35 7 - 53 30.26 Comparison of Models for the Device Inventory Data 7 - 51 Plot of ARIMA(1,1,1) Model Log-likelihood Surface for the Device Inventory Data ma(1) ma(1) 0.5 0 ) (1 ma .5 -0 0 ar(1 ) 0.5 7 - 50 Plot of ARIMA(1,1,1) Model Log-likelihood Surface for the Device Inventory Data 0.6 0.4 0.2 ma ( 1) 0.5 0.6 0.7 0.8 7 - 52 Plot of ARIMA(1,1,1) Model Log-likelihood Surface for the Device Inventory Data Z -500 -400 -300 -900 -800 -700 -600 Z -420 -400 -380 -500 -480 -460 -440 0.5 0.0 -0.5 0.6 0.4 0.2 0.0 -0.2