Search this site
Embedded Files
Yuya Sasaki - Professor of Economics - Vanderbilt University
  • HOME
    • CV
    • RESEARCH
    • STATA
      • Stata Command: cdecompose
      • Stata Command: crhdreg
      • Stata Command: dkdensity
      • Stata Command: exquantile
      • Stata Command: itvalpctile
      • Stata Command: kotlarski
      • Stata Command: npeivreg
      • Stata Command: npss
      • Stata Command: qrkd
      • Stata Command: rdqte
      • Stata Command: reporterror
      • Stata Command: rkqte
      • Stata Command: robustate
      • Stata Command: robustpf
      • Stata Command: testex
      • Stata Command: testout
      • Stata Command: xtusreg
      • Stata Command: xtregtwo
      • Stata Command: ecic
      • Stata Command: oga
    • STUDENTS
    • TEACHING
    • 日本語
Yuya Sasaki - Professor of Economics - Vanderbilt University
  • HOME
    • CV
    • RESEARCH
    • STATA
      • Stata Command: cdecompose
      • Stata Command: crhdreg
      • Stata Command: dkdensity
      • Stata Command: exquantile
      • Stata Command: itvalpctile
      • Stata Command: kotlarski
      • Stata Command: npeivreg
      • Stata Command: npss
      • Stata Command: qrkd
      • Stata Command: rdqte
      • Stata Command: reporterror
      • Stata Command: rkqte
      • Stata Command: robustate
      • Stata Command: robustpf
      • Stata Command: testex
      • Stata Command: testout
      • Stata Command: xtusreg
      • Stata Command: xtregtwo
      • Stata Command: ecic
      • Stata Command: oga
    • STUDENTS
    • TEACHING
    • 日本語
  • More
    • HOME
      • CV
      • RESEARCH
      • STATA
        • Stata Command: cdecompose
        • Stata Command: crhdreg
        • Stata Command: dkdensity
        • Stata Command: exquantile
        • Stata Command: itvalpctile
        • Stata Command: kotlarski
        • Stata Command: npeivreg
        • Stata Command: npss
        • Stata Command: qrkd
        • Stata Command: rdqte
        • Stata Command: reporterror
        • Stata Command: rkqte
        • Stata Command: robustate
        • Stata Command: robustpf
        • Stata Command: testex
        • Stata Command: testout
        • Stata Command: xtusreg
        • Stata Command: xtregtwo
        • Stata Command: ecic
        • Stata Command: oga
      • STUDENTS
      • TEACHING
      • 日本語

< Back to STATA Main Page

Stata Command: testex

Stata Command: testex.ado

A statistical test of the exclusion restriction of an instrumental variable (IV) based on D'Haultfoeuille, Hoderlein, & Sasaki (2021). Use it when you consider running an IV regression and want to test the exclusion restriction of the IV to ensure that it is a valid IV.

Installation:    

    . ssc install testex

Help:    

    . help testex

Reference:  D'Haultfoeuille, X., Hoderlein, S & Sasaki, Y. (2021) Testing and Relaxing the Exclusion Restriction in the Control Function Approach. Journal of Econometrics, forthcoming. Paper

Title
    testex -- Executes a statistical test of the exclusion restriction of an        instrumental variable (IV).
Syntax
    testex y x z [if] [in] [, numboot(real)]

Description
    testex executes a statistical test of the exclusion restriction of an        instrumental variable (IV) based on D'Haultfoeuille, Hoderlein, &        Sasaki (2021).  The command takes as input a scalar outcome variable        y, a scalar endogenous variable x that is continuous, and a scalar        instrumental variable z.  If the instrument is not binary, then the        program transforms the original instrument into a binary one.  The        output of the command includes the p-value of the test and the        indicators of whether the test rejects the null hypothesis at various        levels of statistical significance.  The program gives a caution when        there is no crossing of conditional CDFs required by Assumption 5 in        D'Haultfoeuille, Hoderlein, & Sasaki (2021).

Option
    numboot(real) sets the number of multiplier bootstrap iterations to        compute the critical value of the test statistic. The default value        is numboot(1000).

Examples
    y outcome variable, x endogenous variable, z instrumental variable
    Test of the exclusion restriction:
    . testex y x z
    Setting the number of multiplier bootstrap iterations to 2000
    . testex y x z, numboot(2000)
    Including additive controls:
    . reg y controls    . predict residy, resid    . reg x controls    . predict residx, resid    . reg z controls    . predict residz, resid    . testex residy residx residz

Stored results
    testex stores the following in r():
    Scalars        r(N)           observations        r(nb)          Number of multiplier bootstrap iterations        r(bw)          Bandwidth        r(KS)          KS statistic        r(p)           P-value
    Macros        r(cmd)         testex

Reference

    D'Haultfoeuille, X., S. Hoderlein, & Y. Sasaki. 2021. Testing and Relaxing        the Exclusion Restriction in the Control Function Approach.  Journal of        Econometrics, forthcoming.   Link to Paper.

Authors
    Xavier D'Haultfoeuille, CREST-ENSAE, Palaiseau, France.    Stefan Hoderlein, Emory University, Atlanta, GA.    Yuya Sasaki, Vanderbilt University, Nashville, TN.
Google Sites
Report abuse
Page details
Page updated
Google Sites
Report abuse