Spatex.Regression.GMErrorRegimes (Spatex v0.2.1)

Copy Markdown View Source

Result of Spatex.Regression.gm_error_regimes/5 (spreg.GM_Error_Regimes and, with :yend, spreg.GM_Endog_Error_Regimes; the _Het_ and _Hom_ classes with estimator: :het / :hom).

  • betas, vm, std_err, z_stat ([{z, p}]) - in :pooled mode spreg's layout: the regime-specific exogenous columns of every regime in turn ("<regime>_<name>"), the global ones ("_Global_<name>"), the same for the endogenous columns, then lambda last. vm, std_err and z_stat have no entry for lambda (KP98 reports none). In :separate mode every regime's [constant, x..., yend..., lambda] block follows the previous one and vm is block diagonal. With :het / :hom the covariance, std_err and z_stat also have the lambda entry (:separate: one per block), and kr counts lambda in :separate mode, as spreg does.
  • names - the coefficient names in betas order (lambda included); name_x, name_yend, name_q - names as spreg lists them (name_x ends with "lambda" for a model without :yend, as spreg's does).
  • kr, kf, kryd, nr - regime-specific columns per regime (exogenous plus endogenous), global columns (lambda counted, as spreg does), regime-specific endogenous columns and regimes; regimes - the labels in order.
  • lam - the spatial error coefficient (:pooled); lams - :separate, a map by regime label.
  • sig2, pr2 - error variance (u'u / n of the filtered fit; nil for :het, which reports none) and squared correlation of y with predy (:pooled; spreg reports none for the regimes of :separate, which live in the per-regime fits).
  • estimator, iteration, iter_stop, step1c (:het), max_iter, epsilon, a1 (:hom) and lambdas (every lambda the moment optimizer returned, in call order; a map by regime in :separate mode) - nil for :kp98 (:pooled; in :separate mode the iterations live in the per-regime fits).
  • u, predy (Z betas), e_filtered (u - lambda W u).
  • chow - %{joint: {wald, p}, regi: [{name, wald, p}]}: Wald tests that the coefficients (lambda excluded, except in the :separate Het / Hom fits, where spreg tests it too) are equal across regimes, jointly and per regime-specific column.
  • mode - :separate (one Spatex.Regression.GMError per regime on the regime's subgraph, in multi by label) or :pooled (one KP98 fit on the regime design).
  • cols2regi - the flags over the x then yend columns; constant_regi, regime_err_sep, warnings.

Summary

Types

t()

@type t() :: %Spatex.Regression.GMErrorRegimes{
  a1: term(),
  betas: term(),
  chow: term(),
  cols2regi: term(),
  constant_regi: term(),
  e_filtered: term(),
  epsilon: term(),
  estimator: term(),
  iter_stop: term(),
  iteration: term(),
  kf: term(),
  kr: term(),
  kryd: term(),
  lam: term(),
  lambdas: term(),
  lams: term(),
  max_iter: term(),
  mode: term(),
  multi: term(),
  n: term(),
  name_q: term(),
  name_x: term(),
  name_y: term(),
  name_yend: term(),
  names: term(),
  nr: term(),
  pr2: term(),
  predy: term(),
  regime_err_sep: term(),
  regimes: term(),
  sig2: term(),
  std_err: term(),
  step1c: term(),
  u: term(),
  vm: term(),
  warnings: term(),
  z_stat: term()
}