Regression with ARMA Errors

Slides:



Advertisements
Similar presentations
A. The Basic Principle We consider the multivariate extension of multiple linear regression – modeling the relationship between m responses Y 1,…,Y m and.
Advertisements

6-1 Introduction To Empirical Models 6-1 Introduction To Empirical Models.
Time Series Building 1. Model Identification
Regression Analysis Once a linear relationship is defined, the independent variable can be used to forecast the dependent variable. Y ^ = bo + bX bo is.
Regression with ARMA Errors. Example: Seat-belt legislation Story: In February 1983 seat-belt legislation was introduced in UK in the hope of reducing.
Multiple Regression Predicting a response with multiple explanatory variables.
Forecasting JY Le Boudec 1. Contents 1.What is forecasting ? 2.Linear Regression 3.Avoiding Overfitting 4.Differencing 5.ARMA models 6.Sparse ARMA models.
x y z The data as seen in R [1,] population city manager compensation [2,] [3,] [4,]
Examining Relationship of Variables  Response (dependent) variable - measures the outcome of a study.  Explanatory (Independent) variable - explains.
Nemours Biomedical Research Statistics April 2, 2009 Tim Bunnell, Ph.D. & Jobayer Hossain, Ph.D. Nemours Bioinformatics Core Facility.
1 Ka-fu Wong University of Hong Kong Pulling Things Together.
Prediction and model selection
Regression Transformations for Normality and to Simplify Relationships U.S. Coal Mine Production – 2011 Source:
Checking Regression Model Assumptions NBA 2013/14 Player Heights and Weights.
Regression Harry R. Erwin, PhD School of Computing and Technology University of Sunderland.
Regression Analysis Regression analysis is a statistical technique that is very useful for exploring the relationships between two or more variables (one.
9/14/ Lecture 61 STATS 330: Lecture 6. 9/14/ Lecture 62 Inference for the Regression model Aim of today’s lecture: To discuss how we assess.
Analysis of Covariance Harry R. Erwin, PhD School of Computing and Technology University of Sunderland.
 Combines linear regression and ANOVA  Can be used to compare g treatments, after controlling for quantitative factor believed to be related to response.
7.1 - Motivation Motivation Correlation / Simple Linear Regression Correlation / Simple Linear Regression Extensions of Simple.
23-1 Analysis of Covariance (Chapter 16) A procedure for comparing treatment means that incorporates information on a quantitative explanatory variable,
Lecture 3: Inference in Simple Linear Regression BMTRY 701 Biostatistical Methods II.
Managerial Economics Demand Estimation. Scatter Diagram Regression Analysis.
Intervention models Something’s happened around t = 200.
Autocorrelation in Time Series KNNL – Chapter 12.
Lesson Multiple Regression Models. Objectives Obtain the correlation matrix Use technology to find a multiple regression equation Interpret the.
Multiple Regression Petter Mostad Review: Simple linear regression We define a model where are independent (normally distributed) with equal.
Exercise 1 The standard deviation of measurements at low level for a method for detecting benzene in blood is 52 ng/L. What is the Critical Level if we.
Introducing ITSM 2000 By: Amir Heshmaty Far. S EVERAL FUNCTION IN ITSM to analyze and display the properties of time series data to compute and display.
© Copyright McGraw-Hill Correlation and Regression CHAPTER 10.
Tutorial 4 MBP 1010 Kevin Brown. Correlation Review Pearson’s correlation coefficient – Varies between – 1 (perfect negative linear correlation) and 1.
Environmental Modeling Basic Testing Methods - Statistics III.
Applied Statistics Week 4 Exercise 3 Tick bites and suspicion of Borrelia Mihaela Frincu
Estimation Method of Moments (MM) Methods of Moment estimation is a general method where equations for estimating parameters are found by equating population.
Linear Models Alan Lee Sample presentation for STATS 760.
Lesson 14 - R Chapter 14 Review. Objectives Summarize the chapter Define the vocabulary used Complete all objectives Successfully answer any of the review.
1 Chapter 5 : Volatility Models Similar to linear regression analysis, many time series exhibit a non-constant variance (heteroscedasticity). In a regression.
1 Statistics 262: Intermediate Biostatistics Regression Models for longitudinal data: Mixed Models.
Tutorial 5 Thursday February 14 MBP 1010 Kevin Brown.
Statistics 350 Review. Today Today: Review Simple Linear Regression Simple linear regression model: Y i =  for i=1,2,…,n Distribution of errors.
1 Experimental Statistics - week 11 Chapter 11: Linear Regression and Correlation.
Transforming the data Modified from:
Ch5 Relaxing the Assumptions of the Classical Model
Lecture 11: Simple Linear Regression
Regression and Correlation of Data Summary
Regression Analysis AGEC 784.
Chapter 12 Simple Linear Regression and Correlation
Résolution de l’ex 1 p40 t=c(2:12);N=c(55,90,135,245,403,665,1100,1810,3000,4450,7350) T=data.frame(t,N,y=log(N));T; > T t N y
Dynamic Models, Autocorrelation and Forecasting
CHAPTER 7 Linear Correlation & Regression Methods
Inference for Regression
Chapter 11: Simple Linear Regression
Correlation and regression
Checking Regression Model Assumptions
CHAPTER 16 ECONOMIC FORECASTING Damodar Gujarati
Linear Regression Models
Regression with Autocorrelated Errors
Correlation and Regression
CHAPTER 29: Multiple Regression*
Checking Regression Model Assumptions
Chapter 12 – Autocorrelation
Console Editeur : myProg.R 1
Chapter 12 Simple Linear Regression and Correlation
Multiple Regression Models
Regression Transformations for Normality and to Simplify Relationships
Linear regression Fitting a straight line to observations.
Linear Filters.
State-Space Models for Time Series
Time Series introduction in R - Iñaki Puigdollers
Chap 7: Seasonal ARIMA Models
Presentation transcript:

Regression with ARMA Errors

Example: Seat-belt legislation Story: In February 1983 seat-belt legislation was introduced in UK in the hope of reducing the number of deaths and serious injuries on the road. Goal: Check whether or not this law is effective Procedure: Use the number of monthly deaths and serious injuries around the time this law is introduced. Check whether or not there was a drop in the mean number of monthly deaths and serious injuries from that time onwards

1. Formulation Data: Model: Yt, t = 1,…,120 : the number of monthly deaths and serious injuries on UK roads for 10 years beginning in January 1975 (SBL.TSM) ft , t = 1,…,120 : indicator variable showing whether these is this law at time t. ft =0 for 1≤t≤ 98, ft =1 for 99≤t≤ 120 (SBLIN.TSM) Model: Yt = a + b • ft + Wt or Y = Xβ+ W, β=(a,b)T If the estimated value of the coefficient b is significantly negative, the Seat-belt legislation will be considered effective.

2. try OLS regression Assume Wt ~ WN(0, σ2), we can do OLS regression 1. estimate (a, b) by minimizing the sum of squares: which yields: 2. how well the OLS estimator is: 3. If Wt ~ N(0, σ2), we can calculate the 95% confidence interval of b, therefore we can test whether b is significantly different from zero.

Do it in ITSM: 1.File>Project>Open>Univariate then SBL.TSM 2.click Regression>Specify, polynomial regression order=1 auxiliary variable = SBLIN.TSM 3. then click OK and press the GLS button

Results: ======================================== ITSM::(Regression estimates) Method: Generalized Least Squares Y(t) = L(t) + W(t) Trend Function: L(t) = .16211443E+04 t^0 - .29944868E+03 f(t) ARMA Model: W(t) = Z(t) WN Variance = 1.000000 Coeff Value Std Error 0 .16211443E+04 .10153462 1 -.29944868E+03 .23192141

In R > summary(lm(SBL ~ SBLIN)) Call: lm(formula = SBL ~ SBLIN) Residuals: Min 1Q Median 3Q Max -312.14 -162.39 -68.14 104.97 652.86 Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) 1621.14 22.83 71.004 < 2e-16 *** SBLIN -299.45 52.15 -5.742 7.41e-08 *** --- Signif. codes: 0 `***' 0.001 `**' 0.01 `*' 0.05 `.' 0.1 ` ' 1 Residual standard error: 224.9 on 118 degrees of freedom Multiple R-Squared: 0.2184, Adjusted R-squared: 0.2118 F-statistic: 32.97 on 1 and 118 DF, p-value: 7.411e-08

