Lecture 2

22 downloads 301 Views 135KB Size Report
Finite sample properties of the OLS estimators. Gauss-Markov and classical linear model assumptions for time series regression: How do they differ from the ...
Econometrics Week 2 Institute of Economic Studies Faculty of Social Sciences Charles University in Prague

Fall 2012

1 / 23

Recommended Reading

For today Basic regression analysis with time series data Chapter 10 (pp. 311 – 342) For the next week Further issues in using OLS with time series data Chapter 11 (pp. 347 – 370)

2 / 23

Today’s Lecture

What is the basics of the time series data and cross-sectional data. Examples of some time series regressions. Finite sample properties of the OLS estimators. Gauss-Markov and classical linear model assumptions for time series regression: How do they differ from the cross-sectional case? How do we interpret logarithmic functional form and dummy variables? Basic notion about trends and seasonality in multiple regression.

3 / 23

Cross Sectional Data vs. Time Series Data

y t = β0 + β1 xt1 + ut

ut ∼ N (0, σ 2 )

t = 1, 2, . . . , n

4 / 23

The Nature of Time Series Data

Time series vs. cross-sections: Temporal ordering. In the social sciences data, it is crucial to understand that past can effect the future, BUT NOT VICE VERSA Until now, we have studied properties of OLS estimators based on the notion that samples are random. Instead, we have Time Series process, or Stochastic Process “stochastic” from the Greek “stochos”: aim, guess, or characterized by conjuncture and randomness. When we collect the data, we have one realization of the stochastic process.

5 / 23

Examples of Time Series Regression Models: Static Models A contemporaneous (in Czech: “soubˇeˇzn´ y”) relation between y and z can be captured by a static model: yt = β0 + β1 zt + ut ,

t = 1, 2, . . . , n.

When to use? Change in z at time t have immediate effect on y: ∆yt = β1 ∆zt , when ∆ut = 0. We would like to know tradeoff between y and z. Example: Phillips Curve Contemporaneous tradeoff between natural rate of unemployment and inflationary expectations: inft = β0 + β1 unemt + ut Phillips curve assumes that both are constant. 6 / 23

Examples of Time Series Regression Models: Finite Distributed Lag Models (FDL) We allow one or more variables to affect y with a lag. FDL of order two: yt = α0 + δ0 zt + δ1 zt−1 + δ2 zt−2 + ut , Where δ0 is so-called “impact propensity” or “impact multiplier” and it reflects immediate change in y. More generally, a FDL model of order q will include q lags of z. For a temporary, 1-period change, y returns to its original level in period q + 1. We can call δ0 + δ1 + . . . + δq the ‘long-run propensity” (LRP) and it reflects the long-run change in y after a permanent change. 7 / 23

Examples of Time Series Regression Models Note Please note that the static model is a special case of an FDL when setting δ0 , δ1 , . . . , δq to zero: yt = α0 + δ0 zt + δ1 zt−1 + . . . + δq zt−q + ut ↓ ↓ ↓ 0 0 0 Note Often, we have substantial correlation in z at different lags ⇒ multicollinearity

8 / 23

Unbiasedness: Assumptions Ass1: Linear in parameters The stochastic process {(xt1 , xt2 , . . . , xtk , yt ) : t = 1, 2, . . . , n} follows the linear model: yt = β0 + β1 xt1 + . . . + βk xtk + ut ,

(1)

with {ut : t = 1, 2, = . . . , n} sequence of error disturbances and n number if observations (time periods). Ass2: Zero Conditional Mean E(ut |X) = 0,

t = 1, 2, . . . , n.

(2)

⇒ error term in any given period is uncorrelated with explanatory variable in all time periods. 9 / 23

Unbiasedness: Assumptions cont. Ass. (2) implies that explanatory variable is strictly exogenous. Alternative assumption to (2) can be: E(ut |xt1 , . . . , xtk ) = E(ut |xt ) = 0 It implies that xtj are contemporaneously exogenous. It is less strict, as it does not require ut to be uncorrelated with xsj for s 6= t as in Ass. (2). Note In the social sciences, many explanatory variables violate the strict exogeneity assumption!

10 / 23

Unbiasedness: Assumptions cont. Ass. 3: No Perfect Collinearity No independent variable is constant or a perfect linear combination of the others. The issues are essentially the same as with cross-sectional data. Theorem 1: Unbiasedness of OLS Under Ass. (1), (2) and (3), the OLS estimators are unbiased conditional on X, and therefore unconditionally as well: E(βˆj ) = βj , j = 0, 1, . . . , k. The theorem is similar to the one we used in cross-sectional data, but we have omitted random sampling assumption (thanks to the Ass 2.). Ommited variables bring bias as in the cross-sectional data. 11 / 23

The Variance of the OLS Estimators

To be able to round out the Gauss-Markov assumptions for time series regressions, we need 2 more assumptions. Ass. 4: Homoskedasticity Conditional on X, the variance of ut is the same for all t: V ar(ut |X) = V ar(ut ) = σ 2 , t = 1, 2, . . . , n. Thus, the error variance is independent of all x’s and is constant over time. Otherwise, data are heteroskedastic as in cross-sectional case.

12 / 23

