ADVANCED ECONOMETRICS Ihome.iscte-iul.pt/~jjsro/advecoi/Slides-Theory-1.pdf · 2020. 10. 21. ·...

88
Theory (1/3) ADVANCED ECONOMETRICS I Instructor: Joaquim J. S. Ramalho E.mail: [email protected] Personal Website: http://home.iscte-iul.pt/~jjsro Office: D5.10 Course Website: https://jjsramalho.wixsite.com/advecoi Fénix: https://fenix.iscte-iul.pt/disciplinas/03089

Transcript of ADVANCED ECONOMETRICS Ihome.iscte-iul.pt/~jjsro/advecoi/Slides-Theory-1.pdf · 2020. 10. 21. ·...

  • Theory (1/3)

    ADVANCED ECONOMETRICS I

    Instructor: Joaquim J. S. Ramalho

    E.mail: [email protected]

    Personal Website: http://home.iscte-iul.pt/~jjsro

    Office: D5.10

    Course Website: https://jjsramalho.wixsite.com/advecoi

    Fénix: https://fenix.iscte-iul.pt/disciplinas/03089

    mailto:[email protected]://home.iscte-iul.pt/~jjsrohttps://jjsramalho.wixsite.com/advecoihttps://fenix.iscte-iul.pt/disciplinas/03089

  • Joaquim J.S. Ramalho

    This course provides an introduction to the modern econometric techniques used in the analysis of cross-sectionaland panel data in the area of microeconometrics:▪ The interaction between theory and empirical econometric analysis is

    emphasized

    ▪ Students will be trained in formulating and testing economic models using real data

    Pre-requisites (recommended):▪ Introductory Econometrics

    Grading:▪ Two problem sets (50%) + Final (open book) exam (50%)

    – Weighted mean of at least 9,5/20

    – Minimum grade at the exam of 7,5/20

    ▪ No re-sit examinations

    Course Description

    2Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    i. Introduction

    1. Linear Regression Analysis

    2. Nonlinear Regression Analysis

    3. Discrete Choice Models

    4. Models for Continuous Limited Dependent Variable Models

    Contents - Theory

    3Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Recommended:▪ Cameron, A. and P.K. Trivedi (2005), Microeconometrics: Methods and

    Applications, Cambridge University Press

    Others:▪ Baltagi, B. (2013), Econometric Analysis of Panel Data, John Wiley and

    Sons (5th Edition)

    ▪ Davidson, R. and J.G. MacKinnon (2003), Econometric Theory andMethods, Oxford University Press

    ▪ Greene, W. (2011), Econometric Analysis, Pearson (7th Edition)

    ▪ Verbeek, M. (2017), A Guide to Modern Econometrics, Wiley (5th Edition)

    ▪ Wooldridge, J.M. (2010), Econometric Analysis of Cross Section andPanel Data, MIT Press (2nd Edition)

    ▪ Wooldridge, J.M. (2015), Introductory Econometrics: A ModernApproach, South Western (6th Edition).

    Textbooks

    4Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    1. Determinants of Firm Debt

    2. Estimating the Returns to Schooling

    3. Explaining Individual Wages

    4. Explaining Capital Structure

    5. Modelling the Choice Between Two Brands

    6. Health Care Expenses and Consultations

    7. Explaining Firm’s Credit Ratings

    8. Travel Mode Choice

    9. Health Care Expenses and Consultations (revisited)

    10. Determinants of Firm Debt (revisited)

    Contents - Illustrations

    5Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Recommended:▪ Stata: http://www.stata.com

    ▪ R: https://cran.r-project.org

    Others:▪ Gauss: http://www.aptech.com/products/gauss-mathematical-and-

    statistical-system

    ▪ Matlab: https://www.mathworks.com/products/matlab

    Software

    6Advanced Econometrics I2020/2021

    http://www.stata.com/https://cran.r-project.org/http://www.aptech.com/products/gauss-mathematical-and-statistical-systemhttps://www.mathworks.com/products/matlab

  • Joaquim J.S. Ramalho

    i.1. Econometric Methodology

    i.2. The Structure of Economic and Financial Data

    i.3. Dependent Variables and Econometric Models

    i.4. Types of Explanatory Variables

    i. Introduction

    7Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Econometrics:

    Definition:▪ Application of statistical techniques to the analysis of economic,

    financial, social... data aiming at estimating relationships between a dependent variable and a set of explanatory variables

    Ultimate purpose:▪ Theory validation

    ▪ Prediction / Forecasting

    ▪ Policy recommendation

    i. Introductioni.1. Econometric Methodology

    8Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    i. Introductioni.1. Econometric Methodology

    Model specification

    Data collection

    Model estimation

    Model evaluation

    Suitable modelUnsuitable model

    Result interpretation

    Theory validationPolicy

    recommendationPrediction / Forecasting

    9Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Cross-sectional data:

    N cross-sectional units (individuals / firms / cities / ...)

    1 time observation per unit

    Time series:

    1 unit

    T time observations per unit

    Panel data

    N units

    T time observations per unit

    i. Introductioni.2. The Structure of Economic and Financial Data

    10Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Main types of econometric models:

    Regression Model: ▪ Aim: explaining 𝐸 𝑌|𝑋

    Probabilistic model:▪ Aim: explaining 𝑃𝑟 𝑌|𝑋

    ▪ Usually incorporates also a regression model for 𝐸 𝑌|𝑋

    Each type of econometric model has many variants

    i. Introductioni.3. Dependent Variables and Econometric Models

    11Advanced Econometrics I2020/2021

    𝑌: dependent variable

    𝑋: explanatory variables

    𝐸 𝑌|𝑋 : expected value for 𝑌 given 𝑋

    𝑃𝑟 𝑌|𝑋 : probability of 𝑌 being equal to a specific value given 𝑋

  • Joaquim J.S. Ramalho

    i. Introductioni.3. Dependent Variables and Econometric Models

    𝑌 Type of outcome Main model

    ] − ∞, +∞[ Unbounded data Linear

    [0, +∞[ Nonnegative data Exponential

    [0,1] Fractional data Fractional Logit,...

    {0,1} Binary choices Logit,...

    {0,1,2, … , 𝐽 − 1} Multinomial choices Multinomial logit,…

    {0,1,2, … , 𝐽 − 1} Ordered choices Ordered logit,…

    {0,1,2, … } Count data Poisson,…

    The numeric characteristics of the dependent variablerestricts the variants that may be applied in each case:

    12Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Model Transformations and Adaptations:

    Bounded continuous outcomes may often be transformed in such a way that they give rise to unbounded outcomes whichmay be modelled using a linear model

    Any econometric model may require adaptations: ▪ Data structure: cross-section, time series, panel

    ▪ Non-random samples: stratified, censored, truncated

    ▪ Measurement error

    ▪ Endogenous explanatory variables

    ▪ Corner solutions

    i. Introductioni.3. Dependent Variables and Econometric Models

    13Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Explanatory variables:Their characteristics are not relevant for the choice ofeconometric model, but affect the interpretation of the results

    Quantitative variables (examples):▪ Levels (Euro, kilograms, meters,…)

    ▪ Levels and squares

    ▪ Logs

    ▪ Growth rates

    ▪ Per capita values

    Qualitative variables▪ Binary (dummy) variables:

    𝑋 = 0,1

    ▪ Interaction variables:𝑋 = 𝐷𝑢𝑚𝑚𝑦 𝑣𝑎𝑟. ∗ 𝑄𝑢𝑎𝑛𝑡𝑖𝑡𝑎𝑡𝑖𝑣𝑒 𝑜𝑟 𝑑𝑢𝑚𝑚𝑦 𝑣𝑎𝑟.

    i. Introductioni.4. Quantitative and Qualitative Explanatory Variables

    14Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    1.1. The Linear Regression Model with Cross-Sectional Data

    1.1.1. Exogenous Explanatory Variables

    Specification

    Estimation

    Interpretation

    Inference

    Model Evaluation

    RESET Test

    Tests for Heteroskedascity

    Chow Test

    1. Linear Regression Analysis1.1. The Linear Regression Model with Cross-Sectional Data

    15Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Model Specification:

    𝑌𝑖 = 𝛽0 + 𝛽1𝑋𝑖1 + ⋯ + 𝛽𝑘𝑋𝑖𝑘 + 𝑢𝑖 𝑖 = 1, ⋯ , 𝑁or

    𝑦 = 𝑋𝛽 + 𝑢

    𝑦 =

    𝑌1𝑌2⋮

    𝑌𝑁

    𝑋 =

    1 𝑋11 𝑋12 ⋯ 𝑋1𝑘1 𝑋21 𝑋22 ⋯ 𝑋2𝑘⋮ ⋮ ⋮ ⋱ ⋮1 𝑋𝑁1 𝑋𝑁2 ⋯ 𝑋𝑁𝑘

    𝛽 =

    𝛽0𝛽1⋮

    𝛽𝑘

    𝑢 =

    𝑢1𝑢2⋮

    𝑢𝑁

    1.1.1. Exogenous Explanatory VariablesSpecification

    16Advanced Econometrics I2020/2021

    𝑢: error term

    𝛽: parameters

    𝑘: n. explanatory variables

    𝑝: n. parameters (= 𝑘 + 1)

    𝑁: n. observations

  • Joaquim J.S. Ramalho

    Model estimation:

    𝛽 is unknown and needs to be estimated

    Most popular estimation method - Ordinary Least Squares(OLS)

    min

    𝑖=1

    𝑁

    ො𝑢𝑖2 , ො𝑢𝑖 = 𝑌𝑖 − 𝑌𝑖 , 𝑌𝑖 = መ𝛽0 + መ𝛽1𝑋𝑖1 + ⋯ + መ𝛽𝑘𝑋𝑖𝑘

    or

    min ො𝑢′ ො𝑢 , ො𝑢 = 𝑦 − ො𝑦, ො𝑦 = 𝑋 መ𝛽

    1.1.1. Exogenous Explanatory VariablesEstimation

    17Advanced Econometrics I2020/2021

    ො𝑢: residuals

    𝑌: fitted values of 𝑌

    𝛽: estimator for 𝛽

  • Joaquim J.S. Ramalho

    OLS estimators:

    𝜕ෝ𝑢′ ෝ𝑢

    𝜕𝛽= −2𝑋′ 𝑦 − 𝑋′ መ𝛽 = 0 (Note: implies 𝑋′ ො𝑢 = 0)

    𝑋′𝑦 = 𝑋′𝑋 መ𝛽

    መ𝛽 = 𝑋′𝑋 −1𝑋′𝑦

    1.1.1. Exogenous Explanatory VariablesEstimation

    Stataregress Y 𝑋1 ⋯ 𝑋𝑘

    18Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Model assumptions:

    1. Linearity in parameters

    2. Random sampling

    3. 𝑬 𝒖|𝑿 = 𝟎

    4. No perfect colinearity

    5. Homoskedasticity: 𝑉𝑎𝑟 𝑢|𝑋 = 𝜎2𝐼

    6. Normality: 𝑢~𝒩 0, 𝜎2𝐼

    1.1.1. Exogenous Explanatory VariablesEstimation

    19Advanced Econometrics I2020/2021

    𝜎2: error variance

  • Joaquim J.S. Ramalho

    Estimator properties:

    Finite samples:▪ Assumptions 1-4: Unbiasedness

    ▪ Assumptions 1-5: Unbiasedness and efficiency

    ▪ Assumptions 1-6: Unbiasedness, efficiency and normality

    Asymptotically:▪ Assumptions 1-4: Consistency

    ▪ Assumptions 1-5: Consistency, efficiency and normality

    1.1.1. Exogenous Explanatory VariablesEstimation

    20Advanced Econometrics I2020/2021

    Unbiasedness: 𝐸 𝛽 = 𝛽

    Efficiency: in the group of linear unbiased estimators, OLS displays

    the smallest variance [𝜎𝛽2 or 𝑉𝑎𝑟 𝛽 ]

    Normality: 𝛽 ∼ 𝒩 𝛽, 𝜎𝛽2

    Consistency: lim𝑁→∞

    𝐸 𝛽 = 𝛽

  • Joaquim J.S. Ramalho

    Goodness-of-fit:

    Sums of squares – measures of the sample variations in 𝑦, ො𝑦 and ො𝑢:

    ▪ Total Sum of Squares: 𝑆𝑆𝑇 = σ𝑖=1𝑁 𝑌𝑖 − ത𝑌

    2

    ▪ Explained Sum of Squares: 𝑆𝑆𝐸 = σ𝑖=1𝑁 𝑌𝑖 −

    ത𝑌2

    ▪ Residual Sum of Squares: 𝑆𝑆𝑅 = σ𝑖=1𝑁 ො𝑢𝑖

    2

    The total variation in 𝑦 can be expressed as the sum of theexplained and unexplained variation:

    𝑆𝑆𝑇 = 𝑆𝑆𝐸 + 𝑆𝑆𝑅

    Coefficient of determination (𝑅2):▪ Proportion of the variation of the dependent variable that is explained by

    the explanatory variables:

    𝑅2 =𝑆𝑆𝐸

    𝑆𝑆𝑇= 𝑟𝑦, ො𝑦

    2

    1.1.1. Exogenous Explanatory VariablesEstimation

    21Advanced Econometrics I2020/2021

    𝑟: coefficient of correlation

  • Joaquim J.S. Ramalho

    Effects from unitary changes in a given explanatoryvariable:

    ∆𝑋𝑗= 1 ⇒ ∆𝑌 = 𝛽𝑗Needs adaptation for:▪ Transformed dependent variables

    ▪ Transformed quantitative explanatory variables

    ▪ Qualitative explanatory variables

    Aims:▪ Most of the time: testing whether the effect is null or significantly

    different from zero → it is equivalent to test whether a parameter or a set of a parameters or a linear combination of parameters are significantly different from zero

    ▪ Most of the time: analyze the sign of the effect (null, positive, negative)

    ▪ Sometimes: calculate and analyze the magnitude of the effect

    1.1.1. Exogenous Explanatory VariablesInterpretation

    22Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Partial effect for quantitative variables:

    (Ceteris paribus) effect over the dependent variable originatedby a unitary change in a given explanatory variable:

    ∆𝑋𝑖𝑗 = 1 unit ⇒ ∆𝑌𝑖 = ?

    It is approximated by differentiating the dependent variable in order to the explanatory variable:

    ▪ Model in levels - 𝑌𝑖 = ⋯ + 𝛽𝑗𝑋𝑖𝑗 + ⋯ + 𝑢𝑖:

    𝜕𝑌𝑖

    𝜕𝑋𝑖𝑗= 𝛽𝑗, which implies that ∆𝑋𝑖𝑗 = 1 unit ⇒ ∆𝑌𝑖 = 𝛽𝑗 units

    ▪ Quadratic model - 𝑌𝑖 = ⋯ + 𝛽𝑗𝑋𝑖𝑗 + 𝛽𝑚𝑋𝑖𝑗2 + ⋯ + 𝑢𝑖:

    𝜕𝑌𝑖

    𝜕𝑋𝑖𝑗= 𝛽𝑗 + 2𝛽𝑚𝑋𝑖𝑗, which implies that

    ∆𝑋𝑖𝑗 = 1 unit ⇒ ∆𝑌𝑖 = 𝛽𝑗 + 2𝛽𝑚𝑋𝑖𝑗 units

    1.1.1. Exogenous Explanatory VariablesInterpretation

    23Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    ▪ Model in logs - ln 𝑌𝑖 = ⋯ + 𝛽𝑗ln 𝑋𝑖𝑗 + ⋯ + 𝑢𝑖:

    – Re-transformed model: 𝑌𝑖 = 𝑒⋯+𝛽𝑗ln 𝑋𝑖𝑗 +⋯+𝑢𝑖

    – Derivative:

    𝜕𝑌𝑖

    𝜕𝑋𝑖𝑗=

    𝛽𝑗

    𝑋𝑖𝑗𝑒⋯+𝛽𝑗ln 𝑋𝑖𝑗 +⋯+𝑢𝑖

    ≈∆𝑌𝑖

    ∆𝑋𝑖𝑗=

    𝛽𝑗

    𝑋𝑖𝑗𝑌𝑖

    ⟺∆𝑌𝑖𝑌𝑖

    × 100 = 𝛽𝑗∆𝑋𝑖𝑗

    𝑋𝑖𝑗× 100

    ⟺ %∆𝑌𝑖 = 𝛽𝑗%∆𝑋𝑖𝑗

    – Effect:%∆𝑋𝑖𝑗 = 1% ⇒ %∆𝑌𝑖 = 𝛽𝑗%

    » 𝛽𝑗 represents an elasticity

    1.1.1. Exogenous Explanatory VariablesInterpretation

    24Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    ▪ Log-linear model - ln 𝑌𝑖 = ⋯ + 𝛽𝑗𝑋𝑖𝑗 + ⋯ + 𝑢𝑖:

    – Re-transformed model: 𝑌𝑖 = 𝑒⋯+𝛽𝑗𝑋𝑖𝑗+⋯+𝑢𝑖

    – Derivative:𝜕𝑌𝑖

    𝜕𝑋𝑖𝑗= 𝛽𝑗𝑒

    ⋯+𝛽𝑗𝑋𝑖𝑗+⋯+𝑢𝑖

    ≈∆𝑌𝑖

    ∆𝑋𝑖𝑗= 𝛽𝑗𝑌𝑖

    ⟺∆𝑌𝑖𝑌𝑖

    × 100 = 100 × 𝛽𝑗∆𝑋𝑖𝑗

    ⟺ %∆𝑌𝑖 = 100𝛽𝑗∆𝑋𝑖𝑗

    – Effect:∆𝑋𝑖𝑗 = 1 unit ⇒ %∆𝑌𝑖 = 100𝛽𝑗%

    1.1.1. Exogenous Explanatory VariablesInterpretation

    25Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    ▪ Semi-logarithmic model - 𝑌𝑖 = ⋯ + 𝛽𝑗ln 𝑋𝑖𝑗 + ⋯ + 𝑢𝑖:

    – Derivative:𝜕𝑌𝑖

    𝜕𝑋𝑖𝑗=

    𝛽𝑗

    𝑋𝑖𝑗

    ≈ ∆𝑌𝑖 × 100 = 𝛽𝑗∆𝑋𝑖𝑗

    𝑋𝑖𝑗× 100

    ⟺ ∆𝑌𝑖 =𝛽𝑗

    100%∆𝑋𝑖𝑗

    – Effect:

    %∆𝑋𝑖𝑗 = 1% ⇒ ∆𝑌𝑖 =𝛽𝑗

    100units

    1.1.1. Exogenous Explanatory VariablesInterpretation

    26Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Partial effect for dummy variables:

    (Ceteris paribus) difference on the value of the dependentvariable between two groups

    The effect is given by the parameter associated to the dummyvariable:

    ▪ Definition of a dummy variable:

    𝐷𝑖 = ቊ1 if the individual belongs to group 𝐺𝐴0 if the individual belongs to group 𝐺𝐵

    ▪ Example:

    – Base model: 𝑌𝑖 = 𝛽0 + 𝛽1𝑋𝑖1 + ⋯ + 𝛽𝑘𝑋𝑖𝑘 + 𝛽𝑑𝐷𝑖 + 𝑢𝑖– If 𝐷𝑖 = 1, then 𝑌𝑖 = 𝛽0 + 𝛽1𝑋𝑖1 + ⋯ + 𝛽𝑘𝑋𝑖𝑘 + 𝛽𝑑 + 𝑢𝑖– If 𝐷𝑖 = 0, then 𝑌𝑖 = 𝛽0 + 𝛽1𝑋𝑖1 + ⋯ + 𝛽𝑘𝑋𝑖𝑘 + 𝑢𝑖– Difference (effect of belonging to group 𝐺𝐴): 𝛽𝑑

    1.1.1. Exogenous Explanatory VariablesInterpretation

    27Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Partial effect for interaction variables:

    (Ceteris paribus) difference between two groups on the effectover the value of the dependent variable of a unitary change in a given explanatory variable

    The effect is given by the parameter associated to theinteraction variable:

    ▪ Example:

    – Base model: 𝑌𝑖 = 𝛽0 + 𝛽1𝑋𝑖1 + ⋯ + 𝛽𝑘𝑋𝑖𝑘 + 𝛽𝑚𝑋𝑖𝑚 + 𝛽𝑑𝑚 𝐷𝑖 ∗ 𝑋𝑖𝑚 + 𝑢𝑖– If 𝐷𝑖 = 1, then 𝑌𝑖 = 𝛽0 + 𝛽1𝑋𝑖1 + ⋯ + 𝛽𝑘𝑋𝑖𝑘 + 𝛽𝑚 + 𝛽𝑑𝑚 𝑋𝑖𝑚 + 𝑢𝑖– If 𝐷𝑖 = 0, then 𝑌𝑖 = 𝛽0 + 𝛽1𝑋𝑖1 + ⋯ + 𝛽𝑘𝑋𝑖𝑘 + 𝛽𝑚𝑋𝑖𝑚 + 𝑢𝑖– Partial effect of 𝑋𝑖𝑚 for those in group 𝐺𝐴: 𝛽𝑚 + 𝛽𝑑𝑚– Partial effect of 𝑋𝑖𝑚 for those in group 𝐺𝐵: 𝛽𝑚– Difference: 𝛽𝑑𝑚

    1.1.1. Exogenous Explanatory VariablesInterpretation

    28Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Estimators for the variance of the parameter estimators:

    Standard – assumes homoskedasticity: 𝑉𝑎𝑟 መ𝛽 = ො𝜎2 𝑋′𝑋 −1

    Robust – allows for heteroskedasticity:

    𝑉𝑎𝑟 መ𝛽 = 𝑋′𝑋 −1𝑋′ Φ𝑋 𝑋′𝑋 −1, Φ =

    ො𝑢12 0 ⋯ 0

    0 ො𝑢22 0

    ⋮ ⋱ ⋮0 0 ⋯ ො𝑢𝑁

    2

    Cluster-robust – specific for panel data

    Bootstrap – simulated variance

    1.1.1. Exogenous Explanatory VariablesInference

    Stataregress Y 𝑋1 … 𝑋𝑘regress Y 𝑋1 … 𝑋𝑘 , vce(robust)regress Y 𝑋1 … 𝑋𝑘 , vce(cluster clustvar)regress Y 𝑋1 … 𝑋𝑘 , vce(bootstrap)

    29Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Hypothesis tests:

    Require specification of the:

    ▪ Null and alternative hypothesis; typically:

    – 𝐻0: Partial effect = 0

    – 𝐻1:Partial effect ≠ 0 (> 0 or < 0 also possible)

    ▪ Significance level (𝛼):

    – Probability of rejecting the null hypothesis when it is true

    – Typically, 𝛼 = 0.01, 0.05 or 0.10

    p-value:

    ▪ The p-value of the result of a test is the probability of obtaining a value at least as extreme when the null hypothesis is true; therefore:

    – 𝑝 < 𝛼 ⟹ Reject 𝐻0

    – 𝑝 > 𝛼 ⟹ Do not reject 𝐻0

    1.1.1. Exogenous Explanatory VariablesInference

    30Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Main tests:

    ▪ Test for the individual significance of a parameter: t test

    ▪ Test for the joint significance of a set of parameters: F test

    t test:𝐻0: 𝛽𝑗 = 0

    𝐻1: 𝛽𝑗 ≠ 0

    𝑡 =መ𝛽𝑗

    ො𝜎𝛽𝑗~𝑡𝑁−𝑝

    Τ𝛼 2

    𝑡 < 𝑡𝑁−𝑝Τ𝛼 2 ⟹ Do not reject 𝐻0

    𝑡 > 𝑡𝑁−𝑝Τ𝛼 2 ⟹ Reject 𝐻0

    1.1.1. Exogenous Explanatory VariablesInference

    Stataregress Y 𝑋1 … 𝑋𝑘regress Y 𝑋1 … 𝑋𝑘 , vce(robust)regress Y 𝑋1 … 𝑋𝑘 , vce(cluster clustvar)regress Y 𝑋1 … 𝑋𝑘 , vce(bootstrap)

    31Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    F test:

    Model:𝑌 = 𝛽0 + 𝛽1𝑋1 + ⋯ +𝛽𝑔 𝑋𝑔 +𝛽𝑔+1 𝑋𝑔+1 + ⋯ + 𝛽𝑘𝑋𝑘 + 𝑣

    Hypotheses:𝐻0: 𝛽𝑔+1 = ⋯ = 𝛽𝑘 = 0

    𝐻1: No 𝐻0Test:

    𝐹 =𝑅2−𝑅∗

    2

    1−𝑅2𝑁−𝑝

    𝑞~𝐹𝑁−𝑝

    𝑞→ valid only under homoskedasticity

    𝐹 = 𝑁 መ𝛽∗′ Var መ𝛽∗

    −1 መ𝛽∗~𝜒𝑞2 → general formula

    ▪ Decision:𝐹 < 𝐹𝑁−𝑝

    𝑞⟹ Do not reject 𝐻0

    𝐹 > 𝐹𝑁−𝑝𝑞

    ⟹ Reject 𝐻0

    1.1.1. Exogenous Explanatory VariablesInference

    Stataregress Y 𝑋1 ⋯ 𝑋𝑔 𝑋𝑔+1 ⋯ 𝑋𝑘 ,…test 𝑋𝑔+1 ⋯ 𝑋𝑘

    32Advanced Econometrics I2020/2021

    𝑅2: coefficient of determination of the full model

    𝑅∗2: coefficient of determination of the restricted model

    𝑞: n. of parameters to be tested

  • Joaquim J.S. Ramalho

    Specification tests:

    Model functional form: RESET test

    Heteroskedasticity: Breusch-Pagan (BP) test

    Structural breaks: Chow tests

    1.1.1. Exogenous Explanatory VariablesModel Evaluation

    33Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    RESET test:

    Intuition:▪ Any model of the type 𝐸 𝑌|𝑋 = 𝑆 𝑋𝛽 may be approximated by

    𝐸 𝑌|𝑋 = 𝐿 𝑋𝛽 + σ𝑗=1∞ γj 𝑋 መ𝛽

    𝑗+1

    ▪ Assume a linear form for 𝐿 ∙ and check if γj = 0

    Implementation:

    ▪ Estimate the original model and get መ𝛽

    ▪ Generate the variables 𝑋 መ𝛽2

    , 𝑋 መ𝛽3

    , 𝑋 መ𝛽4

    , …

    ▪ Add the generated variables to the original model and estimate thefollowing auxiliary model:

    𝑌 = 𝛽0 + 𝛽1𝑋1 + ⋯ + 𝛽𝑘𝑋𝑘 + γ1 𝑋 መ𝛽2

    + γ2 𝑋 መ𝛽3

    + γ3 𝑋 መ𝛽4

    + ⋯ + 𝑣

    ▪ Apply an F test for the significance of the added variables:

    𝐻0: γ1 = γ2 = γ3 = ⋯ = 0 (suitable model functional form)

    𝐻1: No 𝐻0 (unsuitable model functional form)

    1.1.1. Exogenous Explanatory VariablesModel Selection - RESET Test

    Stata(only test version based on three fitted powers)

    regress Y 𝑋1 … 𝑋𝑘estat ovtest

    34Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    BP Test:

    Intuition:▪ Because the mean of the error term is zero, the variance of the error

    term is given by the sum of the squared error terms

    ▪ The squared residuals are an estimate of the squared error terms

    ▪ Check if the squared residuals and the explanatory variables are correlated

    Implementation:▪ Estimate the original model and generate the variable ො𝑢2

    ▪ Replace 𝑌 by ො𝑢2 in the original model and estimate the followingauxiliary model:

    ො𝑢2 = γ0 + γ1𝑋1 + ⋯ + γ𝑘𝑋𝑘 + 𝑣

    ▪ Apply an F test for the joint significance of the right-hand side variablesof the previous auxiliary model:

    𝐻0: γ1 = ⋯ = γ𝑘 = 0 (homoskedasticity)

    𝐻1: Não 𝐻0 (heteroskedasticity)

    1.1.1. Exogenous Explanatory Variables Model Selection - Tests for Heteroskedascity

    Stataregress Y 𝑋1 … 𝑋𝑘estat hettest, rhs fstat

    35Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Chow Test for Structural Breaks:

    Context:▪ Two groups of individuals / firms / ...: 𝐺𝐴, 𝐺𝐵▪ It is suspected that the behaviour of the two groups in which regards the

    dependent variable may have different determinants

    Implementation:

    ▪ Generate the dummy variable 𝐷 = ቊ1 if the individual belongs to 𝐺𝐴0 if the individual belongs to 𝐺𝐵

    ▪ Estimate the original model ‘duplicated’:𝑌 = 𝜃0 + 𝜃1𝑋1 + ⋯ + 𝜃𝑘𝑋𝑘 + γ0𝐷 + γ1𝐷𝑋1 + ⋯ + γ𝑘𝐷𝑋𝑘 + 𝑣

    ▪ Apply an F test for the significance of the terms where 𝐷 is present:

    𝐻0: γ0 = ⋯ = γ𝑘 = 0 (no structural break)

    𝐻1: Não 𝐻0 (with a structural break)

    1.1.1. Exogenous Explanatory VariablesModel Selection - Chow Test

    Stataregress Y 𝑋1…𝑋𝑘 𝐷 𝐷𝑋1…𝐷𝑋𝑘test 𝐷 𝐷𝑋1 … 𝐷𝑋𝑘

    36Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Endogeneity

    Definition and Consequences

    Motivation: Omitted variables, Measurement Errors, Simultaneous Equations

    Solutions: Instrumental Variables, Panel Data

    Methods based on Instrumental Variables

    Two-Stage Least Squares

    Generalized Method of Moments (GMM)

    Specification Tests

    Test for the Exogeneity of an Explanatory Variable

    Test for the Exogeneity of the Instrumental Variables

    Tests for Correlation between Instrumental Variables and Explanatory

    Variables

    1.1.2. Endogenous Explanatory Variables

    37Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Definitions:

    Exogenous explanatory variables: 𝐸 𝑢|𝑋 = 0 → essentialassumption in any regression model

    Endogenous explanatory variables: 𝐸 𝑢|𝑋 ≠ 0

    Consequences:

    OLS estimators become unbiased and inconsistent

    Motivation:

    Omitted variables

    Covariate measurement error

    Simultaneity

    1.1.2. Endogenous Explanatory VariablesEndogeneity: Definition and Consequences

    38Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Omitted variables - example:

    True model: 𝑌 = 𝛽0 + 𝛽1𝑋1 + 𝛽2𝑋2 + 𝑣, 𝐸 𝑣|𝑋1, 𝑋2 = 0

    Estimated model: 𝑌 = 𝛽0 + 𝛽1𝑋1 + 𝑢

    As 𝑢 = 𝛽2𝑋2 + 𝑣:▪ If 𝑐𝑜𝑣 𝑋1, 𝑋2 = 0, then 𝐸 𝑢 𝑋1 = 0 → 𝑋1 is exogenous

    ▪ If 𝑐𝑜𝑣 𝑋1, 𝑋2 ≠ 0, then 𝐸 𝑢 𝑋1 ≠ 0 → 𝑋1 is endogenous

    1.1.2. Endogenous Explanatory VariablesEndogeneity: Motivation

    39Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Covariate measurement error - example:

    True model: 𝑌 = 𝛽0 + 𝛽1𝑋1∗ + 𝑣, 𝐸 𝑣|𝑋1

    ∗ = 0

    𝑒: measurement error

    Instead of 𝑋1∗, it is observed 𝑋1= 𝑋1

    ∗ + 𝑒

    Estimated model: 𝑌 = 𝛽0 + 𝛽1𝑋1 + 𝑢

    As 𝑢 = 𝑣 − 𝛽1𝑒:▪ If 𝑐𝑜𝑣 𝑋1, 𝑒 = 0, then 𝐸 𝑢 𝑋1 = 0 → 𝑋1 is exogenous

    ▪ If 𝑐𝑜𝑣 𝑋1, 𝑒 ≠ 0, then 𝐸 𝑢 𝑋1 ≠ 0 → 𝑋1 is endogenous → mostcommon case because the measurement error is on 𝑋1

    1.1.2. Endogenous Explanatory VariablesEndogeneity: Motivation

    40Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Measurement error on 𝑌 has less serious consequences:

    True model: 𝑌∗ = 𝛽0 + 𝛽1𝑋1 + 𝑣 , 𝐸 𝑣|𝑋1 = 0

    Instead of 𝑌∗, it is observed 𝑌 = 𝑌∗ + 𝑒

    Estimated model: 𝑌 = 𝛽0 + 𝛽1𝑋1 + 𝑢

    As 𝑢 = 𝑣 + 𝑒:▪ In general, 𝑐𝑜𝑣 𝑋1, 𝑒 = 0 and 𝐸 𝑢 𝑋1 = 0, since the measurement

    error is on 𝑌 and not in 𝑋1▪ Hence, usually there are no endogeneity problems

    ▪ However, estimation is less precise, since the error term has now twocomponents

    1.1.2. Endogenous Explanatory VariablesEndogeneity: Motivation

    41Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Simultaneity - example:

    True model: ቊSupply: 𝑄 = 𝛽0 + 𝛽1𝑃 + 𝑢Demand: 𝑄 = 𝛼0 + 𝛼1𝑃 + 𝑣

    Estimated model: ቊSupply: 𝑄 = 𝛽0 + 𝛽1𝑃 + 𝑢Demand: 𝑄 = 𝛼0 + 𝛼1𝑃 + 𝑣

    As:

    ൞𝑃 =

    𝛼0 − 𝛽0𝛽1 − 𝛼1

    +𝑣 − 𝑢

    𝛽1 − 𝛼1𝑄 = ⋯

    then 𝑃 is function of 𝑣 and 𝑢; hence:▪ 𝐸 𝑢 𝑃 ≠ 0 in the supply equation → 𝑃 is endogenous

    ▪ 𝐸 𝑣 𝑃 ≠ 0 in the demand equation → 𝑃 is endogenous

    1.1.2. Endogenous Explanatory VariablesEndogeneity: Motivation

    42Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    What to do in case of endogeneity:

    Universal solution – methods based on ‘instrumental variables’:▪ Two-Stage Least Squares

    ▪ Generalized Method of Moments (GMM)

    When data is in panel form and the endogeneity problem iscaused by omitted time-constant variables:▪ Methods based on the removal of the ‘fixed effects’

    1.1.2. Endogenous Explanatory VariablesEndogeneity: Instrumental Variables

    43Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Instrumental variables:

    Context:▪ 𝑌 = 𝛽0 + 𝛽1𝑋1 + 𝛽2𝑋2 + ⋯ + 𝛽𝑘𝑋𝑘 + 𝑢 (structural model)

    ▪ 𝐸 𝑢 𝑋1 ≠ 0 → 𝑋1 is endogenous

    Definitions of instrumental variable (𝐼𝑉𝐴, … , 𝐼𝑉𝑀):▪ 𝐸 𝑢 𝐼𝑉𝐴 = ⋯ = 𝐸 𝑢 𝐼𝑉𝑀 = 0

    ▪ 𝑐𝑜𝑣 𝐼𝑉𝐴, 𝑋1 ≠ 0, …,𝑐𝑜𝑣 𝐼𝑉𝑀, 𝑋1 ≠ 0

    Exogenous variables: 𝑍 = 1 𝑋2 ⋯ 𝑋𝑘 𝐼𝑉𝐴 ⋯ 𝐼𝑉𝑀

    The number of instrumental variables must be equal or largerthan the number of endogenous explanatory variables

    1.1.2. Endogenous Explanatory VariablesEndogeneity: Instrumental Variables

    44Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Implementation:1. Estimate the reduced form of the model by OLS:

    ด𝑋1End. Expl. Var.

    = 𝜋0 + 𝜋2𝑋2 + ⋯ + 𝜋𝑘𝑋𝑘Ex. Expl. Var.

    + 𝜋𝐴𝐼𝑉𝐴 + ⋯ + 𝜋𝑀𝐼𝑉𝑀Instrumental Variables

    + 𝑤

    and get 𝑋1 = ො𝜋0 + ො𝜋2𝑋2 + ⋯ + ො𝜋𝑘𝑋𝑘 + ො𝜋𝐴𝐼𝑉𝐴 + ⋯ + ො𝜋𝑀𝐼𝑉𝑀

    2. Estimate the structural model, with 𝑋1 replaced by 𝑋1, byOLS:

    𝑌 = 𝛽0 + 𝛽1 𝑋1 + 𝛽2𝑋2 + ⋯ + 𝛽𝑘𝑋𝑘 + 𝑢

    1.1.2. Endogenous Explanatory VariablesMethods based on Instrumental Variables: Two-Stage Least Squares (2SLS)

    45Advanced Econometrics I2020/2021

    Stata(by default, variances are estimated in a standard way; to use another estimator, use

    the option vce(robust) or similar)

    ivregress 2sls Y (𝑋1= 𝐼𝑉𝐴… 𝐼𝑉𝑀) 𝑋2 … 𝑋𝑘

  • Joaquim J.S. Ramalho

    Very general estimation method:▪ Applies to a large variety of cases

    ▪ Includes as particular cases OLS, maximum likelihood, etc.

    Formulation:▪ Moment conditions: 𝐸 𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽 = 0

    ▪ 𝑚 moment conditions

    ▪ 𝑝 parameters: 𝛽0, 𝛽1, ⋯ , 𝛽𝑘▪ Optimization:

    – 𝑚 = 𝑝 → just-identified model: 𝑔 𝑌, 𝑋, 𝐼𝑉; መ𝛽 = 0

    – 𝑚 > 𝑝 → overidentified model:min 𝐽 = 𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽 ′W𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽

    where W is a weighting matrix; the first-order conditions are given by:𝜕𝑔 𝑌, 𝑋, 𝐼𝑉; መ𝛽

    𝜕𝛽W𝑔 𝑌, 𝑋, 𝐼𝑉; መ𝛽 = 0

    1.1.2. Endogenous Explanatory VariablesMethods based on Instrumental Variables: GMM

    46Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Choosing 𝑊 in overidentified models:To get efficient estimators, 𝑊 has to be defined as the inverseof the covariance matrix of the moment conditions:

    𝑊 = Ω−1,

    where:

    Ω = 𝑉𝑎𝑟 𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽 = 𝐸 𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽 𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽 ′

    1.1.2. Endogenous Explanatory VariablesMethods based on Instrumental Variables: GMM

    Stata(by default, variances are estimated in a standard way; to use another estimator, use

    the option vce(robust) or similar)

    ivregress gmm Y (𝑋1= 𝐼𝑉𝐴… 𝐼𝑉𝑀) 𝑋2 … 𝑋𝑘

    47Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Particular case – OLS:

    Assumption: 𝐸 𝑢|𝑋 = 0 ⟹ 𝐸 𝑋′𝑢 = 0

    𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽 = 𝑋′𝑢 = 𝑋′ 𝑦 − 𝑋𝛽

    𝑚 = 𝑝 ⟹ 𝑋′ 𝑦 − 𝑋 መ𝛽 = 0

    𝑋′ 𝑦 − 𝑋 መ𝛽 = 0

    𝑋′𝑦 − 𝑋′𝑋 መ𝛽 = 0

    𝑋′𝑋 መ𝛽 = 𝑋′𝑦

    መ𝛽 = 𝑋′𝑋 −1𝑋′𝑦

    1.1.2. Endogenous Explanatory VariablesMethods based on Instrumental Variables: GMM

    48Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Instrumental Variables (𝑚 = 𝑝):

    Assumption: 𝐸 𝑢|𝑍 = 0 ⟹ 𝐸 𝑍′𝑢 = 0

    Moment conditions: 𝑔 𝑌, 𝑋, 𝐼𝑉; 𝛽 = 𝑍′𝑢 = 𝑍′ 𝑦 − 𝑋𝛽

    If 𝑚 = 𝑝 ⟹ 𝑍′ 𝑦 − 𝑋 መ𝛽 = 0

    መ𝛽 = 𝑍′𝑋 −1𝑍′𝑦

    In this case, GMM is identical to 2SLS estimation

    1.1.2. Endogenous Explanatory VariablesMethods based on Instrumental Variables: GMM

    49Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Instrumental Variables (𝑚 > 𝑝):

    Optimization problem: min 𝐽 = 𝑦 − 𝑋𝛽 ′𝑍Ω−1𝑍′ 𝑦 − 𝑋𝛽

    First-order conditions:

    −𝑋′𝑍෩Ω−1𝑍′ 𝑦 − 𝑋 መ𝛽 = 0𝑋′𝑍෩Ω−1𝑍′𝑦 = 𝑋′𝑍Ω−1𝑍′𝑋 መ𝛽

    መ𝛽 = 𝑋′𝑍෩Ω−1𝑍′𝑋−1

    𝑋′𝑍Ω−1𝑍′𝑦

    where ෩Ω is a preliminar estimate of Ω = 𝐸 𝑍′𝑢𝑢′𝑍 , whichrequires a preliminar estimate for 𝛽; typically, ෨𝛽 is obtainedfrom min 𝐽 = 𝑦 − 𝑋𝛽 ′𝑍𝑍′ 𝑦 − 𝑋𝛽 (assumes 𝑊 = 𝐼)

    1.1.2. Endogenous Explanatory VariablesMethods based on Instrumental Variables: GMM

    50Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Tests relevant for 2SLS / GMM:Tests for the exogeneity of an explanatory variable▪ If the explanatory variable is exogenous, it is better to use OLS in order

    to get efficient estimators

    ▪ Methods based on IV’s should be used only if really necessary, sincethere may be a substantial loss in precision

    Tests for the exogeneity of the instrumental variables▪ To act as an IV, a variable has to be exogenous ⟶ when based on “IV’s”

    that actually are endogenous, 2SLS and GMM are inconsistent

    Tests for correlation between instrumental variables and explanatory variables▪ To act as an IV, a variable has to be correlated with the endogenous

    explanatory variable ⟶ when based on “IV’s” uncorrelated with theendogenous regressors, 2SLS and GMM are inconsistent

    ▪ If the IV’s are only weakly correlated with the endogenous regressors, then the model with be poorly identified ⟶ in such a case, 2SLS and GMM may display a huge variability

    1.1.2. Endogenous Explanatory VariablesSpecification Tests

    51Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    2SLS - Wu-Hausman test:1. Estimate the reduced model by OLS:

    𝑋1 = 𝜋0 + 𝜋2𝑋2 + ⋯ + 𝜋𝑘𝑋𝑘 + 𝜋𝐴𝐼𝑉𝐴 + ⋯ + 𝜋𝑀𝐼𝑉𝑀 + 𝑤

    2. Calculate the residuals ෝ𝑤

    3. Add ෝ𝑤 to the strutural model and re-estimate it, by OLS:𝑌 = 𝛽0 + 𝛽1𝑋1 + 𝛽2𝑋2 + ⋯ + 𝛽𝑘𝑋𝑘 + 𝛿 ෝ𝑤 + 𝑢

    4. t test:𝐻0: 𝛿 = 0 (𝑋1 is exogenous)

    𝐻1: 𝛿 ≠ 0 (𝑋1 is endogenous)

    GMM - Eichenbaum, Hansen e Singleton’s (1988) C testBased on the difference of two J statistics (see the next page)

    1.1.2. Endogenous Explanatory VariablesTests for the Exogeneity of an Explanatory Variable

    Stataivregress 2sls Y (𝑋1= 𝐼𝑉𝐴… 𝐼𝑉𝑀) 𝑋2 … 𝑋𝑘estat endogenous

    Stataivregress gmm Y (𝑋1= 𝐼𝑉𝐴… 𝐼𝑉𝑀) 𝑋2 … 𝑋𝑘estat endogenous

    52Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    These tests can be applied only when the model isoveridentified

    If the model is just-identified, then it is only possible to justifythe exogeneity of the IV’s using theoretical arguments

    Hansen’s J test (also called test for overidentifying restrictions; this is an extension of the Sargan test, very common in the2SLS framework under homoskedasticity):1. Estimate the model by GMM

    2. Test

    𝐻0: 𝐸 𝑢|𝑍 = 0 (IV’s are exogenous)

    𝐻1: 𝐸 𝑢|𝑍 ≠ 0 (IV’s are not exogenous)

    using the J statistic:መ𝐽 = 𝑔 𝑌, 𝑋, 𝐼𝑉; መ𝛽

    ′ W𝑔 𝑌, 𝑋, 𝐼𝑉; መ𝛽 ~𝜒𝑞2

    1.1.2. Endogenous Explanatory Variables Tests for the Exogeneity of the Instrumental Variables

    Stata(applies also to the 2SLS estimator, with the obvious adaptation)

    ivregress gmm Y (𝑋1= 𝐼𝑉𝐴… 𝐼𝑉𝑀) 𝑋2 … 𝑋𝑘estat overid

    q: number of overidentifyingrestrictions

    53Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Alternatives:

    F tests for the significance of the IV’s in the reduced formmodel

    Criteria / tests for ‘weak instruments’

    F tests:1. Estimate the reduced form model:

    𝑋1 = 𝜋0 + 𝜋2𝑋2 + ⋯ + 𝜋𝑘𝑋𝑘 + 𝜋𝐴𝐼𝑉𝐴 + ⋯ + 𝜋𝑀𝐼𝑉𝑀 + 𝑤

    2. Test the hypothesis:

    𝐻0: 𝜋𝐴 = ⋯ = 𝜋𝑀 = 0 (𝐼𝑉’s and 𝑋1 are not correlated)

    1.1.2. Endogenous Explanatory Variables Tests for Correlation between Instrumental Variables and Explanatory Variables

    54Advanced Econometrics I2020/2021

    Stata(applies also to the GMM estimator, with the obvious adaptation)

    ivregress 2sls Y (𝑋1= 𝐼𝑉𝐴… 𝐼𝑉𝑀) 𝑋2 … 𝑋𝑘estat firststage

  • Joaquim J.S. Ramalho

    Tests for ‘weak instruments’:

    Even when the previous tests reveal that 𝐼𝑉’s and 𝑋1 are correlated, that correlation may be so weak that 2SLS / GMM estimators are very little precise

    Criterium: 𝐹 < 10 → Suggest a high probability of having‘weak instruments’

    Tests: Cragg and Donald (2005), Kleibergen and Paap (2006)

    1.1.2. Endogenous Explanatory VariablesTests for Correlation between Instrumental Variables and Explanatory Variables

    55Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    1.2.1. Static Models

    1.2.2. Dynamic Models

    1.2. The Linear Regression Model with Panel Data

    56Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Panel data:

    𝑁 cross-sectional units: 𝑖 = 1, … , 𝑁

    𝑇 time observations per unit: 𝑡 = 1, … , 𝑇

    Econometric analysis more complex:

    Cross-sectional data: different units ⇒ independentobservations

    Panel data: same units ⇒ dependent observations over time

    1.2.1. Static ModelsDefinitions

    57Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Advantages:

    Make possible the analysis of the dynamics of individual behaviours

    Generate more efficient estimators, since samples are larger

    Allow for endogenous explanatory variables in some specialcases

    It is simple to get instrumental variables

    Limitations:

    Prediction and calculation of partial effects not possible in some models

    1.2.1. Static Models Definitions

    58Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Temporal dimension:

    Short panels:▪ Sample comprises many individuals (𝑁 ⟶ ∞), but there is a reduced

    number of time observations (small 𝑇)

    ▪ The temporal correlation of the observations for each individual is anissue, but across individuals it is assumed independence

    Long panels:

    ▪ Large number of time observations for each individual (𝑇 ⟶ ∞)

    ▪ Need to take into account time series issues (stationarity, cointegration, etc.)

    1.2.1. Static Models Definitions

    59Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Cross-sectional composition:

    Balanced panels:▪ Every individual is observed in all time periods (𝑇𝑖 = 𝑇, ∀𝑖)

    Unbalanced panels:▪ Some individuals are not observed in some time periods (𝑇𝑖 ≠ 𝑇)

    ▪ Motivation: some individuals refuse to continue providing informationafter some time periods ⟶ ‘attrition’ problem

    ▪ Most estimators work with unbalanced panels, provided that one mayassume that there is no endogenous selection (the data are missing atrandom)

    1.2.1. Static Models Definitions

    60Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Variability over time and across individuals:

    With panel data, the variance of 𝑌𝑖𝑡 can be decomposed as follows:

    𝑖=1

    𝑁

    𝑡=1

    𝑇

    𝑌𝑖𝑡 − ത𝑌2 =

    𝑖=1

    𝑁

    𝑡=1

    𝑇

    𝑌𝑖𝑡 − ത𝑌𝑖 + ത𝑌𝑖 − ത𝑌2

    =

    𝑖=1

    𝑁

    𝑡=1

    𝑇

    𝑌𝑖𝑡 − ത𝑌𝑖2 +

    𝑖=1

    𝑁

    ത𝑌𝑖 − ത𝑌2

    To obtain the the total, ‘within’ and ‘between’ variance, divide by, respectively, 𝑁𝑇 − 1, 𝑁 𝑇 − 1 and 𝑁 − 1

    1.2.1. Static Models Definitions

    Variability within thegroups

    Variability between thegroups

    61Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Base Model – Model with individual effects:

    𝑌𝑖𝑡 = 𝛼𝑖 + 𝑥𝑖𝑡′ 𝛽 + 𝑢𝑖𝑡 𝑖 = 1, … , 𝑁; 𝑡 = 1, … , 𝑇

    𝛼𝑖: individual effects, time-constant

    𝑥𝑖𝑡 - explanatory variables, including:

    ▪ 𝑥𝑖𝑡: changes across individuals and over time

    ▪ 𝑥𝑖: time-constant

    ▪ 𝑑𝑡: temporal dummy variable

    ▪ 𝑡: trend (one may also have 𝑡2, 𝑡3, …)

    ▪ 𝑑𝑡.𝑥𝑖𝑡: interaction term

    𝑢𝑖𝑡: idiosyncratic error term – changes randomly across individuals andover time

    1.2.1. Static Models Models

    62Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Other models:

    ‘Pooled’ or ‘Population-averaged’ model:𝑌𝑖𝑡 = 𝛼 + 𝑥𝑖𝑡

    ′ 𝛽 + 𝑢𝑖𝑡▪ Direct extension of cross-sectional models

    ▪ Popular in the area of Statistics but not in Economics, where individual heterogeneity is always an issue

    Random Coefficients Model:𝑌𝑖𝑡 = 𝛼𝑖 + 𝑥𝑖𝑡

    ′ 𝛽𝑖 + 𝑢𝑖𝑡▪ More complex than the base model, allowing for a different coefficient

    also for the explanatory variables

    ▪ Computationally-intensive model, hard to estimate

    1.2.1. Static Models Models

    63Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    The individual effects model may be re-written as: 𝑌𝑖𝑡 = 𝑥𝑖𝑡

    ′ 𝛽 + 𝛼𝑖 + 𝑢𝑖𝑡The error term has now two componentes, 𝛼𝑖 and 𝑢𝑖𝑡The individual effects 𝛼𝑖 may be correlated, or not, with theexplanatory variables

    Fixed effects:

    𝛼𝑖 and 𝑥𝑖𝑡 are correlated → 𝑥𝑖𝑡 is endogenous

    Direct estimation of the model is not possible

    Random effects:

    𝛼𝑖 and 𝑥𝑖𝑡 are not correlated → 𝑥𝑖𝑡 is exogenous

    Direct estimation of the model is possible

    1.2.1. Static Models Fixed Effects versus Random Effects

    64Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Most panel data estimators:

    Are based on transformed versions of the base model

    Differ of the type of exogeneity required for the explanatoryvariables:

    ▪ Contemporaneous: 𝐸 𝑥𝑖𝑡𝑢𝑖𝑡 = 0

    ▪ Weak (pre-determined variables): 𝐸 𝑥𝑖𝑡𝑢𝑖,𝑡+𝑗 = 0, 𝑗 ≥ 0

    ▪ Strict: 𝐸 𝑥𝑖𝑡𝑢𝑖𝑠 = 0, ∀𝑠, 𝑡

    1.2.1. Static Models Alternative Estimators

    65Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    List of estimators:

    Estimators for the random effects model:▪ Pooled OLS

    ▪ Between estimator

    ▪ Random effects estimator

    Estimators for the fixed effects model:▪ Fixed effects or Within estimator

    ▪ Least squares dummy variables (LSDV) estimator

    ▪ First-diferences estimator

    Estimators based on instrumental variables:▪ General estimators

    ▪ Hausman-Taylor estimator

    1.2.1. Static Models Alternative Estimators

    66Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Pooled OLS estimator:

    Model:𝑌𝑖𝑡 = 𝛼 + 𝑥𝑖𝑡

    ′ 𝛽 + 𝛼𝑖 − 𝛼 + 𝑢𝑖𝑡𝑣𝑖𝑡

    Assumption: 𝐸 𝑥𝑖𝑡 𝛼𝑖 + 𝑢𝑖𝑡 = 0▪ Requires random effects: 𝛼𝑖 e 𝑥𝑖𝑡 must be uncorrelated

    ▪ Requires contemporaneous exogeneity between 𝑢𝑖𝑡 and 𝑥𝑖𝑡

    Estimation:▪ OLS with a cluster-type estimator for the variance

    1.2.1. Static Models Estimators for the Random Effects Model

    Stataregress Y 𝑋1 … 𝑋𝑘 , vce(cluster clustvar)

    67Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Between estimator:

    Model:ത𝑌𝑖 = 𝛼 + ҧ𝑥𝑖

    ′𝛽 + 𝛼𝑖 − 𝛼 + ത𝑢𝑖ത𝑣𝑖

    ▪ ത𝑌𝑖 =1

    𝑇𝑖σ𝑡=1

    𝑇𝑖 𝑌𝑖𝑡, etc.

    Assumption: 𝐸 ҧ𝑥𝑖 𝛼𝑖 + ത𝑢𝑖 = 0▪ Requires random effects: 𝛼𝑖 e 𝑥𝑖𝑡 must be uncorrelated

    ▪ Requires strict exogeneity between 𝑢𝑖𝑡 and 𝑥𝑖𝑡

    Estimation:▪ OLS

    1.2.1. Static Models Estimators for the Random Effects Model

    Stataxtreg Y 𝑋1 … 𝑋𝑘 , be

    68Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Random effects estimator:

    Model:𝑌𝑖𝑡 = 𝛼 + 𝑥𝑖𝑡

    ′ 𝛽 + 𝛼𝑖 − 𝛼 + 𝑢𝑖𝑡𝑣𝑖𝑡

    New assumptions:

    ▪ 𝑉𝑎𝑟 𝛼𝑖 = 𝜎𝛼2

    ▪ 𝑉𝑎𝑟 𝑢𝑖𝑡 = 𝜎𝑢2

    Under the new assumptions:𝑐𝑜𝑟 𝑣𝑖𝑡 , 𝑣𝑖𝑠 = 𝜎𝛼

    2/ 𝜎𝛼2 + 𝜎𝑢

    2

    ▪ Taking into account this result, more efficient estimators may beobtained

    ▪ All the previous estimators did not fully exploit the panel nature of thedata in the estimation process

    1.2.1. Static Models Estimators for the Random Effects Model

    69Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Estimation:▪ Generalized least squares (GLS)

    ▪ It is equivalent to apply OLS to the following equation:

    𝑌𝑖𝑡 − 𝜃𝑖 ത𝑌𝑖 = 1 − 𝜃𝑖 𝛼 + 𝑥𝑖𝑡 − 𝜃𝑖 ҧ𝑥𝑖′𝛽 + 𝑣𝑖𝑡

    – 𝜃𝑖 = 1 − ො𝜎𝑢2/ 𝑇𝑖 ො𝜎𝛼

    2 + ො𝜎𝑢2

    – 𝑣𝑖𝑡 = 1 − 𝜃𝑖 𝛼𝑖 + 𝑢𝑖𝑡 − 𝜃𝑖 ത𝑢𝑖

    Assumption: 𝐸 ҧ𝑥𝑖𝑣𝑖𝑡 = 0▪ Requires random effects: 𝛼𝑖 e 𝑥𝑖𝑡 must be uncorrelated

    ▪ Requires strict exogeneity between 𝑢𝑖𝑡 and 𝑥𝑖𝑡

    1.2.1. Static Models Estimators for the Random Effects Model

    Stataxtreg Y 𝑋1 … 𝑋𝑘 , re vce(cluster clustvar)

    70Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Fixed effects / within estimator:

    Model:𝑌𝑖𝑡− ത𝑌𝑖= 𝑥𝑖𝑡 − ҧ𝑥𝑖 ′𝛽 + 𝑢𝑖𝑡 − ത𝑢𝑖

    ▪ Corresponds to the subtraction of the model defining the betweenestimator from the base individual effects model

    Assumption: 𝐸 𝑥𝑖𝑡 − ҧ𝑥𝑖 𝑢𝑖𝑡 −ത𝑢𝑖 = 0▪ Requires strict exogeneity between 𝑢𝑖𝑡 and 𝑥𝑖𝑡

    Estimation:▪ OLS with a cluster-type estimator for the variance

    1.2.1. Static Models Estimators for the Fixed Effects Model

    Stataxtreg Y 𝑋1 … 𝑋𝑘 , fe vce(cluster clustvar)

    71Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Limitations:▪ It is not possible to include in the model:

    – Time-constant explanatory variables

    – (If the model includes time dummies) Explanatory variables with identicalchanges over time for all individuals (e.g. age)

    ▪ Prediction not possible

    ▪ Partial effects conditional not only on 𝑥𝑖𝑡 but also on 𝛼𝑖; how to calculate them?

    Main advantage:▪ Allow for (time-constant) unobserved individual heterogeneity that

    may be correlated with the explanatory variables, not requiring the use of instrumental variables

    1.2.1. Static Models Estimators for the Fixed Effects Model

    72Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    LSDV estimator:

    Model:

    𝑌𝑖𝑡 = 𝑗=1

    𝑁

    𝛼𝑗𝑑𝑖𝑗 + 𝑥𝑖𝑡′ 𝛽 + 𝑢𝑖𝑡

    where 𝑑𝑖𝑗 = 1 if 𝑖 = 𝑗 and 0 if 𝑖 ≠ 𝑗

    Assumptions and estimates of 𝛽 identical to those of the fixedeffects estimator

    Estimates of 𝛼𝑗:

    ▪ Given by ො𝛼𝑖 = ത𝑌𝑖 − ҧ𝑥𝑖′ መ𝛽

    ▪ Consistent only in case of a long panel, in which case it is also possibleto make prediction and calculate partial effects conditional on both 𝑥𝑖𝑡and 𝛼𝑖

    1.2.1. Static Models Estimators for the Fixed Effects Model

    73Advanced Econometrics I2020/2021

    Stataareg Y 𝑋1 … 𝑋𝑘 , absorb(clustvar) vce(cluster clustvar)

    or (time-constant variables need to be manually dropped in the second alternative)

    regress Y 𝑋1 … 𝑋𝑘 i. 𝑐𝑙𝑢𝑠𝑡𝑣𝑎𝑟, vce(cluster clustvar)

  • Joaquim J.S. Ramalho

    First-differences estimator:

    Model:

    𝑌𝑖𝑡 − 𝑌𝑖,𝑡−1 = 𝑥𝑖𝑡 − 𝑥𝑖,𝑡−1′𝛽 + 𝑢𝑖𝑡 − 𝑢𝑖,𝑡−1 ⟺

    Δ𝑌𝑖𝑡 = Δ𝑥𝑖𝑡′ 𝛽 + Δ𝑢𝑖𝑡

    ▪ Corresponds to the subtraction of the first-diferences equation fromthe base individual effects model

    Assumption: 𝐸 Δ𝑥𝑖𝑡Δ𝑢𝑖𝑡 = 0

    ▪ Requires 𝐸 𝑥𝑖𝑡𝑢𝑖𝑡 = 𝐸 𝑥𝑖𝑡𝑢𝑖,𝑡−1 = 𝐸 𝑥𝑖𝑡𝑢𝑖,𝑡+1 = 0

    Estimation:▪ OLS

    Comparison with the fixed-effects estimator:▪ Identical when 𝑇 = 2

    ▪ Does not require strict exogeneity

    1.2.1. Static Models Estimators for the Fixed Effects Model

    Stataregress D.Y D.𝑋1 … D.𝑋𝑘 , vce(cluster clustvar) nocons

    74Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Endogenous explanatory variables - 𝐸 𝑥𝑖𝑡𝑢𝑖𝑡 ≠ 0:

    Possível IV’s for 𝑥𝑖𝑡:▪ External instruments, as in the cross-sectional case

    ▪ Internal instruments (same explanatory variable but relative to othertime periods)

    Example of internal instruments:▪ If 𝑥𝑖𝑡 is weakly exogenous (apart from the current period), then:

    – All past values (lags) of 𝑥𝑖𝑡 may be used as IV’s

    – Possible IV’s: 𝑥𝑖,𝑡−1 or 𝑥𝑖,𝑡−1, 𝑥𝑖,𝑡−2 or 𝑥𝑖,𝑡−1, … , 𝑥𝑖,𝑡−5 , etc.

    ▪ If 𝑥𝑖𝑡 is strictly exogenous (apart from the current period), then:

    – All past (lags) and future (leads) values of 𝑥𝑖𝑡 may be used as IV’s

    – Possible IV’s : 𝑥𝑖,𝑡−1 and/or 𝑥𝑖,𝑡+1, etc.

    1.2.1. Static Models Instrumental Variables Estimators

    Stata(external instruments – 2SLS)

    xtivreg Y (𝑋1= 𝐼𝑉𝐴… 𝐼𝑉𝑀) 𝑋2 … 𝑋𝑘, options(options: re, fe, be, fd)

    Stata(internal instruments – 2SLS)

    xtivreg Y (𝑋1= 𝐿. 𝑋1 𝐿2. 𝑋1…) 𝑋2 … 𝑋𝑘, options(options: re, fe, be, fd)

    75Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Hausman-Taylor estimator:

    Useful when interest lies on time-invariant explanatoryvariables which are correlated with 𝛼𝑖, since:

    – Fixed effects estimators: drop those variables from the model

    – Random effects estimators: inconsistent

    Intermediate case between the fixed and the random effectscases:▪ Explanatory variables correlated with 𝛼𝑖 are dealt with under the

    assumption of fixed effects

    ▪ Explanatory variables uncorrelated with 𝛼𝑖 are dealt with under the assumption of random effects

    1.2.1. Static Models Instrumental Variables Estimators

    76Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Model:𝑌𝑖𝑡 = 𝑥1𝑖𝑡

    ′ 𝛽1 + 𝑥2𝑖𝑡′ 𝛽2 + 𝑤1𝑖

    ′ 𝛾1 + 𝑤2𝑖′ 𝛾2 + 𝛼𝑖 + 𝑢𝑖𝑡

    ▪ 𝑥1𝑖𝑡: time-varying explanatory variables, uncorrelated with 𝛼𝑖▪ 𝑥2𝑖𝑡: time-varying explanatory variables, correlated with 𝛼𝑖▪ 𝑤1𝑖: time-invariant explanatory variables, uncorrelated with 𝛼𝑖▪ 𝑤2𝑖: time-invariant explanatory variables, correlated with 𝛼𝑖

    Assumptions:▪ All explanatory variables are strictly exogenous relative to 𝑢𝑖𝑡▪ 𝑥1 has a larger dimension than 𝑤2▪ 𝑥1 and 𝑤2 are correlated

    1.2.1. Static Models Instrumental Variables Estimators

    77Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Estimation:▪ 2SLS / GMM based on the following instruments for the explanatory

    variables correlated with 𝛼𝑖:

    – 𝑥2𝑖𝑡: 𝑥2𝑖𝑡 − ҧ𝑥2𝑖– 𝑤2𝑖: ҧ𝑥1𝑖

    1.2.1. Static Models Instrumental Variables Estimators

    StataxthtaylorY 𝑋11 𝑋12 … 𝑋21 𝑋22… 𝑊11 𝑊12… 𝑊21 𝑊22 …, endog(𝑋21 𝑋22… 𝑊21 𝑊22 …)

    78Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    EstimatorEffects

    Efficiency Prediction ExogeneityInternal

    instrumentsfor 𝒙𝒊𝒕

    Random Fixed

    Pooled x x Contemporaneous

    Between x x Strict Lags / Leads

    Random Effects x x x Strict Lags / Leads

    Fixed Effects xOnly if long

    panelStrict Lags / Leads

    First-Differences

    x𝐸 𝑥𝑖𝑡𝑢𝑖𝑡= 𝐸 𝑥𝑖𝑡𝑢𝑖,𝑡−1= 𝐸 𝑥𝑖𝑡𝑢𝑖,𝑡+1 = 0

    Lags / Leads(except 𝑡 − 1

    and 𝑡 + 1)

    1.2.1. Static Models Alternative Estimators

    Static Panel Data Models - Summary

    79Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Variance estimators – best alternatives:

    Cluster-robust

    Bootstrap

    Hausman test:

    Random or fixed effects?𝐻0: 𝐸 𝛼𝑖𝑥𝑖𝑡 = 0 (RE and FE consistent, RE also efficient)

    𝐻1: 𝐸 𝛼𝑖𝑥𝑖𝑡 ≠ 0 (FE consistent, RE inconsistent)

    𝐻 = መ𝛽𝐹𝐸 − መ𝛽𝑅𝐸 ′ 𝑉 መ𝛽𝐹𝐸 − 𝑉 መ𝛽𝑅𝐸−1 መ𝛽𝐹𝐸 − መ𝛽𝑅𝐸 ∼ 𝜒𝑘

    2

    1.2.1. Static Models Inference and Model Evaluation

    Stata(models must be estimated using standard estimators of the variance)

    xtreg Y 𝑋1 … 𝑋𝑘 , feestimates store ModelFExtreg Y 𝑋1 … 𝑋𝑘estimates store ModelREhausman ModelFE ModelRE

    80Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Models with lagged dependent variables:

    Include 𝑌𝑖,𝑡−1, 𝑌𝑖,𝑡−2 , … as explanatory variables:𝑌𝑖𝑡 = 𝛾1𝑌𝑖,𝑡−1 + ⋯ + 𝛾𝑝𝑌𝑖,𝑡−𝑝 + 𝑥𝑖𝑡

    ′ 𝛽 + 𝛼𝑖 + 𝑢𝑖𝑡 , 𝑡 = 𝑝 + 1 , … 𝑇

    All estimators for static panel data models are inconsistent

    Example – 𝐴𝑅 1 model:𝑌𝑖𝑡 = 𝛾1𝑌𝑖,𝑡−1 + 𝛼𝑖 + 𝑢𝑖𝑡

    This equation holds for all time periods, so:

    𝑌𝑖,𝑡−1 = 𝛾1𝑌𝑖,𝑡−2 + 𝛼𝑖 + 𝑢𝑖,𝑡−1𝑌𝑖,𝑡−2 = 𝛾1𝑌𝑖,𝑡−3 + 𝛼𝑖 + 𝑢𝑖,𝑡−2

    etc.

    1.2.2. Dynamic ModelsInconsistency of Estimators for Static Models

    81Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Random effects estimator:

    ▪ Required assumption: 𝐸 𝑌𝑖,𝑡−1𝛼𝑖 = 0

    ▪ However, 𝛼𝑖 is one of the components of 𝑌𝑖,𝑡−1, so 𝐸 𝑌𝑖,𝑡−1𝛼𝑖 ≠ 0

    ▪ All other lags of 𝑌𝑖𝑡 are also correlated with 𝛼𝑖

    Fixed effects model:

    ▪ Required assumption: 𝐸 𝑌𝑖,𝑡−1 − ത𝑌𝑖 𝑢𝑖𝑡 − ത𝑢𝑖 = 0

    ▪ However, 𝑢𝑖,𝑡−1 (included in ത𝑢𝑖) is one of the components of 𝑌𝑖,𝑡−1, so

    𝐸 𝑌𝑖,𝑡−1 − ത𝑌𝑖 𝑢𝑖𝑡 − ത𝑢𝑖 ≠ 0

    ▪ All other lags of 𝑌𝑖𝑡, which are included in ത𝑌𝑖, are also correlated with thecorresponding element of ത𝑢𝑖

    1.2.2. Dynamic Models Inconsistency of Estimators for Static Models

    82Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    First-diferences method:

    ▪ Required assumption: 𝐸 Δ𝑌𝑖,𝑡−1Δ𝑢𝑖𝑡 = 0

    ▪ However, 𝑢𝑖,𝑡−1 (included in Δ𝑢𝑖𝑡) is one of the components of 𝑌𝑖,𝑡−1(included in Δ𝑌𝑖,𝑡−1), so 𝐸 Δ𝑌𝑖,𝑡−1Δ𝑢𝑖𝑡 ≠ 0

    ▪ Unlike the previous estimators, 𝑌𝑖,𝑡−2, 𝑌𝑖,𝑡−3, … are not correlated withΔ𝑢𝑖𝑡, provided that there is no autocorrelation

    ▪ Solution: using 𝑌𝑖,𝑡−2, 𝑌𝑖,𝑡−3, … (ou functions of these variables) as instruments for Δ𝑌𝑖,𝑡−1

    1.2.2. Dynamic Models Inconsistency of Estimators for Static Models

    83Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Base Dynamic Panel Data Model:∆𝑌𝑖𝑡= 𝛾1∆𝑌𝑖,𝑡−1 + ∆𝑥𝑖𝑡

    ′ 𝛽 + ∆𝑢𝑖𝑡 , 𝑡 = 3, … , 𝑇

    Assumption:

    𝑢𝑖𝑡 has no autocorrelation ⟹ Δ𝑢𝑖𝑡 has first-orderautocorrelation:

    𝐶𝑜𝑣 ∆𝑢𝑖𝑡, ∆𝑢𝑖,𝑡−1 = 𝐶𝑜𝑣 𝑢𝑖𝑡 − 𝑢𝑖,𝑡−1, 𝑢𝑖,𝑡−1 − 𝑢𝑖,𝑡−2= −𝐶𝑜𝑣 𝑢𝑖,𝑡−1, 𝑢𝑖,𝑡−1 ≠ 0

    Main estimators:

    Anderson-Hsiao (1981)

    Arellano-Bond (1991) – ‘Difference GMM’

    Blundell-Bond (1998) – ‘System GMM’

    1.2.2. Dynamic Models Instrumental Variable Estimators

    84Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Anderson-Hsiao (1981):

    Two alternative instruments:

    ▪ 𝑌𝑖,𝑡−2

    ▪ ∆𝑌𝑖,𝑡−2 (one observation is lost but in general seems to produce more efficient estimators)

    1.2.2. Dynamic Models Instrumental Variable Estimators

    Stataivregress gmm D.Y (𝐷𝐿. 𝑌 = 𝐿2. 𝑌) 𝐷. 𝑋1 … 𝐷. 𝑋𝑘

    85Advanced Econometrics I2020/2021

    Stataxtivreg D.Y (DL. 𝑌 = DL2. 𝑌) D. 𝑋1 … D.𝑋𝑘

    or

    xtivreg Y (L. 𝑌 = L2. 𝑌) 𝑋1 … 𝑋𝑘 , fd

  • Joaquim J.S. Ramalho

    Arellano-Bond (1991):

    Proposed using all available lags of 𝑌𝑖,𝑡 as instruments:

    ▪ 𝑡 = 3: 𝑌𝑖,1

    ▪ 𝑡 = 4: 𝑌𝑖,2, 𝑌𝑖,1

    ▪ …

    ▪ 𝑡 = 𝑇: 𝑌𝑖,𝑇−2, … , 𝑌𝑖,2, 𝑌𝑖,1

    Total number of instruments: 𝑇 − 1 𝑇 − 2 /2

    It is possible to use only a subset of the available instruments

    More efficient than Anderson-Hsiao’s (1981) estimators

    1.2.2. Dynamic Models Instrumental Variable Estimators

    Stataxtabond Y 𝑋1 … 𝑋𝑘 , maxldep(#) twostep vce(robust)

    86Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Blundell-Bond (1998):

    Often, lags of 𝑌𝑖,𝑡 are not good instruments for ∆𝑌𝑖,𝑡

    Proposed adding the following instruments: ∆𝑌𝑖,2,…,∆𝑌𝑖,𝑇−1

    Total number of instruments: 𝑇−1 𝑇−2

    2+ 𝑇 − 2

    It is possible to use only a subset of the available instruments

    More efficient than Arellano-Bond’s (1991) estimator

    Requires heavier assumptions than Arellano-Bond’s (1991) estimator

    1.2.2. Dynamic Models Instrumental Variable Estimators

    Stataxtdpdsys Y 𝑋1 … 𝑋𝑘 , maxldep(#) twostep vce(robust)

    87Advanced Econometrics I2020/2021

  • Joaquim J.S. Ramalho

    Most common tests:

    Hansen’s J test of overidentifying restrictions

    Test for autocorrelation▪ All estimators for dynamic panel data models assume first-order

    autocorrelation:

    – 𝐶𝑜𝑣 ∆𝑢𝑖𝑡, ∆𝑢𝑖,𝑡−𝑙 ≠ 0

    – 𝐶𝑜𝑣 ∆𝑢𝑖𝑡, ∆𝑢𝑖,𝑡−𝑙 = 0, 𝑙>1

    1.2.2. Dynamic Models Tests for Instruments Validity

    Stata(after xtabond or xtdpdsys, with variance estimated in a standard way)

    estat sargan

    Stata(after xtabond or xtdpdsys, with variance estimated in a standard way)

    estat abond, artests(3)

    88Advanced Econometrics I2020/2021