3. check residues Wt Is the assumption Wt ~ WN(0, σ2) correct? Check residue plot and ACF/PACF =>seasonal component with period 12

4. Deseasonalizing Differencing: Yt = a + b • ft + Wt => Mt = Yt – Yt-12 We get : Mt = b • gt + Nt, t=13, …, 120 gt =1 for 99≤t≤110, gt =0 otherwise; Nt = Wt – Wt-12 (In ITSM: Transform > Difference, input 12) Perform OLS regression of Mt (SBLD.TSM) on gt (SBLDIN.TSM) without intercept term. In ITSM: Trend Function: L(t) = - .34691667E+03 g(t) ARMA Model: N(t) = Z(t), WN Variance = 1.000000 Coeff Value Std Error 1 -.34691667E+03 .28867513 In R: (summary(lm(SBLD ~ 0+SBLDIN))) Coefficients: Estimate Std. Error t value Pr(>|t|) SBLDIN -346.9 40.6 -8.545 9.76e-14 ***

5. check residues Nt Is the assumption Nt ~ WN(0, θ2) correct?

6. Fit ARMA(p,q) model for Nt The residue looks stationary ACF/PACF suggest p≤13, q≤13 => Model selection within 0≤p≤13 and 0≤q≤13 by minimizing AICC To Do: Select Model>Estimation>Autofit to fit AR and MA models with order up to 13 to the residues with no mean-correction

