Skip to contents

Computes the Cragg-Donald (1993) weak-instrument statistic. The statistic is a function of the first-stage regression and is independent of the outcome variable; outcome only needs to name a numeric column in data so ivreg can compile a formula. When outcome = NULL (default), the first endogenous regressor is reused as the outcome – works because ivreg's weak-IV diagnostic comes from the first stage regardless of y.

Usage

morie_iv_cragg_donald(
  data,
  endogenous,
  instruments,
  exogenous = NULL,
  outcome = NULL
)

Arguments

data

Data frame.

endogenous

Character vector of endogenous regressor names.

instruments

Character vector of excluded-instrument names.

exogenous

Optional exogenous covariates.

outcome

Optional outcome column name. Default NULL reuses endogenous[1]; the resulting F-statistic is unaffected because Cragg-Donald only reads the first stage.

Value

Named list with statistic, p_value, name, details.