The Variance of the OLS Estimators cont.

Final assumption we need is new: Ass. 5: No Serial Correlation Conditional on X, the errors in two different time periods are uncorrelated: Corr(ut , us |X) = 0

for all t 6= s.

Otherwise, the errors are correlated across time and suffer from serial correlation or autocorrelation.

13 / 23

The Variance of the OLS Estimators cont. Theorem 2: OLS Sampling Variances Under the time series Gauss-Markov Ass. (1–5), the variance of βˆj , conditional on X is: V ar(βˆj |X) = σ 2 /[SSTj (1 − Rj2 )],

j = 1, . . . , k,

where SSTj is the total sum of squares of xtj and Rj2 is the R-squared. Theorem 3: Unbiased Estimation of σ 2 Under the Ass.(1–5), the estimator σ 2 = SSR/df is an unbiased estimator of σ 2 , where df = n − k − 1. Theorem 4: Gauss-Markov Theorem Under the Ass. (1–5), the OLS estimators are the best linear unbiased estimator (BLUE) conditional on X. 14 / 23

Inference Under the Classical Linear Model (CLM) Assumptions Thus OLS has the same desirable finite sample properties as in the cross-sectional data case, under the Ass. (1–5). Moreover, if we add assumption on normality of errors, inference is the same Ass. 6: Normality The errors ut are independent of X and are independently and identically distributed as N (0, σ 2 ). Ass. (6) implies Ass. (3–5), but is stronger → independence and normality. Theorem 5: Normal Sampling Distribution Under the Ass. (1–6), the CLM assumptions for time series, the OLS estimators are normally distributed, conditional on X. Further, under the null hypothesis, each t statistic has a t distribution, and each F statistic has an F distribution.

15 / 23

Inference Under the Classical Linear Model (CLM) Assumptions ⇒ everything we have learned about estimation and inference for cross-sectional regressions applies directly to time series regressions. BUT this also applies to the problems Inference is only as good as the underlying assumptions ! !!! REMEMBER !!! CLM assumptions for time series data are much more restrictive than those for the cross-sectional data. In particular strict exogeneity and no serial correlation. → unrealistic in social sciences for lot of data sets. 16 / 23

Functional Form, Dummy Variables

Basically all functional forms we have learned about in earlier chapters can be used in time series regressions i.e. log transform of distributed finite lag model: impact propensity becomes short-run elasticity long-run propensity becomes long-run elasticity

The same applies to usage of dummy variables.

17 / 23

Trends in Time Series

Economic time series often trend. But if the 2 series are trending, we can not say that the relation is casual. Today - just to have a notion of the trending. MSc. - advanced concepts of i.e. cointegration will be introduced so you will be able to deal with trends (i.e. Applied Econometrics) (Ex.1): Interactive Example in Mathematica. (NOTE: To make this link work, you need to have Lecture2.cdf at the same directory and Free CDF player installed on your computer.)

18 / 23

Trends in Time Series cont. We can control for trend by several simple ways. Series {yt } can be written as: 1) Linear trend: 2) Exponential trend: 3) Quadratic trend:

yt log(yt ) yt

= = =

α0 + α1 t + t α0 + α1 t + t α0 + α1 t + α2 t2 + t

with i.i.d. {t } and E(t ) = 0 and var(t ) = σ2 . Example: Linear Trend We can think of a sequence with linear trend as: E(yt ) = α0 + α1 t, while change of yt , E(∆yt ) = E(yt − yt−1 ) = α1 . For α1 > 0, we have growing trend. For α1 < 0, we have downward trend. 19 / 23

Trends in Time Series cont. Trending variables does not necessarily result in violating CLM assumptions. The biggest problem is phenomenon of the spurious regression. Spurious Regression Trending factors that affect yt are correlated with explanatory variable. We find relationship between two or more trending variables simply because each is growing over time. How to eliminate this problem? Add time trend! (Ex.2): Interactive Example in Mathematica. (NOTE: To make this link work, you need to have Lecture2.cdf at the same directory and Free CDF player installed on your computer.)

20 / 23

Detrending

Adding a linear trend term to a regression is the same as using “detrended” series in a regression. Detrending involves regressing each variable in the model on t. Basically, the trend has been partially led out.

21 / 23

Detrending cont.

Big advantage is that detrending the data involves the calculation of goodness of fit. Time-series regressions with trending variables will have very large R2 as the trend is very well explained. But the R2 from a regression on detrended data will tell us how well the xt ’s explain yt . (Ex.3): Interactive Example in Mathematica. (NOTE: To make this link work, you need to have Lecture2.cdf at the same directory and Free CDF player installed on your computer.)

22 / 23

Seasonality Data observed at monthly or quarterly interval may exhibit seasonality, or periodicity. Example: Quarterly data on retail sales will tend to jump up in the 4th quarter. Seasonality can be dealt with by adding a set of seasonal dummies. As with trends, the series can be seasonally adjusted before running the regression. (Ex.4): Interactive Example in Mathematica. (NOTE: To make this link work, you need to have Lecture2.cdf at the same directory and Free CDF player installed on your computer.)

Thank you for your attention! ... and do not forget to read Chapter 11 for the next week! 23 / 23