Results : MA(12) Method: Maximum Likelihood M(t) = L(t) + N(t), Based on Trend Function: L(t) = - .34691667E+03 g(t) ARMA Model: N(t) = Z(t) + .2189 Z(t-1) + .09762 Z(t-2) + .03093 Z(t-3) + .06447 Z(t-4) + .06878 Z(t-5) + .1109 Z(t-6) + .08120 Z(t-7) + .05650 Z(t-8) + .09192 Z(t-9) - .02828 Z(t-10) + .1826 Z(t-11) - .6267 Z(t-12) WN Variance = .125967E+05 MA Coefficients .218866 .097620 .030935 .064468 .068780 .110918 .081204 .056495 .091917 -.028275 .182628 -.626664 Standard Error of MA Coefficients .074987 .075880 .076411 .075956 .076014 .075901 .075901 .076014 .075956 .076411 .075880 .074987 (Residual SS)/N = .125967E+05 AICC = .136720E+04 AICC = .136984E+04 (Corrected for regression) BIC = .135676E+04 -2Log(Likelihood) = .133733E+04 Accuracy parameter = .100000E-08 Number of iterations = 1 Number of function evaluations = 239136 Uncertain minimum.

7. so Nt is not white noise, we shall improve out previous estimate of b by recursion Step1. by OLS => fit ARMA(p,q) to Nt, we improved our knowledge about Nt : white noise => MA(12) Step2. with this new knowledge of Nt, we can go back to improve the estimate of b by GLS using the new Γ=E(NTN). => Step3. compute new residue Nt using the new estimate of b, fit an ARMA(p,q) like what we did before Step4. repeat step2 and then step3, until the estimators have stabilized.

To Do: After fitting ARMA(p,q) model for Nt, the model in the Regression estimates window is automatically updated to: M(t) = L(t) + N(t) L(t) = - 0.32844534E+03 g(t) Press MLE button for a new round of iteration Finally we arrive at the model: Mt = b • gt + Nt,, b=-328.45, SE(b) = 49.41 N(t) = Z(t) + .2189 Z(t-1) + .09762 Z(t-2) + .03093 Z(t-3) + .06447 Z(t-4) + .06878 Z(t-5) + .1109 Z(t-6) + .08120 Z(t-7) + .05650 Z(t-8) + .09192 Z(t-9) - .02828 Z(t-10) + .1826 Z(t-11) - .6267 Z(t-12) Z(t) ~ WN(0, 12581)

Conclusion Mt = b • gt + Nt,, b=-328.45, SE(b) = 49.41 =>So b is significantly negative => the law has good effect To Do: Regression > Show Fit